Description of problem: libvirt-lxc creates an /.oldroot directory in the container filesystem and never removes it before executing the container application. Version-Release number of selected component (if applicable): libvirt-daemon-1.0.5.6-3.fc19.x86_64 How reproducible: Start a container Steps to Reproduce: $ virt-sandbox -c lxc:/// /bin/bash bash: /root/.bashrc: Permission denied bash-4.2# ls -ald /.oldroot drwxr-xr-x. 2 root root 4096 Aug 13 13:56 /.oldroot Actual results: The /.oldroot directory exists. Expected results: The /.oldroot directory should not exist. Additional info:
I was able to reproduce this on Fedora 20. Containers are getting a directory /.oldroot created when being started from virt-manager or virsh start. libvirt-daemon-1.1.3.5-2.fc20.x86_64
The .oldroot directory is required during the pivot_root to setup the isolated filesystems. We can't remove it in a race free manner because there can be multiple containers starting in parallel using the same root filesystem. Merely having this directory exist should not cause any functional problems.