On 3/15/19 10:36 AM, Michal Soltys wrote: > On 19/03/15 04:59, Andrei Borzenkov wrote: >> 14.03.2019 19:17, Michal Soltys пишет: >>> On 3/14/19 5:09 PM, Michal Soltys wrote: >>>> On 3/14/19 4:57 PM, Hans van Kranenburg wrote: >>>>> On 3/14/19 4:44 PM, Michal Soltys wrote: >>>>>> >>>>>> <cut> > > That would point to some really weird thing [not] being done in > initramfs in its debian variation. I'll look closer into it. > > Thanks for pointing that out, the 'btrfs device scan' requirement > completely slipped my mind. > >> What "dmesg | grep -i btrfs" shows before and after these commands? >> > > Will verify and report. > Turned out to be a peculiar race issue with debian's initrams-tools's btrfs script (basically executing device scan during its local-premount stage). As it turned out it can be executed very early - in my case, before any block device is even visible in /dev. So no wonder later root mounting didn't work correctly. Hans, Andrei - thanks for help. For the record: [ 15.445002] scsi 0:0:7:0: atapi(n), ncq(y), asyn_notify(n), smart(y), fua(y), sw_preserve(y) [ 15.545118] input: USB Keyboard as /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.1/2-1.1.3/2-1.1.3:1.0/0003:09DA:0260.0003/input/input2 ->>> [ 15.754962] ::: Starting BTRFS pre-mount [ 15.801450] scsi 0:0:8:0: Direct-Access ATA ST2000VX000-1CU1 CV22 PQ: 0 ANSI: 6 ->>> [ 15.803632] ::: Finishing BTRFS pre-mount [ 15.851614] scsi 0:0:8:0: SATA: handle(0x000f), sas_addr(0x5003048000b28b90), phy(16), device_name(0x0000000000000000) [ 15.854133] hid-generic 0003:09DA:0260.0003: input,hidraw2: USB HID v1.10 Keyboard [ USB Keyboard] on usb-0000:00:1d.0-1.1.3/input0 .... then a bit later devices become available: [ 19.691841] sd 0:0:0:0: Power-on or device reset occurred [ 19.692125] sd 0:0:1:0: Power-on or device reset occurred [ 19.740664] sd 0:0:2:0: Power-on or device reset occurred [ 19.740803] scsi 1:0:0:0: Direct-Access ATA INTEL SSDSC2BB08 0370 PQ: 0 ANSI: 5 [ 19.741009] sd 0:0:12:0: Power-on or device reset occurred [ 19.741166] scsi 2:0:0:0: Direct-Access ATA INTEL SSDSC2BB08 0370 PQ: 0 ANSI: 5 [ 19.741348] sd 0:0:3:0: Power-on or device reset occurred [ 19.742136] sd 0:0:0:0: [sda] 7814037168 512-byte logical blocks: (4.00 TB/3.64 TiB) ... and finally: [ 25.221537] md127: detected capacity change from 0 to 5401587744768 [ 25.363978] PM: Image not found (code -22) [ 25.424970] BTRFS: device label xs22_root devid 1 transid 33775 /dev/sds2 [ 25.455095] BTRFS info (device sds2): disk space caching is enabled [ 25.483435] BTRFS info (device sds2): has skinny extents [ 25.513225] BTRFS error (device sds2): devid 2 uuid c93d387c-1acc-4bea-aeae-59a440ac7991 is missing [ 25.546619] BTRFS error (device sds2): failed to read the system array: -2 [ 25.602175] BTRFS error (device sds2): open_ctree failed
