12.04 – ubuntu 20.04 NFS Share – permissions lost for nobody:nogroup on reboot

I am new to Ubuntu/linux, so, most of the config comes from reading guides.

Please bear with me.

I have a fresh install of ubuntu 20.04 server with the intention of using a NFS share as a NAS for a Hikvision camera.

This worked perfectly for a few months until I rebooted the server, and, the camera could not “see” the share. Rebooting the camera had no effect.

The error was (from memory) that the share path was not accessible. re-running

sudo chown nobody:nogroup /media/jack/camera1

Fixes it until reboot.

I am unsure how to fix this, can anyone advise? Why do the permissions get lost on reboot?

Steps I took to configure the server /share:

  1. Create a ext4 disc partition with the mount point /media/jack/camera1

  2. sudo apt update && sudo apt upgrade

  3. sudo apt -y install nfs-kernel-server

  4. add the following to etc/exports

    /media/jack/camera1 *(rw,sync,no_root_squash,no_subtree_check)

  5. cd/media/jack/camera1

  6. sudo rmdir lost+found

  7. sudo chown nobody:nogroup /media/jack/camera1

  8. sudo systemctl restart nfs-kernel-server

At this stage, I can connect to the share from the camera and store footage.
When the server reboots, the camera cannot “see” the drive, until I run

sudo chown nobody:nogroup /media/jack/camera1

Then I am back in business.

Appreciate any help you can give