Skip to main content

Questions tagged [lxc]

Linux Containers (LXC) is a userspace interface for operating system-level virtualization features in the mainline Linux kernel, such as kernel namespaces and control groups (cgroups). These allow multiple distinct user space instances to be run on a single kernel. Note: the 3 letters "lxc" command is part of LXD, not LXC. Please use the LXD tag if your question is about LXD rather than only about LXC.

Filter by
Sorted by
Tagged with
0 votes
0 answers
35 views

How to share a GPU with LXC?

I have some GNOME wayland Linux installs in KVM using virt-manager with spicevmc on Debian 12 that are performant with default settings. I added a LXC instance to virt-manager. How can I get a spice, ...
user1133275's user avatar
  • 5,566
0 votes
0 answers
18 views

How to start one Linux container from another?

On Chromebook Crostini Linux I can (via .ssh/authorized_keys) stop one container from another, jidanni@n1:~$ ssh n2 sudo shutdown -h now But starting it requires crosh> vmc start termina (termina)...
Dan Jacobson's user avatar
0 votes
0 answers
42 views

Prevent OOM killer inside guest in LXC

I have a python program myprogram.py. I realized that my python program is being killed due to Out Of Memory (OOM). But, I noticed also that my VPS is inside LXC and has swap 1GB, when the memory full ...
Muhammad Ikhwan Perwira's user avatar
0 votes
0 answers
35 views

External usb SSD Restic/Backrest backup automation

I've a zimaboard micro server with proxmox and a debian 10 CT that is delegate for backup system (Restic/Backrest) with an external usb ssd always attached. It is possible to pilote the external usb ...
Alessandro's user avatar
0 votes
1 answer
83 views

Incus - Setting migration.stateful for stateful snapshots

I'm trying to get to grips with Incus, because it looks like it is a fork of Canonical's LXD, which I can run fairly easily on Debian 12 with a deb package, rather than using snaps. I have it all set ...
Programster's user avatar
  • 2,279
2 votes
1 answer
42 views

Why does "pgrep -O 600" fail in an LXC? procps bug?

Debian 12.2 in an unpriviledged LXC (proxmox). It's almost 11:45 AM local time. At 5:00 AM in the morning, cron started a script: USER PID %CPU %MEM VSZ RSS TTY STAT START TIME ...
Jan's user avatar
  • 7,782
0 votes
0 answers
154 views

Waydroid installation break config

I have followed the install instructions here : https://docs.waydro.id/usage/install-on-desktops. I use Debian 12 with Gnome 43.6 and X11 on Dell inspiron 15 laptop. After installation I figured out ...
larum's user avatar
  • 1
0 votes
1 answer
848 views

Obtain a Wordpress Website with a Proxmox container available from outside with https (ssl encryption)

My prelimanary actions: setting up a ddns hostname with noip service (ok) configured to automatically keep alive the association on my home router(ok) installed a proxmox server v8 (ok) create a lxc ...
Alessandro's user avatar
1 vote
0 answers
213 views

How can I import lxc containers back from the snapshots the lxc create just before the `lxc snap` is removed?

I have the following situation: I have an Ubuntu 22.04 node, which used to have lxd v5 installed through snap. It used to have 3 containers, at the moment of remove the lxd using the snap remove lxd ...
k.Cyborg's user avatar
  • 507
1 vote
1 answer
110 views

Remote SMTP traffic appears to come from LXC Host to container

Summary: I have a mail server (exim 4, Debian 10) in an LXC container. The host is running Debian 11. Since yesterday evening spam traffic has been coming in that appears to come from the LXC Host. ...
Lennart's user avatar
  • 13
3 votes
0 answers
630 views

udev inside lxc container

I am running a privileged Debian LXC Container on Proxmox, and then running Docker inside that. I am attempting to run an Xserver in a Docker container with Sunshine to stream to a Moonlight client. I ...
Dennis George's user avatar
9 votes
1 answer
2k views

"Error: Too many open files" while starting service in environment with several LXCs

