Skip to content

Passing -J <JSON_config_file> option results in error #3607

Description

@martin-gpy

I'm aware that INI config file changes are in place now. But reading a JSON config file now results in a malformed line error which used to work properly in the past. For e.g.

# cat /usr/local/etc/nvme/config.json
[
  {
    "hostnqn":"nqn.2014-08.org.nvmexpress:uuid:e6550026-173e-4959-ba74-be367844bd8a",
    "hostid":"e6550026-173e-4959-ba74-be367844bd8a",
    "subsystems":[
      {
        "nqn":"nqn.1992-08.com.netapp:sn.48391d66c0a611ecaaa5d039ea165514:subsystem.subsys_CLIENT116_0",
        "ports":[
          {
            "transport":"tcp",
            "traddr":"192.168.1.117",
            "host_traddr":"192.168.1.6",
            "trsvcid":"4420"
          }
        ]
      }
    ]
  }
]
# nvme connect-all -J /usr/local/etc/nvme/config.json
Failed to lookup host 'nqn.2014-08.org.nvmexpress:uuid:e6550026-173e-4959-ba74-be367844bd8a'
/usr/local/etc/nvme/config.json:1: malformed line "["
failed to read /usr/local/etc/nvme/config.json: Invalid argument
#

Is this expected? Or it no longer handles the -J <JSON_config_file> option anymore?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions