[BlueOnyx:07407] Re: Ot: migration of aventurine vps

Michael Stauber mstauber at blueonyx.it
Thu Jun 2 11:13:02 -05 2011


Hi Søren,

> I need to move vps' from and old aventurine server to a new one.
> 
> The new server is a standard installation, with no vps on it.
> 
> i have tried with the command vzmigrate xxx.xxx.xxx.xxx 1, and that export
> vps 1 to the new server, but i cannot see how to active vps 1 on the new
> server.

Here is the procedure. It's the full procedure, although you already have most 
of the steps figured out apparently:

1.) Exchange SSH "root" keys (passwordless login) between the two Aventurin{e} 
nodes, so that you can SSH as "root" from the source of the migration to the 
target of the migration. How this is done is explained under "Backup" / 
"Backup Settings" / "Help" in the Aventurin{e} GUI. You don't have to allow 
passwordless key based "root" login both ways. From the "source" to the 
"target" is sufficient.

2.) Make sure that SSH login as "root" to the target of the migration is 
enabled. Usually it's not - for security reasons.

3.) With "vzmigrate <IP of target> <VPSID>"  you can migrate the VPS.

Example: 	vzmigrate 192.168.1.1 2

That will migrate VPS #2 to the master node with the IP 192.168.1.1

Run "vzmigrate -h" to see the available options. The usual sensible options 
are:

"vzmigrate --remove-area no --keep-dst <IP of target> <VPSID>" 

There is also the "--online" switch that allows you to migrate a VPS with next 
to no downtime. However, it's the most problematic switch and there are cases 
where it'll simply not work or where it will overly complicate matters. So you 
might want to avoid the "--online" switch.

4.) After the migration has finished, the VPS is stopped on the "source" and 
started on the "target" of the migration. You can confirm this by running 
"vzlist -a" on both master nodes.

To allow the GUI of the target of the migration to "see" the new VPS, simply 
restart CCEd on the target node of the migration:

/etc/init.d/cced.init restart

5.) Sensible additional post-migration steps:

- Enable local and/or remote backup of the freshly migrated VPS as you see 
fit.

- If you used the "--remove-area no" parameters for vzmigrate: The  "--remove-
area no" will just rename the config file of the VPS to 
/etc/vz/conf/<vpsid>.conf.migrated, but the config file and the VPS file area 
under  /vz/private/<vpsid> will remain behind. To conserve space you may want 
to delete those.

- Remove the passwordless SSH "root" key and/or disable SSH "root" logins 
again if you don't need them anymore.


-- 
With best regards

Michael Stauber




More information about the Blueonyx mailing list