We Got Served Forums: Running Linux on a Windows Home Server in a Virtual Environment - We Got Served Forums

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Running Linux on a Windows Home Server in a Virtual Environment

#1
User is offline   Bodog (WGS) 

  • Advanced Member
  • PipPipPip
  • View gallery
  • Group: Moderators
  • Posts: 1,242
  • Joined: 17-January 08
  • Gender:Male
  • Location:Sydney, Australia
  • Interests:Windows Home Server
Use this thread to discuss Pedro Innecco's method of running Linux on a Windows Home Server simultaneously in a virtual environment

As I've had some difficulty getting to the site I have included the blog article below:

Runing Linux on a Windows Home Server simuntaneously

May 27th, 2008 by pedro

I read a few weeks ago in some of the Windows Home Server forums that some enthusiasts are trying to install Linux on a HP MediaSmart server. While I do find it to be a quite interesting exercise, I fail to see the benefits of replacing Windows Home Server with a copy of Linux, particularly since HP has their own Linux-based home servers, plus it would be probably cheaper to build a custom one.

On a personal note, I rather like the idea of having a Windows-based server at home. But I do miss having the ability to play with Linux hacks. So I was thinking what I could do to have Linux as an option at home when I came with a solution where I could have both Windows Home Server and Linux on my MediaSmart server running at the same time: Virtual Server.


After upgrading the amount of RAM on my MediaSmart served from 512MB to 2GB, I felt this would be a great opportunity to have a Linux system without compromising the features of Windows Home Server. So I have prepared this guide to explain what I have done to run a Linux virtual machine under my Windows Home Server. I part from the principle that you know what you are doing and you have some idea of what virtualisation all about.

Here is what you need:

Upgraded your server’s RAM. 512MB is unrealistic if you want to do anything with Windows Home Server besides its out-of-the-box features. If you have a HP MediaSmart server, you can find instructions on how to upgrade the server memory here.
A copy of Microsoft Virtual Server. At the time of writing this post, the last version was 2005 R2 SP1. Virtual Server is free and can be downloaded from here.
A distribution of Linux. I am a big Ubuntu fan. However I opted to use openSUSE because of the benefits it has from the interoperability agreement Novell has with Microsoft (e.g.: virtual machine additions). You can get openSUSE from here, and Ubuntu from here.

Instructions

First and foremost, you must do a remote access to your HomeServer using UltraVNC or Remote Desktop and log in as administrator.
Once on the servers desktop, install Microsoft Virtual Server. Reboot the server is necessary and remote desktop into the server again as administrator.
On the Servers Start Menu under Microsoft Virtual Server, click on Virtual Server Administration Website.
Under Virtual Machines on the left-side menu of the Admin Site, choose click on Create.
You must now provide the initial settings of your virtual machine. Here are some of my recommended settings for a simple Unix Server:
Name. The name of the Virtual PC (e.g.: Linux, openSUSE, Ubuntu).
Memory. The amount of RAM you want to provide for the virtual machine, bearing in mind you should leave enough for your server to run smoothly. It really depends of the amount of RAM you have and what you want to do with your Linux server. For example if I only want to use some console (text) applications I would go from a minimum of 256MB to 512MB (if I want to run services for a development environment). If using a graphical desktop and/or some more intensive applications, I might go to 1GB. As I have 2GB for my home server, I prefer to never leave the Home Server operating system with less than 1GB.
Virtual hard disk. You can create the disk to use with your Linux virtual machine now or specify one later.
NOTE: If you already have or plan to have Linux on an external disk or flash drive, you could create a linked virtual hard disk that points to the Linux you partition you want to use.
Virtual network adapter. Make sure you configure your virtual machine to connect to the external network. This will ensure that the virtual machine can be seen and accessed on your network.
Once the machine is created, you will be presented with its configuration page.
If you need to install Linux, you need to ensure the virtual machine will be able to initiate the Linux installation process:
If you have a CD/DVD drive on your home server, simply put the disk on the drive and ensure your virtual machine CD/DVD drive properties is configure to use your physical CD/DVD drive.
NOTE: If you want to use your CD/DVD drive within your Linux virtual machine, you should do this procedure regardless if you need to install Linux or not.
If your home server doesn't have a CD/DVD drive, you must configure the virtual machines CD/DVD driver properties to capture the ISO image of your Linux install disk.
If you already have an external disk with Linux installed, or if you want to install Linux on a dedicated disk, you must create a linked virtual disk that points to your existing Linux install:
Plug the external disk with Linux on your home server.
On the Virtual Server Admin Site under Virtual Disks, choose Create then Linked Virtual Hard Disk.
Specify the location name of the file to be saved and the physical drive that will be used for the virtual disk.
Go back to the configuration page of your Linux virtual machine and under hard disks, provide the filename of the file created for your linked virtual hard disk.
OPTIONAL: Still on the virtual machine configuration page, you can click on General properties in order to specify a username and password to run the virtual machine upon system start-up. Recommended if you want your Linux virtual machine to be always on (i.e.: starts when the home server start).
On the Virtual Server Admin Site under Virtual Server, choose Server Properties.
On the bottom of the page under your server Properties, click on Virtual Machine Remote Control(VMRC).
On the Virtual Machine Remote Control (CMRC) Server Properties page, ensure you enable VMRC server and specify a TCP/IP port that is not already in use on the server. Then click OK to reflect the changes.
OPTIONAL: Back on the left-side menu of the Virtual Server Admin Site, under Virtual Server you could click on Resource Allocation to specify the maximum amount of resources your virtual machines can use in order to ensure resilience to your home server.
Once again on the left-side menu of the Virtual Server Admin Site, under Navigation click on Master Status in order to see your recently created virtual machine. Hove the mouse over its title to show its context menu that would allow it to start and stop the virtual machine, as well to Remote Control it.

