Access files inside LXC

blacklion0221

New Member
May 20, 2024
2
1
3
Hello,

I'm trying to access files within LXC containers. I tried to get a list of all files with "dir" in the LXC cmd, unfortunately without success. I also tried to access the files via FileZilla, but I only found the "*.raw" file there, which I can't do anything with.

I would like to somehow edit the files in the LXC and also download them for editing, how is that possible?

Thanks,
blacklion0221
 
Hello,

I'm trying to access files within LXC containers. I tried to get a list of all files with "dir" in the LXC cmd, unfortunately without success. I also tried to access the files via FileZilla, but I only found the "*.raw" file there, which I can't do anything with.

I would like to somehow edit the files in the LXC and also download them for editing, how is that possible?

Thanks,
blacklion0221

Shutdown the vm. Afterwars you can mount it into the local filesystem of the host to access files.

Code:
# Mount a container into the hosts fs (108 is container ID)

pct mount 108

# Umount a container
pct unmount 108
 
Shutdown the vm. Afterwars you can mount it into the local filesystem of the host to access files.

Code:
# Mount a container into the hosts fs (108 is container ID)

pct mount 108

# Umount a container
pct unmount 108
Thank you for your quick answer!

Have a great day :)
 
  • Like
Reactions: wowo