OpenVz: Migrating Vps from one Hard disk to another

*First copy the contents from old directory to new disk directory

cp -a /var/lib/vz/private/109/* /disk3/private/109/

*Once the copying is over stop the vps

vzctl stop 109

*Drop the quota file

vzquota drop 109

*Then edit the config file and enter the new VE_PRIVATE value,

nano /etc/vz/conf/109.conf

VE_PRIVATE=”/disk3/private/119″

mv /var/lib/vz/private/109 /var/lib/vz/private/109.bak //taking backup to restore if needed, once successful you can remove this file

*Start the vps

vzctl start 109

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s