Moving Drives between VM's? Please Help

R3tr0

New Member
Sep 26, 2022
23
2
3
Hello,
I have 2 vm's for windows. One is windows server and one is windows 10. My problem is whilst moving the os using clonezilla to the ssd (from a hdd) it has eventually corrupted the os files (no the virtual drive has been deleted and away from the system). I had a share with a separate drive attached, could i move that to retrieve the data from the share onto the windows 10 vm? How would I do this?

Many Thanks,
R3tr0
 
By the way, these are virtual disks not hard mounted disks, and i would not like to lose the data.
 
You should just be able to reattach the virtual disk to your other VM. Before doing that I would suggest making a backup of your virtual disk, just in case. After you have done that you can click on your VM in the Web UI, then select Hardware. There you can select the disk and click on 'Disk Action' > 'Reassign Owner'. Select the VM you want to attach the disk to and then the disk should be available in the chosen VM.
 

Attachments

  • Screenshot_20221004_095058.png
    Screenshot_20221004_095058.png
    47.7 KB · Views: 31
Hi shanreich,
This guide did not specify if i could detach and delete the drive? Do I just detach it?
Thanks,
R3tr0
 
Do not delete and/or detach it.

What you need to do is find the configuration file for the VM the disk is currently attached to and cut the respective line for the disk out of the config. Then you need to rename the disk file (change the vmid, and change the trailing number if needed). Afterwards you need to add a new line to the config of the VM that you want to attach the disk to. This should be the line you got from the first config, you just need to change the name of the disk image to the new name.

As I said before, it would be advisable to create a separate backup of the disk - just in case - before attempting to do any of the above steps.


Or, as leesteken posted you can also just upgrade your Proxmox, then you can do it via GUI.
 
  • Like
Reactions: Kingneutron
ok thanks, the only reason i installed a older version is because i was having trouble with the display.
 
Do not delete and/or detach it.

What you need to do is find the configuration file for the VM the disk is currently attached to and cut the respective line for the disk out of the config. Then you need to rename the disk file (change the vmid, and change the trailing number if needed). Afterwards you need to add a new line to the config of the VM that you want to attach the disk to. This should be the line you got from the first config, you just need to change the name of the disk image to the new name.

As I said before, it would be advisable to create a separate backup of the disk - just in case - before attempting to do any of the above steps.


Or, as leesteken posted you can also just upgrade your Proxmox, then you can do it via GUI.
I tried running the 2 commands as listed on the page
# apt-get update (this updates a lot)
# apt-get dist-upgrade (this said 0 to upgrade)
Nothing Happens
 
try

Code:
apt update && apt full-upgrade


edit:

do you have the no-subscription repository enabled? You can do this in the Web UI.
 
Last edited:
try

Code:
apt update && apt full-upgrade


edit:

do you have the no-subscription repository enabled? You can do this in the Web UI.
Reading package lists... Done
E: Failed to fetch https://enterprise.proxmox.com/debian/pve/dists/bullseye/InRelease 401 Unauthorized
E: The repository 'https://enterprise.proxmox.com/debian/pve bullseye InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
 
also, on a random note. My Windows 10 vm ethernet sometimes randomly disconnects. Do you know a fix (It only happens sometimes.)
 
That's the same as apt-get update; apt-get dist-upgrade. Most likely there is no subscription and the no-subscription repository is not configured.
Yes I also noticed my mistake, and already edited my post accordingly. Thanks ;)

Reading package lists... Done
E: Failed to fetch https://enterprise.proxmox.com/debian/pve/dists/bullseye/InRelease 401 Unauthorized
E: The repository 'https://enterprise.proxmox.com/debian/pve bullseye InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

You need to enable the no-subscription repository in your web UI. Then it should work fine
 
Yes I also noticed my mistake, and already edited my post accordingly. Thanks ;)



You need to enable the no-subscription repository in your web UI. Then it should work fine
I have done this, do i just restart my system and the update is there?
 
If you enabled the repository it should just suffice to run apt update && apt full-upgrade again.
 

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!