Environment: I am using a CentOS-7 as a hypervisor for running several LXCs under libvirt. Each container runs a minimal installation of CentOS-7 with cut down FreePBX (Asterisk, Apache, MySQL + bits)....
AnyDev's user avatar
  • 749
0 votes
0 answers
194 views

Configure IPv6 DNS server via DHCP in LXC container

I have an LXC container created and started as follows: sudo lxc-create -t debian -n mylxc -- --release bullseye sudo lxc-start -n mylxc sudo lxc-attach -n mylxc On the LXC host I have a DHCP server ...
carlfriedrich's user avatar
1 vote
2 answers
1k views

LXD ZFS storage pool on lvm filesystem?

The default filesystem of my machine is lvm (Ubuntu 22.04). I would like to spin up LXD/LXC virtual machines to run some Apache projects like Hadoop and Spark. When setting up Hadoop there is a step ...
Mnemosyne's user avatar
  • 161
0 votes
1 answer
2k views

How to SSH to a host and attach an LXC container in one command, properly?

I'd like to connect to a LXC container through Proxmox via SSH without having SSH access to the container itself, so I can get the desired outcome by connecting to the Proxmox host first and then ...
Martin Braun's user avatar
0 votes
0 answers
1k views

LXC - using generated apparmor profiles, but apparmor status shows unconfined

I have been using unprivileged lxc containers (running as root but with user namespaces) using the following config to make use of apparmor: lxc.apparmor.profile = generated lxc.apparmor.allow_nesting ...
4oo4's user avatar
  • 153
6 votes
2 answers
6k views

No network in Waydroid: network is unreachable

I've followed Waydroid arch-wiki page and have installed waydroid, binder_linux-dkms and waydroid-image-gapps. When I run waydroid it works perfectly except for the network part. I do have new ...
petRUShka's user avatar
  • 1,312
0 votes
3 answers
5k views

What is the ID of nobody user and nogroup group?

When trying LXD, I tried to share a folder from my computer with the LXC Container, but I could not write in the folder in the container because ls -l shows that it belongs to user nobody and group ...
Ruben Alves's user avatar
3 votes
4 answers
707 views

Persist resolvectl changes across reboots

I'm using LXC containers, and resolving CONTAINERNAME.lxd to the IP of the specified container, using: sudo resolvectl dns lxdbr0 $bridge_ip sudo resolvectl domain lxdbr0 '~lxd' This works great! But ...
Jonathan Hartley's user avatar
0 votes
1 answer
661 views

How can I monitor individual containers resource usage in LXD/C

I would like to be able to view which individual containers are using what percentage of CPU, memory etc. I have installed HTOP but it doesn't tell me which container, and I have 20+ containers ...
unixlearner's user avatar
1 vote
0 answers
469 views

How to set permissions for passthrough USB device in libvirt LXC guest?

I have an lxc type guest in libvirt to which I pass through a USB device like this: <hostdev mode="subsystem" type="usb" managed="yes"> <source> <...
al.'s user avatar
  • 309
0 votes
1 answer
2k views

Docker on Debian Failing to Bind to Port 80

I am running Docker on Debian 11. I deploy an Nginx container and it fails to bind to port 80 even though port 80 is not in use by any other process. I even tried running Docker as root. Here's the ...
Krishna Chaitanya's user avatar
2 votes
2 answers
747 views

Why is the Linux command `unshare --pid=p --mount=m` not creating a persistent namespace?

From everything I have read in the unshare and nsenter man pages, I should be able to bind-mount a directory to itself, mount --make-private the directory, and then use files within that directory to ...
KJ7LNW's user avatar
  • 495
1 vote
1 answer
254 views

LXC: exposed file from host has 000 permissions in rootfs dir

I have the following in the /var/lib/lxc/container1/config so my container can see the file from the host. lxc.mount.entry = /etc/someconf.conf etc/someconf.conf none bind,create=file 0 0 I can see ...
donkihott's user avatar
4 votes
1 answer
1k views

Why is systemd stuck at 100% inside my new Ubuntu LXC container?

