On 03/05/2012 06:01 PM, Daniel Lezcano wrote:
On 03/05/2012 02:34 PM, David Ward wrote:Originally, lxc-ls listed all containers by printing the directory names in /var/lib/lxc. After commit 65cb447f9b8d1ac8dcf9df24a4f877180444f003, lxc-ls now finds and prints active containers by searching for open UNIX sockets named '/var/lib/lxc/<name>/command'. However, all containers are still printed using the old method as well, so now the active containers just get printed twice.Assuming that the intention of the above commit was to only list active containers, do not print the directory names in /var/lib/lxc any longer.The intention of the above commit was to list also the container which were created on-the-fly and hence not present in the /var/lib/lxc. For example, lxc-execute -n foo sleep 10, does not exists in /var/lib/lxc. I think the correct fix is to remove the duplicate container names. Or just show two list, the running ones and the stopped ones.
I added an '--active' flag in the new patch series. With the flag, running containers are shown. Without the flag, containers existing on the filesystem are shown (running or stopped). Let me know if that is okay.
David
smime.p7s
Description: S/MIME Cryptographic Signature
------------------------------------------------------------------------------ Virtualization & Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________ Lxc-devel mailing list Lxc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/lxc-devel