Portability issues with Linux under Virtual PC / Virtual Server

Portability issues with Linux under Virtual PC / Virtual Server

Rate This
  • Comments 11

If you are like me - then you have quickly grown used to being able to move virtual machines around from computer to computer for convenience.  However - there is one specific problem with doing this with a Linux based virtual machine - and that is that most Linux distributions install kernels that are optimized for the processor type that is detected during installation.

This is great for performance on normal hardware - but results in the fact that if you install Linux on one processor type (say a Pentium IV) and then try to move it to another processor type (say an AMD64) the virtual machine will fail to boot (usually with an 'Unrecoverable Processor Error').  For the most part - there is not much you can do about this problem except for naming your Linux virtual machines such that you can remember which processor type they were built on.


Leave a Comment
  • Please add 4 and 3 and type the answer here:
  • Post
  • ou install Linux on one processor type (say a Pentium IV) Wow!
  • Ben,

    I'm in no mean a VPC expert (ok.. I *must* admit I am more acquainted with the competitor's product).. And since you seem (from reading previous posts) commited to using FC.. well, that's not my bag of tea either.. Ok doesn't sound terrific for a post - but bear with me ...

    If you want to be able to use multiple architecture kernels (say x86 & x86_64) - you may want to try having multiple kernels available at boot time - then - using grub or lilo (whatever your poison is) - select the appropriate kernel..

    Now again (from reading another post - and for pure speculation) since the VPC VM seems to be restricted to 32 bit operations, I'm not 100% sure how any kernel will behave when being confronted with a supposedly 64 bit capable processor that is not capable of actually running 64 bit instructions (which may be the root cause of the 'Unrecoverable Processor Error' kernel Panic)..

  • All that I can say is that the reasons to not use Linux
    have grown pitifully weak.
  • Hi Ivan,

    Neat idea to install and configure multiple kernels for each Arch - I may have to give that a shot one day. By the way - what do you mean by 'FC'?


    I have no idea why you think that this would be a reason not to use Linux - so yes I agree that this would be a weak reason to not use Linux (Ben rolls his eyes).

  • I hadn't noticed any Linux installer choosing a kernel version according to the detected CPU type. (I've accidentally built a kernel for the wrong CPU type and watched it fail to boot, the same symptom but for a different reason.) Perhaps Fedora Core does that though, and that could be why another commenter assumed you use it.

    Now, even if an installer does this kind of detection and selection, what is special about it? Can we think of any operating systems whose installers detect chipsets and video chips and other such stuff and select specialized drivers for those? Are there some famous examples of OSes that can't simply be copied from one machine to another because their installation was tailored to the first machine they were installed on? Are there some famous examples of OSes that even make further use of that detection and tailored installation in order to verify licences?

    So, what is different about CPUs? Oh yes, VPC only emulates chipsets and video chips and stuff like that, it doesn't emulate CPUs.

    If you compile your own kernel, I'll bet you can make a Linux installation sufficiently generic that you can even copy it from a VPC to a real PC and back and it will still work on both. It'll still depend on PC architecture so this one won't boot on Macs and embedded MIPS-based systems, but you'll still find it pretty convenient.
  • Hi Norman Diamond,

    This issue has existed for a very long time (I can remember dealing with it as far back as RedHat 8.0) and affects pretty much every modern Linux distribution that I know of.

    As for your comments about the portability of Windows (yes - you can name the operating system) - maybe you should search my blog for the posts I have provided about migrating Windows from physical to virtual machines.

    I must say that it is very disappointing to see so many negative comments on a post where I am trying to help people who are using Linux under Virtual PC.

  • Hello Ben!

    First of all thanks for giving people the right idea on what could be wrong, and standing outside the Windows/Linux-Bashing-War.

    The idea of using the boot loader for starting the kernel for the right processor is one nice solution. Another one would be to configure and compile a kernel explicitly for Virtual PC. This way you can include all necessary drivers for hardware directly into the kernel without using modules and still get a rather slim one. Maybe together we could figure out some nice configuration for the Linux kernel via email for others to use?

    P.S.: It would be nice of you to state that you'd use the AMD64 in 32-bit mode... ;)
  • This reminds me of some of the flexibility available in many LiveCD distributions for Linux such as Knoppix. In this scenario, the Linux system doesn't know what processor it's based on - well, only that it's x86 - and must be generic, then autodetect much of the hardware.

    I've used VPC to test out a few of the live distributions - I keep a minimal hard drive around, blank, just to use for such machines. (Incidentally, for that reason, it'd be nice to specify what ISO image to capture *before* turning on the machine, rather than having to try and pause it during BIOS boot to put the CD in.)

    Anyway - long story short, Knoppix and others also provide means to install to the hard drive, I believe without losing the autodetect features. That may be a good route to go for VPC-based Linux installs.
  • Ben,

    I realize this isn't specific to your Linux post, but I noticed this blurb in the VPC Help file:

    "If you plan to transfer a virtual machine to another computer it is recommended that the target computer have the same type of processor as the one on which the virtual machine was created. For example, a virtual machine that was created on a computer with a Pentium 4 should be transferred only to another computer running a Pentium 4. "

    How much of an impact do you have if your create a Windows XP image on a machine with a Pentium 4 processor, then transfer that to a machine with a Pentium III or a laptop with a Pentium M?

    This would seem to be a common problem if a desktop administration group was responsible for creating and managing VPC images within an organization with a variety of client processor types.

  • I didn't intend to argue this way, but on seeing this:

    > I must say that it is very disappointing
    > to see so many negative comments on a post
    > where I am trying to help people who are
    > using Linux under Virtual PC.

    The last sentence of your base posting here appears intended as help and the rest of it was analysis. Some other commenters were a bit more helpful I think. The last paragraph of my comment was intended as help and the rest of it was analysis.

    Your analysis appeared to cast Linux as being the cause of the issue, so my analysis cast VPC as part of the cause and showed why VPC's role in this issue didn't affect Windows the way it affected Linux.

    I understand your answer to one of my comments, that Red Hat's installer has been automating its detection and selection of kernel since version 8.0. The last Red Hat version I had to contend with was 7.3. I'm not exactly a big user of Linux but was relieved to discover some other distros with fewer bugs (plus of course the ability to fix a few bugs myself).

    Perhaps the last paragraph of my previous posting should have included more details. You can compile a kernel that targets a plain 80586 CPU and it will run on every Intel x86 from Pentium onwards. You can include chipset drivers for Intel BX AND for real chipsets on any real machines where you might want to copy your installation from a virtual PC to a real PC. You can include video chip drivers for S3 AND any real ones you want to target, etc.

    Someone else suggested a slim kernel but I'm not sure why. That wouldn't maximize the number of real target machines you could copy to.

    If you only intend to copy installed images from one virtual PC to another, then you don't need to compile in extra chipset drivers etc., just make the kernel target an 80586. Then the kernel will be slim.
  • SvOlli,

    Whoops - I guess I am so used to the fact that Virtual PC currently only runs on AMD64 in 32-bit mode that I did not even consider the fact that this might cause confusion


    That is a good idea - I have only ever played with the CD versions of Knoppix - I should check out the HD based versions.


    Generally speaking moving between processors is not that much of a problem (my two main computers are an AMD64 and a Centrino). However we include that statement because it can cause problems with some OSes (like Linux) and because some features don't work well if you change the processor type (like saved states)

    Norman Diamond,

    No problem - I honestly did not think that I was placing blame anywhere - but was just pointing out that this would happen and that users should know why it happens.

Page 1 of 1 (11 items)