I am trying to create an LXC container with xubuntu desktop inside it. This is on a fresh Ubuntu 22.04 install with sudo lxc launch images:ubuntu/22.04 workstation executed to create the container, ...
Josh's user avatar
  • 8,508
1 vote
1 answer
174 views

Is it possible to use a file as Filesystem?

Here is the origin of my question: I'm running Linux containers with LXD snap version at Ubuntu 22.04 on a VPS. The root file system of the VPS is Ext4 and there is not additional storage attached. ...
pa4080's user avatar
  • 121
0 votes
0 answers
4k views

dmesg: read kernel buffer failed: Permission denied with root user in LXC container after Ubuntu upgrade

I had an LXC container running in Proxmox with Ubuntu 21.04. In this container dmesg worked as expected with a root user. I used do-release-upgrade and successfully upgraded the LXC container to ...
automaton's user avatar
  • 101
1 vote
2 answers
1k views

Cannot autostart unprivileged LXC containers on Debian 11 Bullseye

lxc-autostart won't start unprivileged containers in Debian 11 Bullseye. Start of unprivileged container in Debian 11 Bullseye was solved in this answer by using lxc-unpriv-start instead of lxc-start ...
mprudek's user avatar
  • 51
1 vote
0 answers
1k views

systemd-logind.service doesn't work (NAMESPACE error)

The problem that occurred to me goes as follows. I became the admin of a recently launched Linux machine. The specs are: Kernel: 5.13.19-1-pve OS: Debian GNU/Linux 11 (bullseye) At first, I noticed ...
Grzegorz Skrzyński's user avatar
0 votes
0 answers
431 views

How to use screen inside of an LXC container

I am using Proxmox 7.0 to run an LXC container with Debian 11 as guest. When connecting via ssh to the guest, I can install and run screen as usual. I can detach and re-attach as usual. But if I ...
masgo's user avatar
  • 272
0 votes
1 answer
1k views

Connection refused between 2 linux containers

On my host Ubuntu 18.04 I am running two lxc containers using default setups. Containers use Ubuntu 18.04 as well. I have an app running on container1 that offers an https based service on https://...
Mnemosyne's user avatar
  • 161
1 vote
1 answer
4k views

How can I display a GUI LXC container on a physically connected display without a window manager?

I want to have a setup where I have LXC OS containers that start full-screen on particular displays. As an intermediate step, I am trying to get X apps from the container to display via host X. I have ...
Stonecraft's user avatar
0 votes
0 answers
78 views

LXD Container fails to SSH out to AWS

Workstation -> Local LXC -> AWS I have copied over the .ssh keys and config from my main workstation into an LXD container on it. I have also cleared my ip tables which was an issue with docker ...
Michael Paccione's user avatar
0 votes
1 answer
519 views

How can I fix etckeeper or uninstall it so apt will install / remove new packages?

OS: Debian Buster 10.10 inside lxc I am attempting to install a new package (I tried different packages) and apt (and DPkg) is complaining with the following error message(s): /etc/etckeeper/pre-...
Wilhelm de Fheur Gorm's user avatar
4 votes
1 answer
5k views

Cannot start unprivileged LXC containers on Debian 11 Bullseye

I've made a new installation of Debian 11. Regarding LXC, I copied the working setup of my Debian 10 computer. I use a separate user, lxcuser which I su to, to lxc-start. The configuration, ~/.config/...
Krackout's user avatar
  • 2,742
0 votes
0 answers
1k views

How to route LXC container traffic through Wireguard tunnel?

The image shows a complete picture of what I'm building. But for now I want to implement a small part with one home server and 2 LXC, 2 ipv4 on a remote server. I want to use 2 different Wireguard ...
Alex's user avatar
  • 1
0 votes
0 answers
283 views

How to assign a remote public ip (via wireguard) to lxc container

What I have: lxc host # ifconfig wg1: flags=209<UP,POINTOPOINT,RUNNING,NOARP> mtu 1420 inet 192.168.7.2 netmask 255.255.255.0 destination 192.168.7.2 ... enp2s0: flags=4163<UP,BROADCAST,...
Alex's user avatar
  • 1
