[SOLVED] Disk errors found: How can I move the entire Proxmox installation to another disk?

cosmos

Well-Known Member
Apr 1, 2013
104
2
58
Hello all,

I have made a small proxmox installation on a normal (ie non-server quality) system with a single sata disk. This is a fresh 2.3 installation, hosting a Windows XP KVM.

Can I "clone" the entire proxmox installation to a disk drive of the same type? The disk with the issue was a 250G Hitachi drive. I've got another one, exactly same model... If this was a Windows drive, I'd clone it with a program like Acronis True Image, but I do not have the faintest clue how to do it here, especially since LVM is involved (and possibly bad blocks on the original drive as well)...

Which would be the "official" approach to avoid possible future problems with a proxmox upgrade?

I believe I did a byte-for-byte copy once, using dd_rescue or something.

Any information will be greatly appreciated!
 
Last edited:
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

Hello all,

I have made a small proxmox installation on a normal (ie non-server quality) system with a single sata disk. This is a fresh 2.3 installation, hosting a Windows XP KVM.

Can I "clone" the entire proxmox installation to a disk drive of the same type? The disk with the issue was a 250G Hitachi drive. I've got another one, exactly same model... If this was a Windows drive, I'd clone it with a program like Acronis True Image, but I do not have the faintest clue how to do it here, especially since LVM is involved (and possibly bad blocks on the original drive as well)...

Which would be the "official" approach to avoid possible future problems with a proxmox upgrade?

I believe I did a byte-for-byte copy once, using dd_rescue or something.

Any information will be greatly appreciated!
Hi,
you can use different ways (have an valid backup in any case).

1. The official way is to do an new installation (backup first you VMs to another place) - an installation is fast and the safe way.

2. copy the whole disk - with dd or dd_rescue (boot an live cd distro like grml).

3. Copy on the fly - create two partition on the new disk (boot + lvm) - copy the boot-partition (and MBR). Expand the pve-vg with the second partition and move the lvs data, root + swap. After that reduce the VG (original disk). After this you can reboot and disconnect the disks with the issue.


Udo
 
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

Thank you for the fast answer. Do you foresee any trouble regarding LVM/dd_rescue, regarding disk UUIDs etc?
 
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

I'd suggest dd_rescue/ddrescue as well (the gnu version http://www.gnu.org/software/ddrescue/ddrescue.html).

If it turns out you have unrecoverable read errors (even after ddrescue had its way with your disk), I'd follow Udo's suggestion:
1. The official way is to do an new installation (backup first you VMs to another place) - an installation is fast and the safe way.
 
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

Thank you all for your informative posts. Trying dd_rescue showed that there were unrecoverable errors, but not in the area where VMs are stored. So I am going to backup the xp KVM to an external disk (formatted in ext3), hope that is possible, and also keep the old /etc. Then I'll do a fresh PVE install on another disk and restore the KVM from the external storage, using the backed up /etc folder.
 
Last edited:
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

Okay, some more questions. I used vzdump to take a backup of my xp KVM-type vm (had ID 100), to another disk. Reinstalled pve to a fresh disk and I am about to restore the VM. My question is, do I have to setup a VM first, with specifications about cpu(s), hard disk to use etc, or can I just do an import of the backup and have all hardware specs of the VM configured appropriately?

The qmrestore man page hints that I must follow the former approach, since both the archive path and the VMID are required argurements, however I do not recall the exact hardware details used for the vm. I have kept the pve /etc folder intact, can I use information from there to recreate a vm having the exact same config as the vm I had?
 
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

Okay, some more questions. I used vzdump to take a backup of my xp KVM-type vm (had ID 100), to another disk. Reinstalled pve to a fresh disk and I am about to restore the VM. My question is, do I have to setup a VM first, with specifications about cpu(s), hard disk to use etc, or can I just do an import of the backup and have all hardware specs of the VM configured appropriately?

The qmrestore man page hints that I must follow the former approach, since both the archive path and the VMID are required argurements, however I do not recall the exact hardware details used for the vm. I have kept the pve /etc folder intact, can I use information from there to recreate a vm having the exact same config as the vm I had?

Hi,
"qmrestore <archive> <vmid>" restores your vm-disks and the config also - you can choose a new VMID (ar use the old one).

Udo
 
Re: Disk errors found: How can I move the entire Proxmox installation to another disk

System back in its place, everything working beautifully!

I have already added to my agenda moving my ESXi production VMs to proxmox! :)

Case solved!
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!