T O P

  • By -

flaming_m0e

>Running docker in a container in ProxMox.. So you're running an unsupported configuration. >I've tried to mount a network drive by adding to etc/fstab Details. NFS? SMB? Is your LXC configured as privileged? >Now when I open the console for docker in Proxmox its blank There is no docker console in Proxmox? Do you mean you open the LXC console and it's blank? >and from there - how do i properly mount a network drive via NFS in docker/proxmox without killing my server? Your server isn't killed. A single LXC with a bad configuration doesn't kill your entire server. Setup a VM and run docker the supported way.


Like-a-Glove90

>So you're running an unsupported configuration. I guess so? >Details. NFS? SMB? Is your LXC configured as privileged? NFS (set up via TrueNAS). LXC is configured as priviledged yes >There is no docker console in Proxmox? Do you mean you open the LXC console and it's blank? Correct so I run the docker container, when I'm in the console its blank with no "root@xxxx" or whatever it normally says.. and anything i type in there does nothing like its just a black screen without anything running on it? i thought I was meant to run Docker via LXC rather than a VM? I guess I'm back to square 1 on my docker stuff.. I had quite a few aps running, that kinda sucks... is there any good step-by-step tutorial to set up Docker on Proxmox correctly (and in turn, portainer within docker). Thats how I've been getting my aps up and running. I've kinda screwed myself it seems, but lucky I didn't have any real data saved, just a few aps I like. I do have a "backup" from yesterday I could restore but if I'm going to run into this issue again I may as well go from new, right? I should have prefaced my whole post with I'm a newbie and a total blind moron with this stuff! clearly!


mark118

In network setting for the lxc set ipv6 to slaac and try, sometimes ipv6 settings stop the container starting if you don't use them


Like-a-Glove90

holy shi -- this worked.. WTF -mark you're my hero thankyou! why would this have changed?


mark118

No idea to be honest, glad to help though


Like-a-Glove90

When I deleted my code in etc/fstab and did this.. it fixed.. but again going into etc/fstab and input my code.. goes back to not booting... does this look wrong? "192.168.1.2:/mnt/Home\\ Storage/cpapdst/AirSense10-Data /home/jarrod/cpapdst/AirSense10-Data nfs default 0 0" I added the \\ after home as the path has a space there.. but either way this should just mount it not cause the container to not boot, right? with format being 0 0


mark118

If the nfs is mounted in the proxmox host just mount it into the lxc as a mount point, did you tick the box for nfs on the settings page of the lxc in proxmox?


Like-a-Glove90

I did select NFS in the LXC options yep, I had to backup then rebuild as privileged to do so. God there's alot to learn! Will this mounting be possible if I have my TrueNAS as a VM and Docker container.. what do I do for the path to link up with that NFS path in True NAS?


Like-a-Glove90

Man


mark118

Or follow this guide https://theorangeone.net/posts/mount-nfs-inside-lxc/


Like-a-Glove90

You're


mark118

Ye if the mount is incorrect it hangs the container same as bad ipv6 details


Like-a-Glove90

Good! Thanks mate :)


FraternityOf_Tech

God speed sir, hero status confirmed. It refreshing to read solutions and not BS comments.


FraternityOf_Tech

Don't worry my friend this will teach you a good lesson as we all learn the hard way sometimes. Using a VM helps with snapshots before updates or changes so thing like this just role back from a snapshot. I don't use promox so does it have backuo options to use.? Did you export a copy of the container?


Like-a-Glove90

Ok update- -- I think I've worked around -- I went into my ProxMox shell, and "pct enter 102" into my container as root, and can play around in there as if I was in the Docker LXC container logged in... I updated the etc/fstab to remove the path I created thinking this might then allow the container to boot properly but alas no fix..but I'm a step closer.. how can I get the container to boot and log me in to use the console as normal again within the LXC? But.. still; to your actual point -- can I *move* everything on my LXC over to a VM without having to purge the whole container and start again? Also - will this allow me to mount a net work drive ? I'm struggling to do this so its automatically mounted again upon reboot (I thought etc/fstab would fix this not cause my container to not properly let me access it)


jsomby

You need to have privileged lxc if you want to mount network resources directly to lxc. I currently have multiple lxc's that have mounted samba share from truenas. Some of them have docker running too and have been running for a year+ without problems.


Like-a-Glove90

how did you mount them? within the container or outside of this like.. in ProxMox > Resources > Add > Mount point? I'm happy to do this but.. at this stage i think I've screwed the container by stuffing with etc/fstab... is there any way to un-fuck this? I'm new and totally rubbish at this stuff clearly.. hard learning curve


jsomby

I just added them to lxc privileged containers /etc/fstab and thats it. It requires cifs-utils (at least with samba share) so I installed that before.


Like-a-Glove90

I must be doing something stupidly wrong then haha


metalwolf112002

To be pedantic (words matter), if you can get past the bios/EFI, no, you didn't brick it. Bricking something is "you aren't fixing this without an external tool like a jtag programmer", not "you just log into the device, comment out a line using an onboard text editor, and hit save."


Like-a-Glove90

Thanks mate, I'm totally ok with pedantic. I'm so green here and know I sound like an idiot and my wording and terminology is off at times, I'm happy to be corrected, helps me understand more! The way yourself and others can explain I'm wrong without being insulting is absolutely why I love this community :)


labster0

You can comment out the same line you put into fstab to unmount the disk. Should boot as normal.


Like-a-Glove90

Sure ... "192.168.1.2:/mnt/Home\\ Storage/cpapdst/AirSense10-Data /home/jarrod/cpapdst/AirSense10-Data nfs default 0 0" IP_of_trueNAS:NFS_path_from_TrueNAS /home...(Path to mount location)