To build a mini-NAS I have bought a new Seagate 5T 2.5inch disk and attached the USB to the RPI3. (Yes, it's slow and I plan to upgrade this rig to RPI4 with USB3) Seems the spin-up and self test of the disk take longer during the boot sequence than the point in time when mount is called. Thus on normal boot the disk is not mounted and missing from the file system.
Manually adding a
Code: Select all
mount -a Question : Is there syntax in fstab to allow for a longer-than-usual spin-up of the disk?
I have seen fstab code to wait for network-up until a mount is issued. But this is a plain 'spinning-rust' device.
As a workaround (which I hope is not permanent) I've put the mounts into a crontab entry.
Code: Select all
@reboot sleep 30 && mount -aCode: Select all
UUID=F02E77D02E778E7A /media/usbdisk ntfs-3g auto,user,exec,rw,nofail,noatime,errors=remount-ro 0 0Code: Select all
grep ' sd ' /var/log/syslog | grep '17 17'
Sep 17 17:00:47 rpi3 kernel: [ 4.088699] sd 0:0:0:0: [sda] Spinning up disk...
Sep 17 17:00:47 rpi3 kernel: [ 4.101507] sd 0:0:0:0: Attached scsi generic sg0 type 0
Sep 17 17:00:47 rpi3 kernel: [ 10.325987] sd 0:0:0:0: [sda] Very big device. Trying to use READ CAPACITY(16).
Sep 17 17:00:47 rpi3 kernel: [ 10.326241] sd 0:0:0:0: [sda] 9767541167 512-byte logical blocks: (5.00 TB/4.55 TiB)
Sep 17 17:00:47 rpi3 kernel: [ 10.336904] sd 0:0:0:0: [sda] Write Protect is off
Sep 17 17:00:47 rpi3 kernel: [ 10.336918] sd 0:0:0:0: [sda] Mode Sense: 4f 00 00 00
Sep 17 17:00:47 rpi3 kernel: [ 10.337358] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Sep 17 17:00:47 rpi3 kernel: [ 10.341385] sd 0:0:0:0: [sda] Very big device. Trying to use READ CAPACITY(16).
Sep 17 17:00:47 rpi3 kernel: [ 10.450387] sd 0:0:0:0: [sda] Very big device. Trying to use READ CAPACITY(16).
Sep 17 17:00:47 rpi3 kernel: [ 10.451484] sd 0:0:0:0: [sda] Attached SCSI disk
Sep 17 17:00:47 rpi3 kernel: [ 12.247721] sd 1:0:0:0: [sdb] 249999360 512-byte logical blocks: (128 GB/119 GiB)
Sep 17 17:00:47 rpi3 kernel: [ 12.247821] sd 1:0:0:0: Attached scsi generic sg1 type 0
Sep 17 17:00:47 rpi3 kernel: [ 12.247938] sd 1:0:0:0: [sdb] Write Protect is off
Sep 17 17:00:47 rpi3 kernel: [ 12.247951] sd 1:0:0:0: [sdb] Mode Sense: 23 00 00 00
Sep 17 17:00:47 rpi3 kernel: [ 12.248268] sd 1:0:0:0: [sdb] Write cache: disabled, read cache: disabled, doesn't support DPO or FUA
Sep 17 17:00:47 rpi3 kernel: [ 12.260593] sd 1:0:0:0: [sdb] Attached SCSI removable disk
Code: Select all
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sdb 8:16 1 119.2G 0 disk
└─sdb1 8:17 1 119.2G 0 part /media/usbstick
sda 8:0 0 4.6T 0 disk
├─sda2 8:2 0 4.6T 0 part /media/usbdisk
└─sda1 8:1 0 128M 0 part
mmcblk0 179:0 0 29.7G 0 disk
├─mmcblk0p2 179:2 0 29.7G 0 part /
└─mmcblk0p1 179:1 0 63M 0 part /boot
Your feedback is appreciated.
Cheers,
Gert
PS : Let me know if there are other improvement to the fstab entry.