2

I want my Pi to mount my USB drive at boot if the drive is inserted, however, I also want the Pi to boot regardless of whether or not the drive is inserted at startup or not. I edited my fstab file and used my devices UUID to mount it, and it works fine, but like the title says, it won't boot without the drive inserted.

I read online that I need to write nofail in my fstab line, which I tried doing but I think I did it wrong as it still won't boot. Here is the line I have written in my fstab file:

UUID=9687-3A59 /mnt/usb vfat defaults 0 2, nofail

Also, I read from another user on here that if you go this route by adding nofail to fstab, if the drive isn't inserted you have to wait 90 seconds for the Pi to try mounting it. Is there an alternative to this? Something where I won't have to wait if it's not there, but it will still boot with or without the drive?

I am new to the Pi/Linux/Unix world, and this has all been a major learning process that I am enjoying so far.

2
  • 1
    First of all, you should add nofail to fstab after defaults, without a space between the comma and fstab. The line should look like this: UUID=9687-3A59 /mnt/usb vfat defaults,nofail 0 2 Jan 8 '17 at 8:20
  • See man fstab for a better understanding of how the file should be structured.
    – goldilocks
    Jan 8 '17 at 16:43
1

Try adding nobootwait to the options section. The line should look like this:

UUID=9687-3A59 /mnt/usb vfat defaults,nofail,nobootwait 0 2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.