Cannot reproduce the failure within 10000 cycles test now, thanks. Tested-by: Yi Zhang <yi.zhang@xxxxxxxxxx> On Wed, Apr 17, 2024 at 6:42 PM Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx> wrote: > > Recently, CKI project found blktests nbd/002 failure. The test case sets up the > connection to the nbd device, then checks partition existence in the device to > confirm that the kernel reads the partition table in the device. Usually, this > partition read by kernel is completed before the test script checks the > partition existence. However, the partition read often completes after the > partition existence check, then the test case fails. I think the test script > checks the partition existence too early, and this should be fixed in the test > script. > > During this investigation, I noticed that the test case nbd/002 handles the > ioctl interface and the netlink interface opposite. The first patch fixes this > wrong interface handling. The second patch addresses the too early partition > existence check issue. > > Link to v1 patch: https://lore.kernel.org/linux-block/20240319085015.3901051-1-shinichiro.kawasaki@xxxxxxx/ > > Changes from v1: > * Added another patch to fix ioctl/netlink interface handling mistake > * Avoid the nbd/002 failure by repeating the partition existence check > > Shin'ichiro Kawasaki (2): > nbd/002: fix wrong -L/-nonetlink option usage > nbd/002: repeat partition existence check for ioctl interface > > tests/nbd/002 | 26 ++++++++++++++++++-------- > 1 file changed, 18 insertions(+), 8 deletions(-) > > -- > 2.44.0 > -- Best Regards, Yi Zhang