How Can I Perform P2V Conversion On Linux Fedora Workstation 39

Hi, a complete newbie here. I’ve installed Linux Fedora a couple days ago and so far I’m enjoying it.

I’ve already run into a bunch of problems as I learn how the entire structure works.

There’s a steep learning curve for sure, that’s why I figured it might be a good idea to convert the entire physical system into a virtual machine so that I can create multiple virtual environments that are good for testing and without losing any data.

The answers on the web didn’t satisfy me that’s why I decided to reach out for your help.

Certainly, there are plenty of ways to do that I can use VMware or Starwind but I would like to do it natively and by using free open source software. The problem is, I can’t find anyone talk about it…

Thank you.

What physical machine do you want to turn into a VM?

If its a Fedora instance then its easier to install a fresh instance and sync user files or mount user files into the VM. I do this a lot to have instances of Fedora that run different versions of Fedora for example.

For Windows instance it would be hard to do this, but you would run into licensing issues with clones.

Hi there, and welcome to Fedora land :slight_smile:

Since you just started testing Fedora: Do you really want p2v (convert an existing installation) or rather restart your experiments with a virtualised installation? The latter is easier.

Now, depending on what kind of experiments you’re thinking about, there are different ways:

  • full blown virtualization (like VMware): kvm/qemu is the free and open source solution. There are different front-ends, such as gnome-boxes (simple), virt-manager (somewhat similar to the old VMware workstation) and others. Basically gives you complete virtual system.
  • containerization (podman/toolbox/distrobox): Uses your host system’s kernel but allows you to have separate user space (separate apps etc). Easy way to try out different apps, related admin commands without destroying your host’s system.
  • os-tree/immutable/atomic Fedora variants (Silverblue and the like): No isolation/parallel systems but easy roll-back to a previous working system state

Well, my system is already set up and I don’t want to lose any apps, settings, preferences etc. that I have already.

I have a couple of apps that I would like to test but I don’t want to risk breaking my system.

I’m looking for something where I can deploy multiple instances of my current system for long term stability.

My native Linux Fedora 39. I don’t want to lose any settings, apps, preferences etc. that’s why fresh install might not be a good idea.

Unlike Windows its a lot easier to setup a duplicate system.

If you installed all the apps from RPMs then just install the same RPMs.
Did you edit config in /etc? That should be simple to copy.
You can find your user’s config in the ~/.local and ~/.config folder trees.
They can be copied to a new VM.

My usual practice is to write a script to setup a system.
It will install all RPMs that I need and setup the config files.
As it is a script I can easierly maintain it as changes are needed.

I understand what you want to do, I just think there are better work flows that you may wish to consider.

1 Like

If you want to use an open source solution for this, I have used Clonezilla to create an image of the physical installation and then restored that image to a VM.

May I know how did you install this on Fedora? I can see only Debian and Ubuntu based installations on their website.

If you are asking about clonezilla then the site linked above shows how to download the live version of clonezilla that can be put onto a usb device. Then use that to clone an image of the HDD onto another usb device. Finally that can be used to restore onto a VM image.

1 Like

That’s an interesting approach, thank you. I will definitely check it out unless I find something more subtle. Updates tend to break things and I’m not sure how it will affect my system since I have little experience writing scripts. If there’s an option to turn my system into a VHD file or any other file that VM will recognize I would rather choose to stick with it because I think it’s easier.

Mhm, could you explain how it works in more detail?

Do I need a sizable USB drive?
Can I somehow use it to create a file format supported by VMbox, QEMU etc.?