Manual migration to new server without backup

Hi there!

I have totally messed up with my server, now I need to migrate configuration with users and mailboxes to the new one.
Few months ago upgraded server to 22.04 (Yup, I saw that this is unsupported and shouldn’t do like this), mail was working so I left it as is, later saw that roundcube is not working, but I do not use it often.
Now I decided to do a normal migration to new server, but after upgrade python stopped working as it should, unable to run backup, ssl scripts, etc.
Tried to fix that python issue, and at some point taught that maybe reinstall of python will help, after removal of python nothing is working anymore :slight_smile: even no network.
Is it possible somehow to migrate configuration, users, mailboxes to new server without backup?
There is a backup few months old before upgrade, but I don’t want to loose all emails that was sent and received after that backup.

The mailinabox data files are stored in the STORAGE_ROOT directory, usually /home/user-data From your post, I think it is not clear that the whole of the storage root folder is in a recognizable state for the mailinabox installer scripts. Your best bet might just be to install a fresh box somewhere and then use a tool like Imap sync to copy all the mail from the old to the new server. However, thus you would miss out on the configuration and defined users, which you would have to add manually.
A second option is to copy all the files from the STORAGE_ROOT directory to the new server, then run the mailinabox setup again.

1 Like

Thanks!
Actually yes, today after posting, I tried to just copy /root/user-data folder to the new server and it helped. Everything is working now as it should.

Old lesson learned again: Do not experiment on production!!! :slight_smile:

1 Like