diff options
author | Serge Hallyn <serge@hallyn.com> | 2012-02-22 11:40:16 -0600 |
---|---|---|
committer | Daniel Lezcano <daniel.lezcano@free.fr> | 2012-02-26 10:44:41 +0100 |
commit | 97d3756cbe108e564d1a1b6cc23c02d379c3c02e (patch) | |
tree | 4e3ec6866f053c574055c25bf085bbb535399586 | |
parent | update ubuntu templates to provide macaddr and more (diff) | |
download | lxc-97d3756cbe108e564d1a1b6cc23c02d379c3c02e.tar.gz lxc-97d3756cbe108e564d1a1b6cc23c02d379c3c02e.tar.bz2 lxc-97d3756cbe108e564d1a1b6cc23c02d379c3c02e.zip |
If a container is already running, say so in error msgs.
Otherwise there is no clear indication to the user why the container
startup failed.
Signed-off-by: Serge Hallyn <serge@hallyn.com>
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
-rw-r--r-- | src/lxc/commands.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lxc/commands.c b/src/lxc/commands.c index f323943..1d488ae 100644 --- a/src/lxc/commands.c +++ b/src/lxc/commands.c @@ -271,7 +271,12 @@ extern int lxc_command_mainloop_add(const char *name, fd = lxc_af_unix_open(path, SOCK_STREAM, 0); if (fd < 0) { - ERROR("failed to create the command service point"); + ERROR("failed (%d) to create the command service point %s", errno, offset); + if (errno == EADDRINUSE) { + ERROR("##"); + ERROR("# The container appears to be already running!"); + ERROR("##"); + } return -1; } |