Tidying up after Guest rebuild - rename and file dependency

This is for discussing general topics about how to use VirtualBox.
Post Reply
Jonners59
Posts: 45
Joined: 21. Jan 2011, 20:09
Primary OS: Ubuntu other
VBox Version: OSE Debian
Guest OSses: Windows 7 32-bit Home Prem

Tidying up after Guest rebuild - rename and file dependency

Post by Jonners59 »

After a power outage, I was unable to remount my Linux guest. After some fuffing about, making a duplicate I managed to get it working, though with a slightly different name. The original was just called Debian, but the new one is called Debian3CX. Not a major issue, except.

1. I have a script to safely shut down Debian and do not want to mess about with it, so it would be nice to change the name to Debian from Debian3CX.

2. To get this working again, I created a new guest with a new name and then imported the old image. I then tried to tidy up by deleting the old image, but the new one refused to boot. Checking the logs it has used a file in the old image folder. I restored the folder and it works. The file is

Code: Select all

Debian-disk002.vdi
. How do I get this tidied up so I can delete the old Debian?

Any assistance, please?
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Tidying up after Guest rebuild - rename and file dependency

Post by mpack »

The name of the VDI really shouldn't matter to you. What matters is the name of the VM: to rename a VM you simply change the name in <VM Settings>|General|Basic. VirtualBox will itself take care of renaming the control files (not the VDI).

And btw, this not really a "Linux Guests" question since the answer is the same for all guests. Topic moved to "Using VirtualBox".
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Tidying up after Guest rebuild - rename and file dependency

Post by scottgus1 »

Jonners59 wrote:I have a script to safely shut down Debian and do not want to mess about with it
A bit of scripting advice: If the VM name were a variable throughout the script, then it would be easy as pie to change the variable definition at the beginning of the script.
Post Reply