TurnKey Nextcloud LXC NFS missing

I recently posted the TurnKey Linux’ Nextcloud container on Proxmox and I encountered an annoying issue with it. I could not figure out if the issue is from Proxmox, TKL Nextcloud LXC, or my NAS which is exporting the NFS share. The issue is the mount point disconnect after ~4 hours. Since my installation is based on NFS share for /data, when I logged in, I got the prompt that I do not have the .occdata in my data directory. When I checked the mount within the Nextcloud LXC via the command df -h, the output was not showing the NFS mount point. I also checked the Proxmox server and it was still able to access the NFS export.

Anyways, the workaround I found is to reboot the LXC container. Once the container has been rebooted, the mount point works again. To somewhat to automate the reboot. I have to create a cron file in the /etc/cron.d/ directory.

# Create a file in /etc/cron.d/
vim reboot_e4h

# Paste these two lines. This reboots the LXC container every 4 hours starting at 12 midnight
# run cron to reboot lxc to re-establish the mount point
0 0,4,8,12,16,20 * * * root 	/sbin/shutdown -r now

If I find a better solution or a fix, I will post about it. For now, LXC reboots takes 2 – 3 seconds so it is not hurting my services at all.

Hope you’ll find this useful. Cheers!

Notify of

Inline Feedbacks
View all comments
Would love your thoughts, please comment.x
WordPress Appliance - Powered by TurnKey Linux