coLinux: running Linux from within Windows

Cooperative Linux (coLinux) is a very interesting project i stumbled upon a few days ago. The idea of this project is to allow a Linux Kernel to run at the same time (cooperation) with the Windows system instead of doing virtualization or emulation. The result is an amazing speed if compared to VirtualBox or other virtualization solutions expecially in I/O and network operations.

coLinux can run as stand-alone application (you get a console with working virtual TTYs) or as a system services. It can be insalled on Windows 2000, XP, Vista and Windows 7. Only 32bit mode is supported at this time but 64bit support is under work thanks to a $5,000.00 sponsorship they got.

Installing coLinux

Installation cooperative Linux is quite straightforward:

  1. download the colinux stable installer from sourceforge (8MB) and run the setup program, follow all the normal procedure for a Windows software;
  2. after setup download a pre-built Linux distribution from the same page, i choosed Debian 6 (35MB);
  3. extract the .7z archive with the distribution into the coLinux installation directory, be carefull that the archive is 35MB but after extraction the file will be 2GB;
  4. rename the extracted file as rootfs_2gb.img
  5. now execute squeeze.bat to run coLinux

Et voilà, you can now login as root with blank password:

Configuring coLinux

What you get out of the box is a very minimal system, you need to install all the extra packages you wish but with 2GB is quite a few space, so first of all you may wish to move your system to a larger partition. Luckly is not difficult and there are a few way to enlarge your default coLinux root partition to install more software.

After you’re done you can start installing all your favourites packages via apt-get.

The first things you maybe wants to setup are: network, keyboards, ssh, Windows drives or directories.

Configuring coLinux networking and ssh

coLinux network should work out of the box with the SLIRP driver that allow you to use eth0 interfaces via a TUN/TAP driver that gives access to internet but other machines on the real network will not able to access coLinux.

So, in order to access your coLinux system via SSH you need to configure port forwarding into the SLIRP driver. Its sounds complicated but in reality is quite easy. Edit the squeeze.conf file and change the line:




then shutdown and restart your system.

Is it advisable to use coLinux via SSH because the default console does not supports scrollback!

Configuring coLinux keyboard and locales

If you have a non-US keyboard is quite advisable to install the Debian’s keyboard layout packages and the locales data too.

This is super easy just install the packages:

apt-get install console-setup locale

Also if you want to change the console size to have something bigger then the default 80×25 screen you can add the following line to the squeeze.conf file:


then halt and restart the system again.

Accessing Windows directories from coLinux

Differently from other softwares, coLinux allow you to access windows drives and directories like a breeze. Everything you have to do is to configure your config file adding this line:


then halt and restart the system again.

Once the system has been configure you can mount this directory with the mount command:

mount cofs0 /mnt/ -t cofs

or configure /etc/fstab to automatically have it mounted at boot time just adding this line:

cofs0      /mnt            cofs    defaults          0 0


coLinux is not quite ready for running production services but can make the live of many Windows users that wish to run or try Linux very fast a breeze. If you want to have some LAMP application running or you want to do some C/Perl/whatever development it seems to be a good choice. If you have time you can also create a full running desktop system installing all the required packages and configuring a Windows X server or VNC to access it.

coLinux: running Linux from within Windows, 4.3 out of 5 based on 3 ratings

Potrebbe interessarti anche:

Iscriviti alla newsletter

  • HowTo e Tutorial su Linux e Ubuntu
  • Wordpress, Perl & Webmin
  • VoIP, Asterisk, SIP

Cosa stai aspettando?


  1. lloyd braun says

    Any reason why this would be better than running Windows from inside Linux?

    • says

      Very good point but the audience i’m talking to with this article is made of hardcore windows users that does want to use Linux. I know a few university students what wish to use Linux for programming but they don’t wish to stop playing their favourites PC games.

  2. Anonymous says

    They hurt linux with this sort of App.

    If users want Linux.  Then they should use Linux.  Running Linux under windows in any form negates all the good that Linux brings.  It’s pointless and only fosters further laziness in a breed of people too lazy to move from the beast already.

    • says

       Anonymous i agree with you but not all the people are able to install Linux or use it after the initial installation. Anything that allow a smooth transition of people that will never migrate to Linux in the short time is a good things. Example: my cousin used coLinux to do C programming at the university because it was too complicated for him to only use Linux on his computer in the beginning; after a few months he decided to finally migrate after he got confident with the new system. Changing the habits of people is not easy :)

    • Cmsbloke says

      Yes that’s a good point, but what about people that want to use Linux and are already au fait with distros like debian and rhl but absolutely NEED to use some windows software because of specific workflow requirements? In that case colinux could be just the business. Not everything is good via WINE.

  3. Electronic_Chris says

    Well you can not run Windows inside Linux.  You can run Windows “programs” inside Linux using Wine. Which is more useful for Linux users.  This coLinux sounds like it would be for users with basic Linux skills that are more comfortable in Windows and need to have full Windows functionality. There’s two other projects andLinux and Cygwin that are very similar.  I strongly suggest you look into Cygwin if you find yourself more of a Windows user then Linux.

    • says

      I agree with you Chris on the “sounds like” part :) I should do some real performance testing but coLinux looks like more faster then my cygwin installation. I’m used to mirror all website with Wget/Ftp then i use Mercurial (hg) to check for difference then reupload changes with sitecopy; that’s a memory and I/O consuming operation and i’ve been never satisfied by Cygwin performance with this task (for work sometimes i don’t have my linux box with me); i was amazed to see that coLinux “looks” faster then Cygwin… but maybe i better gather some proof/evidence of this with real numbers.

      For “andLinux” i should try it at it looks like an Ubuntu pre-built image based on coLinux