Install Rocky Linux 9.1 successfully but the clone or import is not work

Discussions about using Linux guests in VirtualBox.
Post Reply
zhanming
Posts: 5
Joined: 3. Jan 2023, 10:16

Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by zhanming »

Environment
Host OS: macOS 13.1(Intel)
Virtual Box: 7.0.4
Guest OS: Rocky Linux 9.1

Install Rocky Linux 9.1 successfully, restart the OS is also working good.
1. Clone the VM to a new one, the new VM can not start.
2. Export the VM and then import it, the import one can not start either.

By the way: I tested install Rocky Linxu 8.7, clone an import both working fine.

Please see screenshot in the attachment.
Attachments
1672734414142.jpg
1672734414142.jpg (120.06 KiB) Viewed 5259 times
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by scottgus1 »

Did you use Virtualbox's Clone command? Was it a full or linked clone?

For the working and cloned VMs, please provide the following:

1. Right-click the VM in the main Virtualbox window's VM list, choose Show in Explorer/Finder/File Manager. Zip the VM's .vbox file (not the .vbox-prev file), and post the zip file, using the forum's Upload Attachment tab. (Configure your host OS to show all extensions if the folder that opens does not show a .vbox file.)

2. Start the VM from full normal shutdown, not save-state. Run until you see the problem happen, then shut down the VM from within the VM's OS if possible. If not possible, close the Virtualbox window for the VM with the Power Off option set.

Right-click the VM in the main Virtualbox window's VM list, choose Show in Explorer/Finder/File Manager. In the "Logs" subfolder, zip the VM's "vbox.log", and post the zip file, using the forum's Upload Attachment tab. (Configure your host OS to show all extensions so you can find the "vbox.log", not "vbox.log.1", etc.)
zhanming
Posts: 5
Joined: 3. Jan 2023, 10:16

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by zhanming »

Thank you for the reply.

I use the GUI(not the command) to full clone the VM.

Please see logs in the attachment.

1. Working.VBox.log.zip is the working VM. Normal start and shutdown.

2. Cloned.VBox.log.zip is the cloned one. Normal start and shut down within the VM's OS.
Attachments
Cloned.VBox.log.zip
Cloned VM
(33.71 KiB) Downloaded 4 times
Working.VBox.log.zip
Working VM
(34.41 KiB) Downloaded 3 times
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by scottgus1 »

They both seem to work OK until the audio in the VM gets set up, then the clone stops. Regrettably, I cannot figure out why.

One thing I do see is that the working VM shows setup of the network as the next thing done. I wonder if you set the clone to make new MAC addresses for the clone's network adapters?

Please note point 1 above also requested both VMs' .vbox files.
zhanming
Posts: 5
Joined: 3. Jan 2023, 10:16

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by zhanming »

Thanks for the reply.

The clone's MAC is new, when clone I choose MAC Address Policy: "Generate new MAC address for all networks", then "Full Clone"

I delete the old working and clone VMs, and reinstall a new VM of Rocky Linux 9.1, this time the clone is worked.
I confused...

Then I test another case:
Choose 2 Hard disks, and create a new Rocky 9.1 VM, this time the new VM is worked, but the clone is not work.
It stuck after "Reached target Sound Card." and "Time out waiting for devid /dev/mapper/rl-home."

And I also tested 2 Hard Disks on a CentOS 7, it also happened.
Host OS: CentOS 7
Virtual Box: 6.1.36
Guest OS: Rocky 9.1

Please see log and .vbox file in the attachment
Attachments
Working.zip
(34.96 KiB) Not downloaded yet
Clone.zip
(32.33 KiB) Downloaded 4 times
zhanming
Posts: 5
Joined: 3. Jan 2023, 10:16

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by zhanming »

Today I update VirtualBox to 7.0.6, and the issue still exists.

I want to reproduce the issue.

BTW: Install Rocky 9.1 with 2 harddisks with auto partition, the clone is good.

The issue happened in this satutation:
1. These 2 harddisks were setting by custom partition, the partition is below

Code: Select all

$ lsblk
NAME         MAJ:MIN RM  SIZE RO TYPE MOUNTPOINTS
sda            8:0    0   20G  0 disk
├─sda1         8:1    0    1G  0 part /boot
└─sda2         8:2    0   19G  0 part
  ├─rl-root  253:0    0   17G  0 lvm  /
  └─rl-swap  253:1    0    2G  0 lvm  [SWAP]
sdb            8:16   0   20G  0 disk
└─sdb1         8:17   0   20G  0 part
  └─data-var 253:2    0   20G  0 lvm  /var
sr0           11:0    1 1024M  0 rom
2. After install and restart the OS, the OS is working good.
3. Clone this VM (Full Clone).
4. Start the clone one, the issue is appears.

The OS log is below:

Code: Select all

localhost kernel: vmwgfx 0000:00:02.0: vgaarb: deactiveate vga console
localhost lvm[687]: /dev/sda2 excluded: device is not in devices file.
localhost lvm[687]: WARNING: no autoactivation for /dev/sda2: system.devices t10.ATA____VBOX_HARDDISK______VB1F51a3e5-89d515fe_ current t10.ATA____VBOX_HARDDISK______VB66855faa-ca693c97_.
localhost lvm[691]: /dev/sdb1 excluded: device is not in devices file.
...
...
localhost systemd[1]: dev-mapper-data\x2dvar.device: Job dev-mapper-data\x2dvar.device/start timed out.
localhost systemd[1]: Timed out waiting for device /dev/mapper/data-var.
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by mpack »

Cloning a VM results in new UUIDs. Some guests are sensitive to this, including Linux guests which identify drives using UUID.
wjm
Posts: 1
Joined: 21. Mar 2023, 20:59

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by wjm »

I had the same issue and solved it by using a standard partitions, not a lvm
Tronmch2
Posts: 33
Joined: 15. Aug 2018, 18:11

Re: Install Rocky Linux 9.1 successfully but the clone or import is not work

Post by Tronmch2 »

Yeah, I have the same issue with actual RHEL 9.x. The default install uses LVM. Which makes things "interesting." You have to go into rescue mode to delete the system.devices file and do some lvmconfig voodoo which I always forget until after I need it again.

For the record, I set "use_devicesfile=0" in /etc/lvm/lvm.conf and removed /etc/lvm/devices/system.devices file in my template file, and it seems to do the trick.
Post Reply