[CRIU] problem restoring a socket: Address already in use

Tycho Andersen tycho.andersen at canonical.com
Mon Oct 27 15:33:44 PDT 2014


On Tue, Oct 28, 2014 at 01:10:05AM +0400, Pavel Emelyanov wrote:
> On 10/28/2014 02:05 AM, Tycho Andersen wrote:
> > Hi all,
> > 
> > I'm trying to restore a container running a server (in particular, a
> > VNC server), but the restore fails with:
> > 
> > (00.168868)    492: Error (sk-inet.c:541): Can't listen on a socket: Address already in use
> > 
> > full log is here: http://paste.ubuntu.com/8709744/
> > 
> > I guess what's happening is that the process listen()ed and then
> > fork()ed, and then cant re-listen() from both when criu restarts?
> 
> We've tried to address that. If a socket (or any other file) is shared between
> two or more tasks, then only one of them will create a socket on restore, all
> the others will receive one via specially created temporary unix socket.

Oh, I remember seeing this code, I had forgotten about it though.

> Maybe that's because of the original socket still hanging around?

I don't think so, this upon migration to another machine. I'll fiddle
around with it a bit more and reply if I can get any more info.

Tycho

> Thanks,
> Pavel
> 


More information about the CRIU mailing list