X86_64 moving running Rust prog from machine A to machine B

MachineA, MachineB are two x86_64/Linux machines with identical hardware and identical software.

some_server, a Rust program, is running on MachineA

some_server has network ports open, but not any files open.

We would like to move some_server, with minimal downtime, from MachineA to MachineB.

Is there a standard way to do this? (The relation to Rust here is: some_server is written in Rust, so it is okay if the solution involves slightly modifying some_server itself).

It's been done: GitHub - trishume/telefork: Like fork() but teleports the forked process to a different computer!. Definitely not "standard" though.


Out of curiosity, what tech were you playing / what problem were you trying to solve when you stumbled across this repo ?

I think I just saw it linked somewhere, possibly on Twitter. Either that or I was already following Tristan Hume because of his syntax highlighting/text editing work (including on Xi) and it showed up in my GitHub feed.

I believe the owner wrote up a blog post and posted it here.

I think most people would run their code inside a virtual machine then take a snapshot and copy that around.

I've never used it before, but the Checkpoint/Restore In Userspace project seems to be almost exactly what you are looking for. The RedHat blog has an interesting article on the topic:

1 Like

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.