> This seems a bit delicate and involves some communication during the hand-off from the old to the new, but it does work.
MUDs routinely did this back in the day. Here's a README excerpt from Erwin Andreasen's widely used patch:
"Basically, for each playing descriptor, it saves the descriptor number, the player's original name as well as the host name (so we don't have to find that again). Then, it closes fpReserve, and exec's the MUD again. As exec preserves open file descriptors, players do not lose link. The MUD is executed with some extra parameters, so the new copy knows that it should reload some player files. It does that, and puts in the players at their old places."
MUDs routinely did this back in the day. Here's a README excerpt from Erwin Andreasen's widely used patch:
"Basically, for each playing descriptor, it saves the descriptor number, the player's original name as well as the host name (so we don't have to find that again). Then, it closes fpReserve, and exec's the MUD again. As exec preserves open file descriptors, players do not lose link. The MUD is executed with some extra parameters, so the new copy knows that it should reload some player files. It does that, and puts in the players at their old places."
http://www.andreasen.org/ftp/copyover-7.tar.gz