All done! Once I got my Linux box installed, I was running things like shell scripting, mySQL, Apache, PHP and other nifty tools. I hope you found this little guide useful!

As a next step, you could look into Microsoft Services for Unix for good interoperability between your Linux virtual machine and your Windows hosts. You can find more about Windows Services for Unix here.

0

#2
User is offline   smadge1 (WGS) 

  • Advanced Member
  • PipPipPip
  • View gallery
  • Group: Moderators
  • Posts: 532
  • Joined: 20-January 08
  • Gender:Male
  • Location:Brisbane, Queensland, Australia
  • Interests:Computers<br />Digital Photography<br />Travel<br />Cat
Linux on Windows?

whoever heard of such a thing? :P
0

#3
User is offline   jstueve 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 172
  • Joined: 30-January 08
  • Gender:Male
  • Location:Plano, TX
I'd go the VMWare route (VMWare Player and Server are both free to use)

I'd also suggest more than 1 GB RAM, and I'd put the VM image on a non-pooled drive, and definitely not a shared folder.

You'd end up with what amounts to another machine from how it looks on your network, so there are some external networking issues if you're trying to run Apache or other LAMP solutions in the new Linux VM.
0

#4
User is offline   azjerry 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 114
  • Joined: 11-April 08
  • Location:Phoenix, AZ
Where do you put the virtual hard drive so that it doesn't trigger the corruption bug?

Edit: jsteuve and I must have been typing at the same time. If I had seen his post I wouldn't have entered mine. ;)
0

#5
User is offline   Kenny McCormick 

  • Member
  • PipPip
  • Group: Members
  • Posts: 14
  • Joined: 18-January 08
  • Gender:Male
  • Location:Sweden
Im running VMware Server on my WHS (specs in sig) with two virtual Windows Server 2008 boxes. One is a Core install that works as a Domain Controller, DNS and DHCP, the other one is a Full install that I use as Web and Mail Server.

I have no problems at all with my setup.
0

#6
User is offline   Pedro Innecco 

  • Member
  • PipPip
  • Group: Members
  • Posts: 10
  • Joined: 03-June 08
  • Gender:Male

View Postazjerry, on Jun 3 2008, 02:42 PM, said:

Where do you put the virtual hard drive so that it doesn't trigger the corruption bug?

Edit: jsteuve and I must have been typing at the same time. If I had seen his post I wouldn't have entered mine. ;)


JR,

Good point. The way I did, I put the virtual Hard Disk in the C:\ drive itself.

The reason I did it this way is that for the virtual machine drive, I don’t think I need to have tombstones or any other kind of gimmicks used to handle the DATA partition.

Alternatively, I *THINK* a user would be safe in simply adding the virtual hard disk drive into a directory in the D:\ drive which is outside of the shared folders structure. For example, I use uTorrent on my home server and the temporary directory of incomplete downloads is at “D:\incomplete downloads\utorrent” — and I never had data corruption issues.
0

#7
User is offline   Pedro Innecco 

  • Member
  • PipPip
  • Group: Members
  • Posts: 10
  • Joined: 03-June 08
  • Gender:Male

View Postjstueve, on Jun 3 2008, 02:41 PM, said:

I'd go the VMWare route (VMWare Player and Server are both free to use)

I'd also suggest more than 1 GB RAM, and I'd put the VM image on a non-pooled drive, and definitely not a shared folder.

You'd end up with what amounts to another machine from how it looks on your network, so there are some external networking issues if you're trying to run Apache or other LAMP solutions in the new Linux VM.


VMWare is far better than Microsoft Virtual Server (IMHO). For example you could have a guest OS (that is, your Linux on a virtual machine) runing as 64bit. Microsoft Virtual Server for now only allows guest operating systems running in 32bit.

This is that in my experience VMWare server is more resource hungry. Also, I opted for Virtual Server because Microsoft Update should take care of manually installing updates for me. After all my HP MediaSmart is supposed to be a headless server :)

As for the disk. If you plan to have your Linux running from a virtual hard drive (that is, a file acting like the hard drive) then I suggest:

To have the virtual HD outside any replicated shared folder. This is regardless of any data corruption or not. I think it would simpyl be overkill to have a virtula hard disk, which is a file in the Windows Home Server filesystem, being replicated!

In fact, I would ensure the file is out of the share folders on the DATA partition. I would go further and suggest the file is completly out of the DATA partition. Either put your virtual disk on the C drive, or have it running on another disk (e.g.: external USB HD/Key).

In fact, if you are planning to use an entire physical partition for your virtual Linux instead of a virtual HD on a file, then I suggest that you configure your Virtual PC to use a linked virtual hard drive. That is, it will use a physical partition instead of creating a file.

Hope my comments are useful!

Regards,
P.
0

#8
User is offline   azjerry 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 114
  • Joined: 11-April 08
  • Location:Phoenix, AZ
Depending on how big you want your virtual hard drive, drive C may or may not work. After all it's only 20G to start with. Start subtracting space for WHS software and whatever other programs you might install ...
0

#9
Guest_Drashna (WGS)_*

  • Group: Guests
Depends on how much planning you are doing for this. There is a way to actually increase the system partition size, but best method is during installation.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users