Installing LXD from APT installs it as a Snap package and while LXC programs are installed from a Debian package, running them tells me I need to install the LXD snap. Is there anyway to install LXC and LXD as a Debian package? Is LXD supposed to supersede LXC?
I am cleaning up my fresh Ubuntu 20.04 install and I can't seem to remove core18
snap.
$ snap list
Name Version Rev Tracking Publisher Notes
core18 20200427 1754 latest/stable canonical✓ base
lxd 4.1 15359 latest/stable/… canonical✓ -
snapd 2.45 7777 latest/stable canonical✓ snapd
$ snap remove core18
error: cannot remove "core18": snap "core18" is not removable: snap is being used by snap lxd.
What IS core18
and why do I need it so much that it won't let me remove it? Most online references I found say it is for IoT or embedded devices. Since my workstation is such a device I don't see why I need it. I am planning to use lxc
containers but why do I need core18
for that?
I have Ubuntu 16.04.6 LTS installed.
Previously I have installed Docker from its repository as docker.io
package.
Yesterday I have installed LXC with LXD and I suppose that they have some problem with coexistence with Docker.
LXC works normally:
$ lxc exec ubuntu-test -- su --login ubuntu-test ~ #
Now when I try to start docker container with docker run
I get error:
docker: Error response from daemon: cgroups: cannot find cgroup mount destination: unknown.
How can I fix this problem with starting Docker containers?
If it is possible please suggest a solution with Docker and LXC/LXD installed in the same time.
Some debug info:
$ mount | grep cgroup
tmpfs on /sys/fs/cgroup type tmpfs (rw,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset,clone_children)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event,release_agent=/run/cgmanager/agents/cgm-release-agent.perf_event)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids,release_agent=/run/cgmanager/agents/cgm-release-agent.pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb,release_agent=/run/cgmanager/agents/cgm-release-agent.hugetlb)
$ dpkg -l | grep -E "containerd|docker|lxc|lxd|cgroup"
ii cgmanager 0.39-2ubuntu5 amd64 Central cgroup manager daemon
ii cgroup-lite 1.11 all Light-weight package to set up cgroups at system boot
ii containerd 1.2.6-0ubuntu1~16.04.3 amd64 daemon to control runC
ii docker.io 18.09.7-0ubuntu1~16.04.5 amd64 Linux container runtime
ii libcgmanager0:amd64 0.39-2ubuntu5 amd64 Central cgroup manager daemon (client library)
ii liblxc1 2.0.11-0ubuntu1~16.04.3 amd64 Linux Containers userspace tools (library)
ii libpam-cgfs 2.0.8-0ubuntu1~16.04.2 amd64 PAM module for managing cgroups for LXC
ii lxc-common 2.0.11-0ubuntu1~16.04.3 amd64 Linux Containers userspace tools (common tools)
ii lxc-templates 2.0.11-0ubuntu1~16.04.3 amd64 Linux Containers userspace tools (templates)
ii lxc1 2.0.11-0ubuntu1~16.04.3 amd64 Linux Containers userspace tools
ii lxcfs 2.0.8-0ubuntu1~16.04.2 amd64 FUSE based filesystem for LXC
ii lxd 2.0.11-0ubuntu1~16.04.4 amd64 Container hypervisor based on LXC - daemon
ii lxd-client 2.0.11-0ubuntu1~16.04.4 amd64 Container hypervisor based on LXC - client
ii python3-lxc 2.0.11-0ubuntu1~16.04.3 amd64 Linux Containers userspace tools (Python 3.x bindings)
$ systemctl list-units --type service
UNIT LOAD ACTIVE SUB JOB DESCRIPTION
accounts-daemon.service loaded active running Accounts Service
acpid.service loaded active running ACPI event daemon
alsa-restore.service loaded active exited Save/Restore Sound Card State
apparmor.service loaded active exited LSB: AppArmor initialization
apport.service loaded active exited LSB: automatic crash report generation
atd.service loaded active running Deferred execution scheduler
avahi-daemon.service loaded active running Avahi mDNS/DNS-SD Stack
avahi-dnsconfd.service loaded active running Avahi DNS Configuration Daemon
binfmt-support.service loaded active exited Enable support for additional executable binary formats
bluetooth.service loaded active running Bluetooth service
cgmanager.service loaded active running Cgroup management daemon
cgroupfs-mount.service loaded active exited LSB: Set up cgroupfs mounts.
click-system-hooks.service loaded active exited Run Click system-level hooks
colord.service loaded active running Manage, Install and Generate Color Profiles
console-kit-daemon.service loaded active running Console Manager
console-kit-log-system-start.service loaded active exited Console System Startup Logging
console-setup.service loaded active exited Set console font and keymap
containerd.service loaded active running containerd container runtime
cpufrequtils.service loaded active exited LSB: set CPUFreq kernel parameters
cron.service loaded active running Regular background program processing daemon
cups-browsed.service loaded active running Make remote CUPS printers available locally
cups.service loaded active running CUPS Scheduler
dbus.service loaded active running D-Bus System Message Bus
docker.service loaded inactive dead start Docker Application Container Engine
ebtables.service loaded active exited LSB: ebtables ruleset management
[email protected] loaded inactive dead start Getty on tty1
gpm.service loaded active running LSB: gpm sysv init script
gpsd.service loaded active running GPS (Global Positioning System) Daemon
grub-common.service loaded active exited LSB: Record successful boot for GRUB
hddtemp.service loaded inactive dead start LSB: disk temperature monitoring daemon
iio-sensor-proxy.service loaded active running IIO Sensor Proxy service
inetd.service loaded active running Internet superserver
irqbalance.service loaded active running LSB: daemon to balance interrupts for SMP systems
keyboard-setup.service loaded active exited Set console keymap
kmod-static-nodes.service loaded active exited Create list of required static device nodes for the curre
libvirt-bin.service loaded active running Virtualization daemon
libvirt-guests.service loaded active exited Suspend Active Libvirt Guests
lightdm.service loaded active running Light Display Manager
lm-sensors.service loaded active exited Initialize hardware monitoring sensors
loadcpufreq.service loaded active exited LSB: Load kernel modules needed to enable cpufreq scaling
lvm2-lvmetad.service loaded active running LVM2 metadata daemon
lvm2-monitor.service loaded active exited Monitoring of LVM2 mirrors, snapshots etc. using dmeventd
lxc-net.service loaded inactive dead start LXC network bridge setup
lxc.service loaded inactive dead start LXC Container Initialization and Autoboot Code
lxcfs.service loaded active running FUSE filesystem for LXC
lxd-bridge.service loaded active exited LXD - network bridge
lxd-containers.service loaded activating start start LXD - container startup/shutdown
lxd.service loaded inactive dead start LXD - main daemon
mdadm.service loaded active running LSB: MD monitoring daemon
ModemManager.service loaded active running Modem Manager
networking.service loaded active exited Raise network interfaces
NetworkManager-wait-online.service loaded activating start start Network Manager Wait Online
NetworkManager.service loaded active running Network Manager
nfs-config.service loaded active exited Preprocess NFS configuration
nmbd.service loaded inactive dead start LSB: start Samba NetBIOS nameserver (nmbd)
ntp.service loaded inactive dead start LSB: Start NTP daemon
ofono.service loaded active running oFono Mobile telephony stack
ondemand.service loaded active running LSB: Set the CPU Frequency Scaling governor to "ondemand"
openvpn.service loaded active exited OpenVPN service
osspd.service loaded active running OSS Proxy Daemon
plymouth-quit-wait.service loaded inactive dead start Hold until boot process finishes up
polipo.service loaded active running LSB: Start or stop the polipo web cache
polkitd.service loaded active running Authenticate and Authorize Users to Run Privileged Tasks
postgresql.service loaded active exited PostgreSQL RDBMS
qemu-kvm.service loaded active exited LSB: QEMU KVM module loading script
rc-local.service loaded inactive dead start /etc/rc.local Compatibility
resolvconf.service loaded active exited Nameserver information manager
rsyslog.service loaded active running System Logging Service
rtkit-daemon.service loaded active running RealtimeKit Scheduling Policy Service
samba-ad-dc.service loaded inactive dead start LSB: start Samba daemons for the AD DC
schroot.service loaded inactive dead start LSB: Recover schroot sessions.
setvtrgb.service loaded inactive dead start Set console scheme
smartd.service loaded active running Self Monitoring and Reporting Technology (SMART) Daemon
smbd.service loaded inactive dead start LSB: start Samba SMB/CIFS daemon (smbd)
speech-dispatcher.service loaded active exited LSB: Speech Dispatcher
ssh.service loaded active running OpenBSD Secure Shell server
sysstat.service loaded active exited LSB: Start/stop sysstat's sadc
systemd-backlight@backlight:intel_backlight.service loaded active exited Load/Save Screen Backlight Brightness of backlight:intel_
systemd-backlight@leds:asus::kbd_backlight.service loaded active exited Load/Save Screen Backlight Brightness of leds:asus::kbd_b
systemd-fsck@dev-disk-by\x2duuid-1207\x2d4052.service loaded active exited File System Check on /dev/disk/by-uuid/1207-4052
systemd-fsck@dev-disk-by\x2duuid-4a44edd5\x2dd396\x2d443e\x2d9a6a\x2d41a81be97246.service loaded active exited File System Check on /dev/disk/by-uuid/4a44edd5-d396-443e
systemd-fsckd.service loaded active running File System Check Daemon to report status
systemd-hostnamed.service loaded active running Hostname Service
systemd-journal-flush.service loaded active exited Flush Journal to Persistent Storage
systemd-journald.service loaded active running Journal Service
systemd-logind.service loaded active running Login Service
systemd-modules-load.service loaded active exited Load Kernel Modules
systemd-random-seed.service loaded active exited Load/Save Random Seed
systemd-remount-fs.service loaded active exited Remount Root and Kernel File Systems
systemd-sysctl.service loaded active exited Apply Kernel Variables
systemd-tmpfiles-setup-dev.service loaded active exited Create Static Device Nodes in /dev
systemd-tmpfiles-setup.service loaded active exited Create Volatile Files and Directories
systemd-udev-trigger.service loaded active exited udev Coldplug all Devices
systemd-udevd.service loaded active running udev Kernel Device Manager
systemd-update-utmp-runlevel.service loaded inactive dead start Update UTMP about System Runlevel Changes
systemd-update-utmp.service loaded active exited Update UTMP about System Boot/Shutdown
systemd-user-sessions.service loaded active exited Permit User Sessions
sysvinit-backlight.service loaded active exited LSB: Save and restore screen and keyboard backlight level
thermald.service loaded active running Thermal Daemon Service
timidity.service loaded active running LSB: start and stop timidity
tor.service loaded active exited Anonymizing overlay network for TCP (multi-instance-maste
[email protected] loaded active running Anonymizing overlay network for TCP
ubuntu-fan.service loaded inactive dead start Ubuntu FAN network setup
udisks.service loaded active running Disk Manager (legacy version)
udisks2.service loaded active running Disk Manager
ufw.service loaded active exited Uncomplicated firewall
upower.service loaded active running Daemon for power management
[email protected] loaded active running User Manager for UID 1000
[email protected] loaded active running User Manager for UID 104
vboxautostart-service.service loaded active exited vboxautostart-service.service
vboxballoonctrl-service.service loaded active exited vboxballoonctrl-service.service
vboxdrv.service loaded active exited VirtualBox Linux kernel module
vboxweb-service.service loaded active running vboxweb-service.service
whoopsie.service loaded inactive dead start crash report submission daemon
winbind.service loaded inactive dead start LSB: start Winbind daemon
wpa_supplicant.service loaded active running WPA supplicant
LOAD = Reflects whether the unit definition was properly loaded.
ACTIVE = The high-level unit activation state, i.e. generalization of SUB.
SUB = The low-level unit activation state, values depend on unit type.
JOB = Pending job for the unit.
116 loaded units listed. Pass --all to see loaded but inactive units, too.
To show all installed unit files use 'systemctl list-unit-files'.
Update after removing all images and containers and adding -D
to docker service:
$ docker run -it ubuntu:18.04
Unable to find image 'ubuntu:18.04' locally
18.04: Pulling from library/ubuntu
35c102085707: Pull complete
251f5509d51d: Pull complete
8e829fe70a46: Pull complete
6001e1789921: Pull complete
Digest: sha256:d1d454df0f579c6be4d8161d227462d69e163a8ff9d20a847533989cf0c94d90
Status: Downloaded newer image for ubuntu:18.04
docker: Error response from daemon: cgroups: cannot find cgroup mount destination: unknown.
$ tail -f /var/log/syslog | grep docker
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.235977407+03:00" level=debug msg="Calling GET /_ping"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.239220453+03:00" level=debug msg="Calling POST /v1.39/containers/create"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.239802159+03:00" level=debug msg="form data: {\"AttachStderr\":true,\"AttachStdin\":true,\"AttachStdout\":true,\"Cmd\":null,\"Domainname\":\"\",\"Entrypoint\":null,\"Env\":[],\"HostConfig\":{\"AutoRemove\":false,\"Binds\":null,\"BlkioDeviceReadBps\":null,\"BlkioDeviceReadIOps\":null,\"BlkioDeviceWriteBps\":null,\"BlkioDeviceWriteIOps\":null,\"BlkioWeight\":0,\"BlkioWeightDevice\":[],\"CapAdd\":null,\"CapDrop\":null,\"Cgroup\":\"\",\"CgroupParent\":\"\",\"ConsoleSize\":[0,0],\"ContainerIDFile\":\"\",\"CpuCount\":0,\"CpuPercent\":0,\"CpuPeriod\":0,\"CpuQuota\":0,\"CpuRealtimePeriod\":0,\"CpuRealtimeRuntime\":0,\"CpuShares\":0,\"CpusetCpus\":\"\",\"CpusetMems\":\"\",\"DeviceCgroupRules\":null,\"Devices\":[],\"DiskQuota\":0,\"Dns\":[],\"DnsOptions\":[],\"DnsSearch\":[],\"ExtraHosts\":null,\"GroupAdd\":null,\"IOMaximumBandwidth\":0,\"IOMaximumIOps\":0,\"IpcMode\":\"\",\"Isolation\":\"\",\"KernelMemory\":0,\"Links\":null,\"LogConfig\":{\"Config\":{},\"Type\":\"\"},\"MaskedPaths\":null,\"Memory\":0,\"MemoryReservation\":0,\"MemorySwap\":0,\"MemorySwappiness\":-1,\"NanoCpus\":0,\"NetworkMode\":\"default\",\"OomKillDisable\":false,\"OomScoreAdj\":0,\"PidMode\":\"\",\"PidsLimit\":0,\"PortBindings\":{},\"Privileged\":false,\"PublishAllPorts\":false,\"ReadonlyPaths\":null,\"ReadonlyRootfs\":false,\"RestartPolicy\":{\"MaximumRetryCount\":0,\"Name\":\"no\"},\"SecurityOpt\":null,\"ShmSize\":0,\"UTSMode\":\"\",\"Ulimits\":null,\"UsernsMode\":\"\",\"VolumeDriver\":\"\",\"VolumesFrom\":null},\"Hostname\":\"\",\"Image\":\"ubuntu:18.04\",\"Labels\":{},\"NetworkingConfig\":{\"EndpointsConfig\":{}},\"OnBuild\":null,\"OpenStdin\":true,\"StdinOnce\":true,\"Tty\":true,\"User\":\"\",\"Volumes\":{},\"WorkingDir\":\"\"}"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.276281207+03:00" level=debug msg="container mounted via layerStore: &{/var/lib/docker/overlay2/60b7962391f9c3670d264b3d8a4982bbebe01cf9283220395c2ca812747a40eb/merged 0x55bf84d46900 0x55bf84d46900}"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.303132923+03:00" level=debug msg="Calling POST /v1.39/containers/5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9/attach?stderr=1&stdin=1&stdout=1&stream=1"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.303320604+03:00" level=debug msg="attach: stdin: begin"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.303347334+03:00" level=debug msg="attach: stdout: begin"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.303367047+03:00" level=debug msg="attach: stderr: begin"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.303750204+03:00" level=debug msg="Calling POST /v1.39/containers/5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9/wait?condition=next-exit"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.304842547+03:00" level=debug msg="Calling POST /v1.39/containers/5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9/start"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.306444389+03:00" level=debug msg="container mounted via layerStore: &{/var/lib/docker/overlay2/60b7962391f9c3670d264b3d8a4982bbebe01cf9283220395c2ca812747a40eb/merged 0x55bf84d46900 0x55bf84d46900}"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.307074242+03:00" level=debug msg="Assigning addresses for endpoint elated_franklin's interface on network bridge"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.307378411+03:00" level=debug msg="RequestAddress(LocalDefault/172.17.0.0/16, <nil>, map[])"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.307682670+03:00" level=debug msg="Request address PoolID:172.17.0.0/16 App: ipam/default/data, ID: LocalDefault/172.17.0.0/16, DBIndex: 0x0, Bits: 65536, Unselected: 65533, Sequence: (0xc0000000, 1)->(0x0, 2046)->(0x1, 1)->end Curr:3 Serial:false PrefAddress:<nil> "
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.333117713+03:00" level=debug msg="Assigning addresses for endpoint elated_franklin's interface on network bridge"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.352988148+03:00" level=debug msg="Programming external connectivity on endpoint elated_franklin (e6aaedb79f9b4df830da55a224ef60162d48952451294c856efcacd1b4d8f2ef)"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.359846164+03:00" level=debug msg="EnableService 5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9 START"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.359866210+03:00" level=debug msg="EnableService 5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9 DONE"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.366442322+03:00" level=debug msg="bundle dir created" bundle=/var/run/docker/containerd/5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9 module=libcontainerd namespace=moby root=/var/lib/docker/overlay2/60b7962391f9c3670d264b3d8a4982bbebe01cf9283220395c2ca812747a40eb/merged
Sep 7 20:57:34 norbert-UX32A NetworkManager[1224]: <info> [1567879054.5349] device (docker0): link connected
Sep 7 20:57:34 norbert-UX32A kernel: [43763.811967] docker0: port 1(vethca4e1e2) entered forwarding state
Sep 7 20:57:34 norbert-UX32A kernel: [43763.811996] docker0: port 1(vethca4e1e2) entered forwarding state
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.541099717+03:00" level=debug msg="sandbox set key processing took 82.724835ms for container 5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.831828501+03:00" level=debug msg="attach: stdout: end"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.831830570+03:00" level=debug msg="attach: stderr: end"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.831871441+03:00" level=debug msg="attach: stdin: end"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.831893135+03:00" level=debug msg="attach done"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.831942207+03:00" level=debug msg="Closing buffered stdin pipe"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.848047063+03:00" level=debug msg="Revoking external connectivity on endpoint elated_franklin (e6aaedb79f9b4df830da55a224ef60162d48952451294c856efcacd1b4d8f2ef)"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.849567170+03:00" level=debug msg="DeleteConntrackEntries purged ipv4:0, ipv6:0"
Sep 7 20:57:34 norbert-UX32A kernel: [43764.133221] docker0: port 1(vethca4e1e2) entered disabled state
Sep 7 20:57:34 norbert-UX32A NetworkManager[1224]: <info> [1567879054.8855] device (docker0): link disconnected (deferring action for 4 seconds)
Sep 7 20:57:34 norbert-UX32A kernel: [43764.172680] docker0: port 1(vethca4e1e2) entered disabled state
Sep 7 20:57:34 norbert-UX32A kernel: [43764.176152] docker0: port 1(vethca4e1e2) entered disabled state
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.948202159+03:00" level=debug msg="Releasing addresses for endpoint elated_franklin's interface on network bridge"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.948233303+03:00" level=debug msg="ReleaseAddress(LocalDefault/172.17.0.0/16, 172.17.0.2)"
Sep 7 20:57:34 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:34.948272022+03:00" level=debug msg="Released address PoolID:LocalDefault/172.17.0.0/16, Address:172.17.0.2 Sequence:App: ipam/default/data, ID: LocalDefault/172.17.0.0/16, DBIndex: 0x0, Bits: 65536, Unselected: 65532, Sequence: (0xe0000000, 1)->(0x0, 2046)->(0x1, 1)->end Curr:3"
Sep 7 20:57:35 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:35.004894384+03:00" level=error msg="5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9 cleanup: failed to delete container from containerd: no such container"
Sep 7 20:57:35 norbert-UX32A dockerd[29727]: time="2019-09-07T20:57:35.004928780+03:00" level=error msg="Handler for POST /v1.39/containers/5d737b86472cdeecc20de8e6fa3f86f71bd7e53c3e59dcc68da0c911bcade3b9/start returned error: cgroups: cannot find cgroup mount destination: unknown"
Sep 7 20:57:39 norbert-UX32A NetworkManager[1224]: <info> [1567879059.5208] device (docker0): link disconnected (calling deferred action)
I need to run old version of application in chroot
(or container) and allow DBus interaction with host system. I can't install this application on host system because of serious dependency problems.
Full details about applications:
- application to be containerized is GNOME Evolution version 3.2.3 (from Ubuntu 12.04 LTS)
- the host system is Ubuntu MATE 16.04 LTS, it will run back-ported
indicator-datetime-gtk2
, which communicates with containerized Evolution through D-BUS.
I hope that it is technically possible with schroot
's bind mounts or LXC/LXD.
How should I set up such configuration?
I have a host machine (KVM with Kubuntu 18.04) with a LXD guest (based on ubuntu18.04 image).
I can ssh from guest to host.
But trying to ssh from host to guest gives an
Permission denied (publickey)
error
Step to reproduce:
- lxc exec into the guest
- exec login with ubuntu user (to avoid root permissions problems)
- ssh to host - SUCCESS
- exit form user ubuntu - exit from guest
- from host ssh into ubuntu@guest - ERROR
What I'm doing wrong?
Below the complete session transcript
sysop@kvmneo4j:~$ lxc list
+----------+---------+-------------------+------+------------+-----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+----------+---------+-------------------+------+------------+-----------+
| base1804 | RUNNING | 10.0.0.205 (eth0) | | PERSISTENT | 0 |
+----------+---------+-------------------+------+------------+-----------+
sysop@kvmneo4j:~$ lxc exec base1804 bash
root@base1804:~# exec login ubuntu
Password:
Last login: Wed Jan 2 18:58:10 UTC 2019 on UNKNOWN
Welcome to Ubuntu 18.04.1 LTS (GNU/Linux 4.15.0-43-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Wed Jan 2 19:02:28 UTC 2019
System load: 1.69 Processes: 22
Usage of /home: unknown Users logged in: 0
Memory usage: 1% IP address for eth0: 10.0.0.205
Swap usage: 0%
Get cloud support with Ubuntu Advantage Cloud Guest:
http://www.ubuntu.com/business/services/cloud
0 packages can be updated.
0 updates are security updates.
Failed to connect to https://changelogs.ubuntu.com/meta-release-lts. Check your Internet connection or proxy settings
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.
ubuntu@base1804:~$ ssh [email protected]
[email protected]'s password:
Welcome to Ubuntu 18.04.1 LTS (GNU/Linux 4.15.0-43-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
* Canonical Livepatch is available for installation.
- Reduce system reboots and improve kernel security. Activate at:
https://ubuntu.com/livepatch
Failed to connect to https://changelogs.ubuntu.com/meta-release-lts. Check your Internet connection or proxy settings
Last login: Wed Jan 2 19:58:42 2019 from 10.0.0.205
sysop@kvmneo4j:~$ logout
Connection to 10.0.0.1 closed.
ubuntu@base1804:~$ logout
sysop@kvmneo4j:~$ ssh -v [email protected]
OpenSSH_7.6p1 Ubuntu-4ubuntu0.1, OpenSSL 1.0.2n 7 Dec 2017
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to 10.0.0.205 [10.0.0.205] port 22.
debug1: Connection established.
debug1: identity file /home/sysop/.ssh/id_rsa type 0
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/sysop/.ssh/id_ed25519-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.1
debug1: Remote protocol version 2.0, remote software version OpenSSH_7.6p1 Ubuntu-4ubuntu0.1
debug1: match: OpenSSH_7.6p1 Ubuntu-4ubuntu0.1 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 10.0.0.205:22 as 'ubuntu'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: [email protected] MAC: <implicit> compression: none
debug1: kex: client->server cipher: [email protected] MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:i0Ezo01qJyhIue4PIRobOw/qKuvDW/7OJZzgB0X5jGM
debug1: Host '10.0.0.205' is known and matches the ECDSA host key.
debug1: Found key in /home/sysop/.ssh/known_hosts:1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: RSA SHA256:EfYKpv5N+M8YBgCFjjy3P9M0jYt7DObq9ApoZ0G8qL4 /home/sysop/.ssh/id_rsa
debug1: Authentications that can continue: publickey
debug1: Trying private key: /home/sysop/.ssh/id_dsa
debug1: Trying private key: /home/sysop/.ssh/id_ecdsa
debug1: Trying private key: /home/sysop/.ssh/id_ed25519
debug1: No more authentication methods to try.
[email protected]: Permission denied (publickey).
sysop@kvmneo4j:~$