All of lore.kernel.org
 help / color / mirror / Atom feed
From: lixiaokeng <lixiaokeng@huawei.com>
To: Martin Wilck <mwilck@suse.com>,
	Benjamin Marzinski <bmarzins@redhat.com>,
	 Christophe Varoqui <christophe.varoqui@opensvc.com>,
	dm-devel mailing list <dm-devel@redhat.com>
Cc: linfeilong <linfeilong@huawei.com>,
	"liuzhiqiang \(I\)" <liuzhiqiang26@huawei.com>,
	lihaotian9@huawei.com
Subject: Re: [dm-devel] [QUESTION]: multipath device with wrong path lead to metadata err
Date: Thu, 28 Jan 2021 16:27:51 +0800	[thread overview]
Message-ID: <7d64e510-029e-dd4b-9afc-58721a37cf30@huawei.com> (raw)
In-Reply-To: <5440d76a18994a7a214321c30fe8a1e99c0a3988.camel@suse.com>


> 
>>
>> (1)multipath -r: The sdf is found as a path of
>> 36001405b7679bd96b094bccbf971bc90
>> (iscsi node is 4:0:0:2)
>>

   Here is a log "dm destory name dm-5; majir:minor 253:5; dm-5"
(dm-5 36001405b7679bd96b094bccbf971bc90) in system time
[1202538.163972]. I add this print in dm_destroy.

>> (2)iscsi logout: The sdf is removed in iscsi in system time
>> [1202538.467014].
>>

   I add refcount print in put_disk instead of put_disk_and_module.
The refcount of sdf will be reduced to zero even the fd to /dev/sdf
is opened (there is no "Couldn't open device node for sdf in log)
when 36001405b7679bd96b094bccbf971bc90 is destoried and iscsi
logout.

   I don't know why dm-5 is destoried. I doubt there may be some
issue in the kernel that I add some print. I have test this in
three computers, but the other two have no problem (they have been
runing for 96h and for 48h respectively).

   I will replace the kernel of the computer with this issue and test
it again.

   Do you have any great idea about dm-5 destruction? Thanks.

Regards,
Lixiaokeng



>> (3)iscsi login: The sdf appears in iscsi in system time
>> [1202538.825745].
>> It is a path of 3600140584e11eb1818c4afab12c17800 (iscsi node
>> 2:0:0:0)
>>
>> Here I have a doubt. When I stop in domap using gdb and iscsi log
>> out/in,
>> the sdf will not  be used again becasue the disk refcount is not
>> zero. I
>> add a print if the disk refcount is zero in put_disk_and_module (for
>> example lxk ref put after: name sdi; count 0), but there is not this
>> print
>> about sdf.
> 
> Yes, this is a very good point, and it's indeed strange. multipathd
> should have opened a file descriptor to /dev/sdf in pathinfo(), and as
> long as that file is open, the use count shouldn't drop to 0, the disk
> devices (block device and scsi_disk device) shouldn't be released, and
> the major/minor number shouldn't be reused. Unless I'm missing
> something essential, that is.


--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel


  reply	other threads:[~2021-01-28  8:28 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-18 11:08 [dm-devel] [QUESTION]: multipath device with wrong path lead to metadata err lixiaokeng
2021-01-19  9:41 ` Martin Wilck
2021-01-19 12:46   ` lixiaokeng
2021-01-19 21:57 ` Martin Wilck
2021-01-20  2:30   ` lixiaokeng
2021-01-20 14:07     ` Martin Wilck
2021-01-25  1:33       ` lixiaokeng
2021-01-25 12:28         ` Martin Wilck
2021-01-26  6:40           ` lixiaokeng
2021-01-26 11:14           ` lixiaokeng
2021-01-26 23:11             ` Martin Wilck
2021-01-28  8:27               ` lixiaokeng [this message]
2021-01-28 21:15                 ` Martin Wilck
2021-02-04 11:25               ` lixiaokeng
2021-02-04 14:56                 ` Martin Wilck
2021-02-05 11:49                   ` lixiaokeng
2021-01-20 13:02   ` Roger Heflin
2021-01-20 20:45     ` Martin Wilck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7d64e510-029e-dd4b-9afc-58721a37cf30@huawei.com \
    --to=lixiaokeng@huawei.com \
    --cc=bmarzins@redhat.com \
    --cc=christophe.varoqui@opensvc.com \
    --cc=dm-devel@redhat.com \
    --cc=lihaotian9@huawei.com \
    --cc=linfeilong@huawei.com \
    --cc=liuzhiqiang26@huawei.com \
    --cc=mwilck@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.