Transfer data from SCM version 1.48 to new server version 3.11.0

Hey,

I have a problem. We have an old SCM server in version 1.48 in a separate network. Now we have to shut down the network and cannot migrate the server.

That’s why we have set up a new SCM server in version 3.11.

Now the question is how we can transfer the data from the old SCM server to the new one and how we can preserve the history of the projects so that we only have to copy the data structure.

Best regards,

Marcel

Hi Marcel!

May I say, you’re a bit late to the party after nearly 10 years, but welcome nonetheless :slight_smile:
Glad to hear, that your server made it for so long :+1:

You should be able to migrate your old data, I’d recommend the following steps:

  1. Backup-up your data
  2. Start SCM-Manager 1.60 once using your data directory to migrate it to the latest 1.x format
  3. Afterwards, start the latest SCM-Manager release using this data directory
  4. Here you should get a migration wizzard to adapt your old data to new folder structures (be aware of the hint, if you have lots of repositories)
  5. The start-up afterwards will migrate the data itself

If you encouter any obstacles, feel free to contact us.

Regards
René :crossed_fingers:

Hey René,

Yes, since the server was running on an offline network, it was not considered necessary to perform updates.

I am currently attempting to install version 1.60 on Ubuntu 24.04 and then copy the data to the new server.

The following error occurs:

root@srv-svn01:~# sudo apt install scm-server
Reading package lists… Done
Building dependency tree… Done
Reading state information… Done
The following NEW packages will be installed:
scm-server
0 upgraded, 1 newly installed, 0 to remove and 93 not upgraded.
Need to get 0 B/32.1 MB of archives.
After this operation, 32.7 MB of additional disk space will be used.
(Reading database … 87182 files and directories currently installed.)
Preparing to unpack …/scm-server_1.60_all.deb …
dpkg: error processing archive /var/cache/apt/archives/scm-server_1.60_all.deb (–unpack):
conffile name ‘opt/scm-server/conf/server-config.xml’ is not an absolute pathname
Errors were encountered while processing:
/var/cache/apt/archives/scm-server_1.60_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Do you have any ideas?

Hi,

I’m afraid you are a few weeks too late, we shut down some of the 1.x infrastructure about two months or so ago.

But since your only goal is to start a server once with 1.60, you can easily use the simple generic Unix package.

Once downloaded, extract it in a path of your choice (may be /tmp) and start it with your data directory specified:

tar xvzf scm-server-1.60-app.tar.gz
cd scm-server
SCM_HOME=/path/to/your/old/scm_home ./bin/scm-server

Once the server started, you should find a file version.txt in the config directory inside of your scm home with the content 1.60. After this, your directory is ready to be migrated to 3.11.

Hope this helps!
René

Hey rené,
Thanks for the info.

Can you tell me where the home directory is located by default in version 1.48 so that I can copy it to the new server?

Best regards,

Marcel

Oh, that’s a very good question, and it depends on your installation. You used the debian package, right? If I’m not mistaken, you could take a look at /var/lib/scm. If you can find for example config and repositories there, that’s probably it.

Hey René,
I was able to complete the migration and create the scmadmin, but when I first set it up and selected the plugins, I always got an error message:

Hi, that sounds like somehow the plugin wizzard somehow interfered with the update. You can try and create a simple file named pluginSets.xml in the config directory of the scm-home with the following content:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<pluginSetsConfig/>

Maybe we have to revise the update mechanism once more.

Please let us know, whether this works.

Regards
René

hey René

That solved the problem, but now the next problem arises: the migration of the repositories is not there.

There should actually be 200 repositories here now.

Hey,

I just stumbled across a message from the SCM server that shows an error in the import.

Oh, okay, Let’s take one step back. Did you see the migration page shown in [these docs](https://scm-manager.org/docs/3.11.x/en/migrate-scm-manager-from-v1/ ?

I just went throught the migration process. It’s important, to use the same path for the home directory. On my first try, I made the mistake to run the 1.60 version without docker, but tried to run the migration with docker. This did not work, because from the docker instance the path had changed.

Another possible error could be, that the home directory had not been specified correctly. This could be done best in the config.yml file depending on your installation (take a look here.