0 votes
0 answers
58 views

How to attach 10 ipv4 from remote server to home lxc containers?

There is a remote ubuntu server with 10 ipv4. There is a home ubuntu server without external ipv4. The home server has 10 lxc containers.
 How to make each lxc container has own ipv4? Upd I want to ...
Alex's user avatar
  • 1
1 vote
0 answers
82 views

LXC container bridge with host network risks?

I'm new to LXC containers and still very much learning what is what. I want to run a container bridged to the host network (e.g. 192.168.0.0). This is required because the application I want to run ...
sjaak's user avatar
  • 604
0 votes
1 answer
364 views

lxc containers can ping host and can resolve dns internet addresses but cannot get to the internet

Debian Buster amd64 Two containers, 192.168.122.2,3 both can resolve but cannot get to the Internet Both containers can ping / interact with the host server. Here is what I have in iptables. # ...
Wilhelm de Fheur Gorm's user avatar
2 votes
1 answer
1k views

Command executing outside container with lxc-attach?

I am trying to do a more complicated task inside a running lxc ubuntu container, but my problem can be explained using this simple example. When I run sudo lxc-attach -n container1 -- echo "test&...
sucks-at-javascript's user avatar
4 votes
3 answers
3k views

lxc-start tells me apparmor_parser not available even though apparmor is installed and running

System:Debian Testing (Bullseye) I am trying to get an LXC container up and running as per here, however, when I get to lxc-start -n my-container -d I get the following: $ lxc-start -n test1 -d lxc-...
Enter Display Name Here's user avatar
1 vote
1 answer
420 views

It is possible to use parallel compression method in lxc publish?

To generate images LXD compresses files using gzip, which can only use one core. Thus, creating images can be very slow with large containers. I would like to use other compressors (e.g., pigz). What ...
Daniel Hernández's user avatar
0 votes
1 answer
130 views

Is possible to identify the LXC unprivileged container owner of process?

I have a linux server, Debian buster with LXC configured for unprivileged containers. I have also a lot of crash from sssd_be, dmesg from server said: dmesg|grep segfault sssd_be[6739]: segfault at 8 ...
elbarna's user avatar
  • 12.8k
2 votes
0 answers
674 views

Start armv7 container on arm64 with lxc / lxd

I installed Ubuntu 20.04 on my Raspberry PI, which has an arm64v8 architecture (but could be on any other debian arm distribution / hardware). Currently I compile a program for several arm ...
User Rebo's user avatar
  • 121
0 votes
1 answer
153 views

Why this script works fine if run as user, but faili if run from rc.local?

I have some troubles with lxc unprivileged containers on Debian. I follow this method: a)I create the user unprivileged with home in /var/lxcunpriv useradd -m -d /var/lxcunpriv lxcunpriv b)I install ...
elbarna's user avatar
  • 12.8k
1 vote
0 answers
888 views

Run KVM inside LXC container

I have a baremetal server with Debian. Iside it I have KVM-based VMs and LXC containers. Now I am searching a solution to run KVM inside LXC container.
512yottabytes's user avatar
2 votes
1 answer
1k views

LXC, Docker and iptables on the same host, timeout on port-forwarding from the container to the container

thanks for reading! I have a publicly exposed server (debian 10), used as an host, running both LXC (not LXD) and Docker. These two container services are running with a mostly original configuration (...
ma2thias's user avatar
2 votes
0 answers
629 views

Solution: How come that lxc-attach doesn't work within su -c?

I have an unprivileged lxc container. It works well and if I need to do something within that container, I su --login lxc-user, then I do lxc-attach -e -n lxc-container for e. g. doing updates ...
killerhippy's user avatar
2 votes
2 answers
4k views

disk quota exceeded when trying to deploy Docker container inside LXC

I have an LXC container running docker. Many containers are running successfully but I am unable to add more; I am trying to deploy a new docker container and getting the following error: container ...
Josh's user avatar
  • 8,508

1
2 3 4 5
7