Linux and Windows: Mixed doubles - Part 2

We continue our two-part guide to Windows and Linux on the same PC, starting with a look at emulator Wine and how to run Windows applications under Linux.

Kelvyn Taylor and David Ludlow

The functionality of the current version of Crossover Office has been significantly improved compared to previous versions. You can now run the current versions of the most important Office applications as well as other popular office software. The following list gives an overview of the officially supported Windows programs.

Back to Wine: all current distributions include the emulator. If it's not installed initially, it can easily be added later with the help of the application manager. Under SuSE, use Yast and add Wine to the application list. Many distributions still include the old version of Wine with the graphical configuration front end.

Advertisement

However, the current version of Wine, version 2, needs to be configured manually. The.config file is created automatically at the first startup and is stored in the user's home directory, /home/$user$/wine.

First, use the command mkdir c to create a subdirectory named 'c'. Next, use your favourite text editor to edit the.config file. The file is split into various sections which you can adjust according to your own requirements and preferences.

Configuring drives and directories
First, you need to tell Wine which Linux directories will act as Windows drives. This entry, for example, links the C drive to a folder in the user's home directory:
[Drive C]
"Path" = "/home/usr/.wine/c"
"Type" = "hd"
"Label" = "Windows"
"Filesystem" = "win95"

Use the same method to define further virtual Windows drives or create links to real Windows partitions. A CD or DVD drive with the letter D has an entry like this:
[Drive]
"Path" = "/mnt/cdrom" or
"/mnt/dvd"
"Type" = "cdrom"
"Label" = "CD-ROM"
"Filesystem" = "win95"
"Device" = "/dev/hdc"

For the Device entry, you must enter the correct Linux device file used. It's important that this matches the correct device file for the drive to be used. So, the Linux device file /dev/hdc points to the master on the secondary IDE port; /dev/hdd is the slave drive on the secondary port.

Temporary drive
The Windows temporary directory also has to be referenced in the Wine configuration file. To do this, define a link from the temporary Windows drive to the Linux temporary directory. The entry in the configuration file should look like this:
[Drive E]
"Path" = /tmp"
"Type" = "hd"
"Label" = "Tmp Drive"
"Filesystem" = "win95"

Basic Wine settings
After this, edit the (wine) section to specify which directories should be used by the virtual Windows. A link to a real Windows partition is not necessary and the resulting entry looks like this:
[wine]
"Windows" = "c:\windows"
"System" = "c.\windowssystem"
"Temp" = "E:"
"Path" = "c:\windows;c.\windowssystem;e:\;f:\"
"Profile" = "windowsProfilesAdministrator"

Windows libraries under Wine
Wine comes with its own native libraries (DLLs), which should replicate the functions of the corresponding Windows library. Usually, Wine's own files work well. However, in some circumstances, errors do occur.

If you run into problems running a Windows application then you can use the original Windows DLLs instead. Simply copy them from the Windows partition to the Wine directory, and specify in the configuration file which type of library (Wine or native Windows DLL) is to be used.

The manual integration of Windows-specific DLLs is, however, complicated by the need to take into account dependencies on virtual drivers and the relationship with other DLLs.

Windows applications under Wine
The number of Windows applications which work with Wine has increased markedly over the past few years. The Wine project has published a list of supported Windows applications. These are the most important:

The more complicated programs do still need a lot of configuration work, which can pose problems even for expert users. For first time users it's worth browsing at one of the many online discussion forums, for example, www.frankscorner.org.

Knoppix - the universal solution
Knoppix is a great way to try out Linux. It allows you to install and run a fully functional Linux distribution without writing a single byte to your hard disk.

If you're working with Linux for the first time, Klaus Knopper's mini-Linux distribution is worth a try. A current version of the Knoppix ISO image (this allows you to burn a bootable CD) can be downloaded from www.knoppix.net.

At 700MB it's quite a large download, but if you don't have broadband or the time to download this much, you can order a CD via mail (£2.50 plus £2 postage & packing) from vendors such as The Linux Emporium.

Knoppix boots and runs directly from the CD - it doesn't even need a hard disk to be present in the PC. Knoppix gives you all the important Linux functions, and has comprehensive hardware support. It automatically detects and loads drivers for your hardware components during the surprisingly quick boot process. There's even a complete Office suite included - the open-source OpenOffice.org.

After the startup routine, Knoppix stores all files generated by the operating system on a temporary 'partition' created in your PC's Ram. Because of this, it's only suitable for use on PCs with at least 128MB of Ram installed. Nothing is written to your hard drive unless you want to write a data file.

Installing Knoppix on a hard disk
Users who want to add extra packages to Knoppix can also install the distribution on a hard disk. To do this, start Knoppix as usual from the CD, log on as root and start the setup routine by typing 'knx-hdinstall' in a root shell terminal window. This fires up the installation script where a series of menus talks you through the configuration.

The first step is to pick which hard disk Knoppix should be installed on. Linux uses a different naming scheme from Windows:

Once you have selected the disk to use, Knoppix starts the partitioning program, cfdisk. This is where the root and swap portions are configured. Once the partitions have been created the installer copies the OS files to the hard disk, which can take a while.

Once complete, there's just a small amount of configuration to be done to choose how Knoppix should run. First, you have to pick which background and network services should be running, including mail (smail), SSH (Secure Shell) and Samba.

Finally, Knoppix needs to know if it should start in text or graphical mode. In graphical mode it uses the KDE desktop.

Linux plus Windows equals Lindows The operating system Lindows is an attempt to integrate Linux and Windows on the desktop. An American Linux distribution, Lindows is supposed to bring together the respective advantages of Windows and Linux.

