[bug report] most of blktests nvme/ failed on the latest linux tree
Max Gurtovoy
mgurtovoy at nvidia.com
Thu Jun 29 05:18:26 PDT 2023
On 29/06/2023 10:36, Daniel Wagner wrote:
> On Wed, Jun 28, 2023 at 02:00:57PM +0300, Max Gurtovoy wrote:
> > --- a/tests/nvme/rc
>>> +++ b/tests/nvme/rc
>>> @@ -14,8 +14,23 @@ def_remote_wwnn="0x10001100aa000001"
>>> def_remote_wwpn="0x20001100aa000001"
>>> def_local_wwnn="0x10001100aa000002"
>>> def_local_wwpn="0x20001100aa000002"
>>> -def_hostnqn="$(cat /etc/nvme/hostnqn 2> /dev/null)"
>>> -def_hostid="$(cat /etc/nvme/hostid 2> /dev/null)"
>>> +
>>> +if [ -f "/etc/nvme/hostid" ]; then
>>> + def_hostid="$(cat /etc/nvme/hostid 2> /dev/null)"
>>> +else
>>> + def_hostid="$(uuidgen)"
>>> +fi
>>> +if [ -z "$def_hostid" ] ; then
>>> + def_hostid="0f01fb42-9f7f-4856-b0b3-51e60b8de349"
>>> +fi
>>> +
>>> +if [ -f "/etc/nvme/hostnqn" ]; then
>>> + def_hostnqn="$(cat /etc/nvme/hostnqn 2> /dev/null)"
>>> +fi
>>> +if [ -z "$def_hostnqn" ] ; then
>>> + def_hostnqn="nqn.2014-08.org.nvmexpress:uuid:${def_hostid}"
>>> +fi
>
> Is there a specific reason why we want to read the /etc/nvme/hostnqn file at
> all? Can't we just use a fixes hostid/hostnqn?
Yes, this will do the job but I guess the initial thought was to use the
same hostnqn/hostid that one configured to the host also for testing.
I don't have a real preference between the two.
More information about the Linux-nvme
mailing list