LXC Troubleshoot




當啟動過 Config 有誤的 VPS 後, 再也 start 不到那 VPS

lxc-start -n debian6

lxc-start: write /sys/fs/cgroup/devices//lxc/debian6/devices.allow : Invalid argument

lxc-start -n debian6

lxc-start: Device or resource busy - failed to remove cgroup '/sys/fs/cgroup/cpuset//lxc/debian6'

不過那時什麼都沒有在執行 ...

lxc-ps aux -n debian6


root@home:/sys/fs/cgroup# rmdir */lxc/debian6


VPS 不夠 Ram


Dec 17 09:32:04 lxc kernel: [799333.427301] Memory cgroup out of memory: 
  Kill process 3588 (mysqld) score 77 or sacrifice child
Dec 17 09:32:04 lxc kernel: [799333.446264] Killed process 3588 (mysqld)
  total-vm:182656kB, anon-rss:80576kB, file-rss:472kB


LXC mount entry devpts to read only after lxc-stop container


嘗試加入以下設定, 看看 Container 是否能啟動, 如果能, 那就 Fix 了

lxc.cap.drop = sys_admin