With the help of Windows emulator Wine, Lindows runs both Windows and Linux software using a common graphical interface. This works very well for Linux programs, but for Windows programs the same restrictions apply as for Wine.

It's noticeable that Lindows mimics the well-known Windows appearance, including Windows-like icons and desktop designs. This is meant to make the switch to Linux easier for Windows users.

The concept of Lindows is interesting; however, many experienced Linux users remain sceptical about the whole thing because many common Linux functions are not available because of the design.

Lindows is currently on version 4, which includes plug and play support, font rendering, virus scanning and optimised printer support. Its implementation is supposed to make it easier for users to move away from Windows, but it's hard to see any improvement over the normal Linux distributions such as SuSE or Red Hat.

In addition, Lindows is a commercial product costing $50 (£31 approx), with a $50 annual subscription on top of that.

Create a virtual PC with Vmware
Another alternative to running Windows applications under Linux, or Linux programs under Windows, is to use a PC emulator such as Vmware, which is available from around $300 (£187).

VMware creates virtual machines, allowing you to simulate one or more PCs, and is available for both Windows and Linux. These virtual PCs can each run a 'guest' operating system, although the Linux version only lets you run Windows XP. It's even conceivable that you might have several virtual Linux machines running under a single Windows host.

After installing VMware under Windows you can, for example, install Linux on a virtual PC. This virtual PC sits in its own program window like any other application, so Windows is just an Alt & Tab away. Or, if you prefer, the application can run in full-screen mode, so it physically looks like it's running Linux natively.

However, only those features that the emulated hardware offers are available, which is of particular relevance with graphics. There's also the problem that the host and virtual PCs have to share the same physical Ram.

Performance limitations
Functionally, using VMware has little effect on the use of Linux or of Windows. Both programs make use of the host system's hard disk and optical drives and write the guest operating system to a predefined space in the form of an image file.

This system has the added advantage that the image file, which contains the current state of the guest operating system, can be backed up using any standard backup application.

Naturally, USB ports, serial connections and network cards can be addressed on the level of this emulation layer. In practice, however, the virtual operating system is slower than a physically installed operating system.

In addition, you will not be able to access certain specialised hardware components such as Windows printers, but will have to be content with the emulated components. 3D graphics card functions are also unavailable under VMware.

However, if you want to make straightforward Linux server services available or use Microsoft Office applications under Linux then VMware is a good choice.

Useful web links
www.vmware.com: home page of VMware; demo version, current information and patches available for download.

www.microsoft.com: information on Virtual PC (PC emulator for Windows and Linux).

www.winehq.com: Wine is a complete emulation environment for Windows in the form of its own APIs, including a corresponding class system.

www.transgaming.com: information on WineX, the commercial version of Wine, which is particularly useful for running Windows games under Linux.

http://frankscorner.org: numerous instructions and FAQs on Wine.

www.codeweavers.com: the Crossover Office manufacturer's website, where you can download the 30-day demo version.

www.cygwin.com: Cygwin is a Unix emulation based on Windows, with which Windows users can carry out BASH commands.

Distributions and variants
www.knoppix.org: free Linux distribution which runs from CD and does not have to be installed.

www.lindows.com: Lindows is a Linux distribution aimed at users changing from Windows (commercial).

  • Have your say
  • Send to a friend
  • Print
  • Digg
  • Reddit
  • Share

Tags:

Do you agree?

Further reading

Open Debate

The Open Debate

The pros and cons of Windows and Linux in enterprise IT

Linux live and kicking

Linux live and kicking - Part 1

Live distributions of Linux let you find out if you are compatible with the open source operating system before you make a permanent commitment

Linux live and kicking - Part 2

We continue our look at live distributions of Linux that you can use to find out if open source is for you before taking the plunge

Open source

Linux is becoming the operating system of choice for an increasing number of corporates, and even the mighty Microsoft is acknowledging the threat ...

Related whitepapers

Related jobs

Most watched

Summit: Views From the Valley

V3.co.uk's US office weighs in on the information overload crisis

John Chambers speaks on collaboration

Cisco boss talks up new offerings

Analysis and Reports

Remote access - Three steps to getting connected

3.4 million UK professionals now work from home – is your company equipped?

Cost benefits of a global collaboration network

This white paper is a must read for organisations looking for evidence of the bottom-line benefits of high-definition video and voice communications

Poll

Impact of Information Overload poll

Impact of Information Overload poll

What is the biggest problem your firm faces as a result of the data explosion?

View poll results

Advertisement

White paper library

Keep up to date with the latest products, services and technologies from the world's leading IT companies; IThound.com brings you over 6,000 white papers, case studies and analyst reports.

Advertisement

Newsletter signup

Sign up for our range of FREE newsletters:

Existing User

Newsletter user login:

Enter email address to edit your newsletter preferences

Job of the week

Search thousands of IT jobs :

Search thousands of IT jobs:

Advanced search

Hiring now on ComputingCareers:

Related IT jobs

Search thousands of IT jobs :

Search thousands of IT jobs:

Advanced search

Advertisement

Spotlight

Information management

Summit: Quiz IBM experts on information strategies

Join our live chat session on Thursday at 11am to...

RIM discusses new developer tools

Blackberry exec on the latest offerings for programmers

Houses of parliament

Summit: Doubts raised over Tory plans for NHS records

Experts say data quality could be an issue

Researchers take down spam botnet

Researchers from security firm FireEye have been able to effectively...

Primary Navigation