Linux on Windows
If you're interested in virtualization, I also have a page about running a virtual Mac inside Windows.
Like many people, for many years I've been thinking of switching from Windows to Linux. Every once in a while, I installed a distribution on an old laptop to see how easy Linux had become. Until 2009, I could not get an installation where everything (internet, sound, graphics) worked out of the box—without my needing to spend hours searching on forums how to fix things that weren't supposed to be broken in the first place.
I won't switch, but I do run Linux inside Windows, with VMWare or VirtualBox, and I love it. This page shows you how.
This all changed in 2010, when I tried Linux Mint. I still didn't switch to Linux: I run it inside Windows, and I love it. That's what this page is about.
Before we start, a few points should be clarified.
Why I Won't Switch to Linux
In case I ever forget, here are the reasons why I am not about to abandon Windows:- I cannot live without Adobe Creative Suite (Photoshop, Dreamweaver, Acrobat Pro, Indesign, Illustrator).
- I need Intuit products such as Quickbooks and TurboTax for business.
I love Linux, and below I explain why. But at the moment, if you're a graphic designer or produce books with Indesign, I don't think you're going to use Linux. The Adobe programs are just too compelling. Same if you absolutely need to use a piece of business software that only runs on Windows.
On the other hand, Linux is probably perfect for you if you want to:
- administer a system that end-users can't mess up too much
- build a cheap entertainment box
- create software for Linux!
- hack into Windows systems :)
Like Windows and like MacOS, Linux is perfect for… the people who love it!!! And who's that? Largely, people who are a bit more "geeky" than your average Mac or Windows user. That's not exactly the same segment as graphic artists, "normal" business users, etc.
Why I Need to Run Linux
I don't. At the moment, I just have Linux "in my pocket" as a virtual machine on my Windows system, at the ready in case I ever need it. I like having Linux "in my pocket" because I can see a day coming when I'll want to run an application that doesn't have a Windows version.If you know of useful apps that only run on Linux, I'd be grateful if you'd help improve the page by sending comments through the form all the way at the bottom.
Why I Do Run Linux
Because it's cool. Here are things I love about Linux.- Linux has a really great way of installing new software. On Windows, when I need a utility to do a certain job, I often download from unknown software vendors and try a few programs, hoping they won't crash my system. By now I'm pretty good at finding safe programs, but the process still worries me. On Linux, you open the menu, start the "Package Manager", type in the first letters of a program, and let the the Package Manager download and install it for you. (In Mint 13, the Package Manager is under Menu / System Tools / Administration / Synaptic Package Manager.) The Package Manager tries to resolve potential incompatibilities as it installs new programs. And the programs you install this way have been reviewed by the community (most of them are open-source), so they are intrinsically safer than most Windows freeware. Also, much Linux software shares libraries, so you don't end up bloating your system as much with duplicate functions. Sure, you still have to know what to install.
- Linux is free! Isn't that amazing? I can see installing Linux Mint on old systems that have become unstable and need a fresh OS installation.
Why I probably shouldn't run Linux
Because I love to play with the computer. It's enough to manage my machine, my lady friend's machine, the virtual machine on which I run Windows 2000 for 16-bit applications, and the machines of whoever's place I'm staying at! If I also run Linux all the time, my whole life becomes absorbed by the computer. That's okay, but I like trees too! :)Running Linux on Windows
The rest of this page deals with setting up and using Linux within a "Virtual Machine" on Windows. Using "virtualization software", you create a virtual computer that shows up as another windows on your Windows system. It's like having a whole 'nother computer inside your regular computer! It's a bit magical. If you get into it, you may want to check out my page about running a virtual Mac inside Windows.Which Distro?
You're probably aware that Linux comes in various flavors: Fedora, Ubuntu, etc. We'll be using Linux Mint. It's been introduced to me as Ubuntu without the bugs. And Ubuntu has presented itself as a version of Linux that works out of the box!
I have installed Ubuntu and other distributions in the past; it was never the seamless experience promised by the Ubuntu priests. At the end of the installation, there was always something that didn't work: networking, sound, etc. Solving these glitches would mean diving for hours into forum world. Perhaps by now Ubuntu does work straight out of the box; I don't know.
What I do know is that with the method outlined below, my Linux Mint installs have perfectly integrated with my hardware right away. Also, unlike other distros, Linux Mint includes a lot of codecs that you would otherwise have to download. Coming from the Windows or Mac world, it's a little strange to be asked to download and install missing pieces the first time you want to play an mp3 file, a movie, etc. So I'm really really happy with Linux Mint. But you can adapt the process below for any other distro you'd like to try.
Which Virtualization Software?
There are several free virtualization programs. Microsoft's Virtual PC, which I use to run 16-bit applications in 64-bit environments, doesn't virtualize Linux. On this page, I explain how to set up Linux Mint with either the VMWare Player or VirtualBox by Sun Microsystem. If you have no preference at the outset, I recommend you go with VMWare. Lower on the page, there is a section that compares running Linux Mint on VMWare vs VirtualBox. If you'd like to install VirtualBox anyway, you can skip to the VirtualBox section, otherwise read on.
Linux Mint on VMWare: The Fastest Way
The first time I installed Mint on VMWare, I did a full install (this was for Mint 8, a.k.a. Helena). If you want to go that way, follow my guide in the next section—updated since my last install, for Linux Mint 13 (Maya). Recently, some people have been sharing pre-made VMWare images on the VMWare site. On my hot rod system build, I installed Mint 11 (Katya) that way. It was really fast and easy.For this, you need:
- a copy of the VMWare Player (free). Go to the VMWare site, click Downloads, find the Player and follow the steps.
- a VMWare image. On the VMWare site, in the search box, type "Mint" and the number of the latest release, for instance "Mint 13". At the moment the Cinnamon desktop is the standard release (the alternate release with the Mate desktop is based on an earlier version of the Gnome desktop).
In VMWare, choose "Open a Virtual Machine". Don't run the machine right away: you'll be better off if you change a few settings first. I suggest setting the RAM to 1GB or more if you can afford it. Also if the VM contains silly things such as floppy drives and serial ports, set them to "Auto Detect" in order to avoid error messages.
You can then run the machine. To fine-tune your Linux Mint VM (e.g. sharing folders or changing the background image), read below in the full install and configuration sections.
Linux Mint on VMWare: Full Install
For this, you can use any version of VMWare. On my first install I used the free VMWare Player, on the last I used VMWare Workstation.- Install VMWare Player or Workstation, then reboot
- Run VMWare. Create new machine.
- Choose "I will install the operating system later"
- Guest: Linux, Ubuntu.
- Click "Edit Virtual Machine Settings". Give yourself at least 1GB of RAM.
- Still in the settings, point the CD drive to the Linux Mint ISO you downloaded.
- Under Display, select "Accelerate 3D Graphics", otherwise the Cinnamon desktop won't work. (To consume fewer resources, you can also install the MATE edition.)
- Leave all settings unchanged for now.
- "Play" the virtual machine. It will boot from the ISO. At the desktop, click on "Install Linux Mint".
- Proceed with the standard installation. After the installation ends, click on "Restart". If the VM doesn't restart, select Power Reset from the VM menu at the top of the screen.
- When the VM boots from the new install, the Linux Mint installation CD-ROM will appear on the desktop, as it is still mounted by the VM. Right-click, choose Eject.
- Without VMWare tools, many things on your VM (such as resolution) will not work: read the next section to install.
Installing VM Tools
This is an essential part of the installation.
From the top toolbar select VM / Install VMWare tools.
- Double-click Computer on the desktop, right-click VMWare Tools, select "Mount".
- In the CD-ROM, drag the tar-gz file to the desktop. Right-click and extract to the desktop.
- Right-click the unpacked folder, select "Open as Admin".
- Double-click the file with the .pl extension. Accept all the default options, pressing Enter everytime the program asks a question. VMWare Tools will now be installed.
- Restart the VM. If your resolution is not perfect by the, click on the Menu icon, then select System Tools / System Settings / Displays, and pick the same resolution as your windows system. You can now use Linux in full screen!
- You should also now be able to share folders on your Windows system with your VM! (see below).
Using USB
If you instert a USB stick, it should show in Linux Mint.
Transfering files between Windows and Linux Mint
- You should now be able to copy-paste between the two environments.
- Now that VMTools are installed, you can also drag-and-drop files between the two environments. Just go slow when you're dragging over the edge of the VM, or you won't go anywhere.
- You can also "share" some of your Windows folders in order to access them in Linux Mint. I put "share" between quotes because it is not the same sharing process as in Windows (in some ways the VMWare process is simpler, because Windows sharing requires a lot of configuration). Once a folder is shared, you can drag and drop files to your Windows system within Linux Mint. See below.
Sharing Folders between Windows and Linux Mint
- In Linux Mint, click "VM" in the VMWare bar at the top, then "Settings". Notice at the top there is a "Hardware" tab and an "Options" tab. Choose options. Click on Share Folders, follow the wizard. Give the share a meaningful name.
- To see the shared folder on the VM, you will need to navigate to the right folder. Click on Computer, then File System, then mnt, then hgfs. Your host folders are inside!
- I did not find a way to make a shortcut to my Windows folder on the Mint desktop. But I managed to make a shortcut to the folder above it (hgfs). While navigating the file system, right-click mnt, choose "Open as Root". Now right-click hgfs, choose "Create link". Drag the link to your desktop. Rename it to something meaningful (it contains your Windows folders).
Internet Connection
- Under VM / Settings, there are three choices for networking: NAT, Bridged, Host.
- When the host is on wireless, NAT works (Firefox can get on the net in Linux Mint).
- When the host is connected via Ethernet (LAN), NAT doesn't work for me, but Bridged does. It's easy to change under VM / Settings.
Allowing yourself to run things without needing a password all the time
- Open a Terminal window (Click Menu / Terminal)
- Type:
sudo visudo
- In the editor, below the line that says "root ALL=(ALL) ALL", add this line (where it says "yourname", enter your user name):
yourname ALL=(ALL) ALL
- On the very last line, add:
yourname ALL=NOPASSWD: ALL
- Press Ctrl+X to exit, Y to save, and delete the .tmp extension in the file name so that the changes are made to the original sudoers file.
Printing from Linux Mint on VMWare
There are two methods for this. The first (which only works for printers connected via USB) is fast, but it requires Linux Mint to find the drivers for the printer—which, for me, it has done automatically, and very fast. The second method also works for USB printers, as well as any printer accessible to the host machine. It requires that you shut down (not just suspend) your VM. It creates a "virtual printer" and passes your print instructions to the host machine.
Let's start with the "quick & dirty USB method". If your printer is connected to your computer via USB, at the top of the VM window, click VM / Removable Devices, choose your printer, then select "Connect (Disconnect from Host)". Linux Mint is very good at finding drivers for you. If all goes well, your printer should be available within a minute or so. You can then select it from any document you try to print.
Let's now look at the "virtual printer method". To use this method VM Tools must be installed, but by now this must have been the case for a long while. If your VM is in a suspended state, open it then shut it down properly. In the left side of your VMWare Player window, select your Linux Mint VM. On the right side, select "Edit Virtual Machine Settings". In the Hardware tab, at the bottom, click "Add". (If this option is greyed out, your VM is probably in suspended state: you need to shut it down.) Select "Virtual Printer". Launch your Virtual Machine. When you try to print a document, all the printers of the host machine should be available. If a problem arises, follow the directions of the troubleshooter that pops open.
Linux Mint on VirtualBox
I actually started with VirtualBox because I hadn't loved my first experience with VMWare, when I'd tried to virtualize Ubuntu. (It had started with having to register before being allowed to download the software. Then I had not understood how to install Ubuntu, so I'd given up. And it seemed to me that VMWare was leaving all kinds of footprints on my system even when I wasn't running it.)Here is the step-by-step guide to installing Linux Mint with VirtualBox. (Click here if you'd like to go straight to VMWare).
- download and install VirtualBox.
- download the Linux Mint iso.
- Mount the Linux Mint iso with Alcohol (install it if you don't have it).
- Run VirtualBox. Create a new VM for Linux Mint (give it at least 256MB of RAM. On my installs, I allotted 896MB.) Point the VM to the CD you mounted with Alcohol.
- Linux Mint will run from the virtual CD. Once Linux Mint is loaded from the CD, you need to install it to the virtual hard drive. On the Linux Mint desktop, you will see a "Install Linux Mint" icon. Click it.
- Take all the default options, or follow this tutorial for this part of the process.
- Once the install finishes and Linux Mint runs for the first time from the virtual hard drive, your screen resolution will be too small. You will now need to install a VirtualBox component that does not install by default.
- Quit VBox. On your windows system, search for VBoxGuestAdditions.iso. Mount this iso file in Alcohol. Install VBox Guest Additions. Reboot.
- Run VirtualBox and load Mint. On the menu at the top, choose "Device / Install Guest Additions"
- In Mint, click on Menu, Terminal.
- Type:
cd /media/cdrom0
- Type:
sudo sh ./VBoxLinuxAdditions-x86.run
- Enter your password if needed. Install. Reboot Mint.
- At this stage, to get the right screen resolution, all you need to do is drag the corner of the VirtualBox window.
- If you'd like to login automatically, click the Menu, type "login", click on "login screen", unlock and check the box.
Sharing Windows Folders
You can access your Windows folders within Linux, but it takes a few more steps. The other option is to drag-and-drop or copy-paste between the host and guest.
- Close the VM. In VirtualBox settings for the VM, navigate to "Shared Folders" and specify the folders to share. For instance, for now, let's say you want to share one single folder (and it's subfolders): your desktop. Select it through the browse function, and give it a share name: WINNY. You now need to "mount" this folder in Linux Mint.
- Start Mint. In the file system, under your name, create a "SHARE" folder. In the "SHARE" folder, create a WDESK folder. Right-click on WDESK, choose "make link". Drag the shortcut to your desktop.
- To mount the folder manually each time you boot Mint, open a terminal window (Menu / Terminal) and type:
sudo mount -t vboxsf WINNY ./SHARE/WDESK
Mounting Shared Folder Automatically
First, you will need to give yourself authorization to run scripts without entering a password.
- In a terminal window, type:
sudo visudo
- In the editor, below the line that says "root ALL=(ALL) ALL", add this line:
yourname ALL=(ALL) ALL
- Also, on the very last line, add:
yourname ALL=NOPASSWD: ALL
- Type Ctrl+X to exit, Y for save, and…
- Make sure to remove the "tmp" extension from the file name so that the original sudoers file is replaced.
Now let's create the script.
- Open a terminal window (Menu / Terminal). Type
cd SHARE
. Type:nano mount-WINNY
(to create a script that will mount the drive). In the editor, type these two lines:#!/bin/sh
sudo mount -t vboxsf WINNY $HOME/SHARE/WDESK
sudo mount -t vboxsf WINNY $HOME/SHARE/WDESK
- Press Ctrl+X to exit, Y to save. Type
ls
to make sure the file mount-WINNY has been created.- To make the script executable, type:
chmod +x mount-WINNY
- Exit the terminal window.
- If you like, you can run the script manually, perhaps with a link on the desktop.
- Or, to run the script at startup, click Menu, then type Startup. Choose "Startup Applications", click "Add". In the Command box, browse to the script in the SHARE folder. In the Name and Comment boxes, enter something descriptive like "Mount Windows Desktop".
VMWare vs VirtualBox
I was prepared to prefer VirtualBox to VMWare, but the results point the other way.Where VMWare Rules and VirtualBox Sucks
- With VirtualBox, the Linux Mint desktop is buggy. There are often larges patches of black on the desktop where the desktop hasn't been refreshed. And the Full Screen work does not work—so far. If you know how to make it work, you'd bring me a big smile by posting a comment at the bottom of the page. With VMWare, the desktop runs smoothly, including Full-Screen mode.
- Speed. I was expecting the opposite, but, where it counts for me, VMWare leaves VirtualBox in the dust. VMWare launches Firefox in 3 seconds (4 for VB). VMWare launches Gimp in 12 seconds (18 for VB). Like VB, VMWare suspends the virtual machine in 6 seconds. It resumes it in 5 to 30 seconds—where VB sometimes cannot resume. When booting Linux Mint cold, VMWare is slower than VirtualBox: 1:32 vs 1:11.
Where VMWare Sucks and VirtualBox Rules
- I have not tried this function, but apparently VirtualBox lets you take a "snapshot" of a machine's state. This enables you to restore the machine later if something goes wrong.
- VirtualBox has a "Pause" function for those times when you need more CPU power on the host. I have't used this, because if I know I need resources, I will suspend the machine.
- Clone function. Another VBox function I haven't tried.
Where both VMWare and VirtualBox need Work
- The Folder Share function. On VMWare, once VMWare tools were installed, adding shared folder was a snap. On the other hand, on the Linux Mint desktop, VMWare doesn't let me make a shortcut to a my Windows desktop! (But it's possible to make a shortcut to the next folder up). With VirtualBox, on the Linux Mint desktop I can have a shortcut to my Windows desktop. Yeah! On the other hand, the feature was hard to install (if educational).
Where VMWare and VirtualBox Both Rule
Hey, you're running Linux Mint on Windows…Hard to argue with that! It just rocks, no?
Configuration
A few tweaks to feel at home with your new system.Background
Menu / Preferences / Appearance / Background
Keyboard Shortcuts
On Windows, I use the Windows key shortcuts a lot. One of the first things I want on Linux is the same shortcuts. Click Menu, type: short, select Keyboard Shortcuts. This is what I start with:
Windows + M: Hide All Windows and Set Focus to the Desktop (under "Window Management")
Windows + E: Home Folder: opens the file explorer, Nautilus (under "Desktop")
Windows + S: Search (under "Desktop")
Windows + T: Run Terminal (under "Desktop")
Windows + C: Launch Calculator (under "Desktop").
Taskbar Shortcuts
You can drag shortcuts there. I start with Firefox, Salculator, Terminal, System Monitor.
File Manager
If you're used to Windows Explorer, the Mint file manager's default configuration will drive you crazy. In Windows I don't even use Windows Explorer but a fancy, expensive replacement called Directory Opus. So the Mint file manager definitely doesn't talk to me when it comes out of the box.
If you can't get it to work for you either, you may want to try other file managers (probably not Thunar and PCManFM, which are similar). I have tried Gnome Commander and Dolphin. In 2010 Krusader was my darling (Mint 8) because I love a file manager with loads of options. But apparently it is not working on recent versions of Mint.
I've heard good things about spacefm, but haven't tried it yet.
Linux Commands
When you get started with the command line, you may be amazed by the number of time you're asked to enter a password. This command lets you work as root and enter all subsequent commands without being policed:sudo su -
In case you get lost in the file structure,
pwd
shows you where you are, and cd /home/YourUserName/Desktop
gets you back to your desktop.Newbie Tips
A few bits of information that can dispel some of the confusion when you land in the Linux world.When I started with Linux, I came across mysterious forum posts that talked about "running X" or "restarting X". What is X? It is short for "XWindows". It is basically the graphical user interface you take for granted (as opposed to running your computer from the command line). On Mint and other Linux distributions, if you ever find yourself at the command prompt, locked out of X Windows and wanting to get back in, type:
xstart
Links
Want to learn more? Here are a few Linux tips.Need software? Here's a list of linux alternatives to windows.
CommandLineFu has a great collection of one-line commands for the terminal window.
If you find other great resources, please post a comment below!
Smiles,
Andy
Comments are Closed
Got it all right thanks to your little guide too :)
Thanks angain, Julius
Thanks for your article; it's like 'lite' instead of extra heavy whipped cream. I too am a fan of Linux Mint after trying several other Linux flavors. A few years ago I decided to push away the X and go with Ubuntu. Unfortunately there was too much for me to learn all at once. So I bought an extra PC at a pawn shop to install Ubuntu on and learn a little at a time. Soon I was introduced to Mint and enjoyed it a lot more. I still depend on windows for my graphics work and QuickBooks.
Now I'm considering (again) installing VMWare and Linux Mint in Win XP or 7, and found your tutorial helpful.
Thanks again.
Thank you for your message. After receiving it, I added a section about installing Mint from a pre-packaged VMWare image (search 'fastest' on the page) as those are now available. Wanted to give you the heads up before you dive in.
Funny that you use Windows for QuickBooks: me too! I run Quickbooks'98 in Windows 2000 (in VirtualPC). That old version still works after all these years---anything to avoid the Intuit bloatware upgrade cycle. <img src='http://b.yu8.us/talk/smilies/smile.gif' alt='' />
Good luck with your install.
Wishing you a fun evening,
Andy
- Mount the Linux Mint iso with Alcohol (install it if you don't have it).
What for? Virtualbox is able to use the ISO-Image directly.
Thanks much, Andy!