I have an RPI-based NFS server with an external USB hard disk. After a recent upgrade to Raspbian 8.0 and systemd I noticed that now nfs-kernel-server seems to be starting before all file systems on the external disk are mounted:

Jun 29 12:01:33 nas nfs-kernel-server[369]: Exporting directories for NFS kernel daemon...exportfs: Failed to stat ▒▒▒▒▒▒▒▒▒▒(redacted): No such file or directory

The nfs-kernel-server has a sysV startup script in /etc/init.d. I tried adding $local_fs to the list of its requirements, but it did not help. I would really appreciate any suggestions on how to fix this.

(I also see smartd starting before the udev tree is fully populated, but I'll save that for another question.)

2 Answers 2


In /etc/fstab you can try to add x-systemd.before=nfs-kernel-server.service as option to the mount maybe?

  • Thanks! It really helped.
    – Vadim
    Commented Dec 23, 2021 at 20:43

You could try to add a sleep to the nfs-kernel-server script.

Open up the script with:

$ sudo vim /etc/init.d/nfs-kernel-server

Scroll down and find the start() section (it's usally under the first case) and add a sleep for 30 seconds under start:

sleep 30

Save and exit.

  • Thanks. That's will be the hack of the last resort. I did not loose hope yet to find a solution...
    – kolbusa
    Commented Jun 29, 2015 at 8:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .