.

Home

Archive

Magazine Corner

About

Install any Linux distro directly from hard disk without burning any DVD

Friday, August 31, 2007 by Kaushik

Linux
,
Tutorials n Tips

After you download any Linux distro from the internet, you have to burn it to a DVD, CD or a number of CDs to install it. That CD or DVD is generally used only once after which it lies unused , and worse, almost every Linux distro comes up with a new release every 6 months. So if you are in the habit of upgrading to every new version, you must have dozens of CDs lying at the bottom of your drawer. What a wastage of CDs! But with a little trick you can install any Linux directly from the hard disk without burning a single CD or DVD. The prerequisite of this trick is to have an operating system already installed on your computer. This is obvious because unless you are able to boot into your machine, you can't install anything; and we are not going to boot from the Linux disk because we aren't burning any. Here I'm going to focus on Microsoft Windows as the pre installed operating system.

Almost all Linux installers uses two files to boot the computer: a Linux kernel, and an initial root file system containing a minimal set of directories that is mounted prior to when the real root file system is available. This initial root file system is also called Ram disk (initrd). We will use these two files to boot our PC. Now lets get to the actual procedure.

1. The first thing you will have to do is copy the ISO file(s) of the Linux to your hard disk (ofcourse, you already have it). Make sure that the partition is FAT32 unless the distro you are installing has native NTFS read/write support. Some distros require you to copy the ISO file(s) to the root of the partition. If you keep it inside a folder, the setup might not be able to detect it.

2. Use Winrar to open the ISO file (you need not need to extract it). Now you will have to extract the two files I talked about earlier. The files are usually found inside a directory called isolinux. Different distros might place the files in different location; you just have to search for it, but it isn't hard to locate. These two files are also named differently in different distros. The files that you will need to search and extract are: (the kernel file is shown in green and the Ram disk is shown in red)

Fedora: vmlinuz and initrd.img

Suse: linux and initrd

Mandriva: vmlinuz and all.rdz

Ubuntu: vmlinuz and initrd.gz

Gentoo: gentoo and gentoo.igz

Knoppix: vmlinuz and initrd.img

Slackware: bzImage and initrd.img

Debian: vmlinuz and initrd.gz

3. After you have extracted the two files, copy them to c:\boot (you will need to create the folder "boot")

4. Now download the file called grub4dos from here. (Note: the new versions of grub4dos i.e. 0.4.2 and 0.4.3 does not work. So download the earlier version 0.4.1. Direct download link)  Extract the folder "boot" and the file "grldr" from the downloaded zip file. Inside the folder "boot" is another folder called "grub"; copy the folder "grub" to c:\boot. Copy the file "grldr" to c:\

5. Open c:\boot\grub\menu.lst and add these following lines. (Notice that hd0 refers to the first hard drive. If you have more than one hard drive, they will be named hd1, hd2 etc. Replace hd0 with the proper hard drive number incase you have windows installed on another drive.) Replace Linux_kernel and Ram_disk with the appropriate file names below. (the ones you copied to c:\boot)

title Install Linux
kernel (hd0,0)/boot/Linux_kernel
initrd (hd0,0)/boot/Ram_disk

6. Now you have to add grub to your c:\boot.ini file. You can open boot.ini by clicking on Start>Run and typing c:\boot.ini. If Windows does not allow the file to be modified, then go to Control Panel>System and click on the Advanced tab. Now under Startup and Recovery click Settings and then under System Startup click Edit. Open boot.ini and add this line in the end.

C:\grldr=”Start GRUB”

7. You are now ready to install Linux. Restart your PC and from the boot screen select "Start GRUB". This will load GRUB. From the grub screen select "Install Linux". During the setup you will be asked the source of installation. Choose hard disk and then select the hard drive partition where you copied the ISO files. Sometimes you might have to type the whole path of the partition and the exact name of the ISO. So write it down before you begin.

I have personally tested this with Fedora, Suse and Mandriva and it works without problem. I have no doubt it will work for others too.

Update: dougfractal adds that this is possible from Linux too. The method as he describes is:

From the terminal enter these commands

sudo mkdir /distro
sudo chmod `whoami`:`whoami`
cp MYLINUX.iso /distro/distro.iso

Now extract Linux_kernel & Ram_disk to /distro#

Open  /boot/grub/menu.lst

#ADD NEW ENTRY#
title Install Linux
root (hdX,X)
kernel /distro/Linux_kernel
initrd /distro/Ram_disk

Reboot and select "Install Linux" from grub.

Liked the article? Then Subscribe in an RSS reader or get updates via Email or follow on Twitter.
And don't forget to visit the Archive section.

Looking for something else? Then search

Download or subscribe to hundreds of industry magazines, whitepapers and podcasts for absolutely FREE at Instant Fundas' Magazine Corner. Browse through our selection of more than 600 offers across 33 categories and Subscribe, all at no cost!

109
comments
Comment Feeds

Anonymous
said...

Thank you, that was interesting and useful :-)

September 1, 2007 4:08 PM

DB
said...

Surely this only applies for a Linux-Windows Dual Boot system? Even then using a rewriteable disc is just as simple?

September 1, 2007 10:12 PM

Karl L. Gechlik
said...

Great tip. I am going to give this a shot in a few minutes. Thanks from your new friends @ AskTheAdmin.com

September 1, 2007 11:02 PM

Bo
said...

Or, if you're like the avarage computer user you have some old useless box sitting in the closet gathering dust. Install Ubuntu on it, load up tftp, rarpd, dhcpd, vsftpd and and start netbooting your installs.

September 1, 2007 11:26 PM

Anonymous
said...

From my experience this usually doesn't work with the now popular Live-CD distrobutions (PCLinuxOS, Ubuntu Desktop). I use a similar method for my Centos installs... and taking CD swapping out of the equation and adding the speed of hard drive data transfer... this method is pretty darn fast.

September 1, 2007 11:29 PM

Miller
said...

Personally, I favor the CD writing. While I condone the senseless wasting of CD's, CD-RW's I have no problem with. Also, I would think the delay inherent in simultaneously reading and writing to a drive, especially if it isn't very high-speed (7200 rpm or less), would make the process a little more time consuming.

However, this method is fantastic for a system with two or more hard drives in it. The data transmission speeds would be much better than even CD to HDD. I definately would try this out.

September 1, 2007 11:29 PM

Anonymous
said...

Miller, it's condemn, not condone. Even then, condoning the senseless waste of CD-RWs is silly. And it's spelled 'definitely'. Really helps with credibility.

September 1, 2007 11:45 PM

Paul
said...

What if you have a Window's Vista partition? Window's Vista creates a boot dir under the root of C:\. I am curious if this Linux install method would have technical difficulties or conflicts with an already occurring Vista boot dir.

September 1, 2007 11:48 PM

Anonymous
said...

Get the minimal CD of your distribution and put it on a usb disk. Boot from there and do a netinstall.

September 1, 2007 11:49 PM

Eugeniu
said...

"almost every Linux distro comes up with a new release every 6 months. So if you are in the habit of upgrading to every new version, you must have dozens of CDs lying at the bottom of your drawer"

Actually, I think most people just upgrade from online repositories.

September 1, 2007 11:59 PM

Anonymous
said...

Gentoo, and some other distros rarely put out new releases. Plus, when installing gentoo, you just create a new partition and chroot.

Yum (and I'd assume apt-get) let you set the root path to install to. Just about every distro uses net-install these days too.

So, if you have room for another root partition, you can usually find a way to install a distribution without even downloading the CD.

September 2, 2007 12:11 AM

phatsphere
said...

i always press "upgrade" in my ubuntu box when a new release is in the wild. this requires nothing except some bandwith and time ...
but anyway, nice hack ;)

September 2, 2007 1:01 AM

Explodingpickle.org
said...

"Gentoo, and some other distros rarely put out new releases. Plus, when installing gentoo, you just create a new partition and chroot."

Yeah, and Gentoo takes 10 hours to install because it compiles everything from source.

September 2, 2007 1:12 AM

russoz
said...

Nice tip!!!

Very ingenious :-) I never heard of grub4ds before, but that makes life way simpler! :-)

Thanks,
Alexei

September 2, 2007 2:45 AM

...
said...

Would you provide the info for Damn Small Linux and FreeNAS? What name is kernel file and the Ram disk this two distro used?

Is it possible have a similar common way to install them from linux?

September 2, 2007 2:50 AM

Anonymous
said...

UNetbootin at http://lubi.sourceforge.net/unetbootin.html does the job for Ubuntu and Debian automatically, for Windows and Linux

September 2, 2007 3:06 AM

Anonymous
said...

Problem with step #4
Now download the file called grub4dos from here. Extract the folder "boot" and the file "grldr"
from the downloaded zip file.

There is no folder called "boot" in the downloaded zip file.

September 2, 2007 3:26 AM

Anonymous
said...

grub_for_dos-0.4.1 which includes the boot folder can be downloaded at:
http://grub4dos.freespaces.com/

September 2, 2007 4:03 AM

dougfractal
said...

This is great.
I thought I'd try this out from linux.

sudo mkdir /distro
sudo chmod `whoami`:`whoami`
cp MYLINUX.iso /distro/distro.iso
#EXTRACT Linux_kernel & Ram_disk TO /distro#

sudo nano /boot/grub/menu.lst

#ADD NEW ENTRY#
title Install Linux
root (hdX,X)
kernel /distro/Linux_kernel
initrd /distro/Ram_disk

Reboot and select "Install Linux" from grub.

September 2, 2007 4:23 AM

doug
said...

sudo chmod `whoami`:`whoami`
whoops!

sudo chown `whoami`:`whoami`

September 2, 2007 4:34 AM

home owner
said...

Great post and thanks for writing!

September 2, 2007 4:48 AM

mtnbluet
said...

Please give directions for Xandros.

Thanks,
Cathy S

September 2, 2007 5:31 AM

wwbein
said...

This has another appliction: There are a number of sub-notebooks out there
which do not have a cd drive, for example the Acer Travelmate C 100, the IBM Thinkpad X series, or the Toschiba Protege. Some of these do not boot some distributions from an external
CD drive. For example, the Acer Travelmate C 100 will not boot off an exteral CD for Fedora. So then the only option used to be a network install. This procesdure is much easier. Thank you!

September 2, 2007 9:26 AM

Kaushik
said...

@Paul: I don't have Windows Vista installed right now on my system so I have no way of telling. But I think the same can be achieved by adding the entries through BCDEdit.

@... (couldn't find a better name, did ya? ;))

I will see for DamnSmall Linux and let you know. And yup its possible from Linux too. See dougfractal's comment.

@dougfractal:

Thanks for that!

@mtnbluet: I will let you know. I have to search for my Xandros CD. :)

September 2, 2007 12:30 PM

Shiben Bhattacharjee
said...

Hey this is nice

September 2, 2007 12:49 PM

ChevronX
said...

Wubi is a GUI system for installing ubuntu based systems in windows.

September 2, 2007 2:10 PM

Dietrich
said...

Gentoo doesn't really make releases as we know them from Debian, Fedora, etc. The releases only consist of an installation CD, Live CD and stage3 tarballs which you need to install Gentoo. You install a Gentoo installation from scratch only once, after that you never need to download a "release" again (and thus certainly do not need to "spend 10 hours" every time). When connected to the Internet and using Portage you can keep your system up-to-date many years after you made the initial install. Every aspect of the system is reflected in a package, even the base stuff (baselayout package).

September 2, 2007 4:30 PM

Anonymous
said...

simply use a rewritable media?

September 2, 2007 5:26 PM

David
said...

For Ubuntu Feisty, you need the following vmlinuz and initrd.gz for installing from iso:

http://archive.ubuntu.com/ubuntu/dists/feisty/main/installer-i386/current/images/hd-media/

September 2, 2007 8:12 PM

Ed Frome
said...

If you burn a cdrom for every distro you download, and install from disk only once, that burn is not wasted if you pass the disk on to a friend or stranger.

September 3, 2007 6:39 AM

Kaushik
said...

@mtnbluet: Sorry, I couldn't find the files in Xandros. The files on the CD are a bit differnt, not what we typically find on a Linux CD. Though there is one vmlinux but its empty and so is initrd. I presume those get created when the installation process starts. I will give you 3 alternatives.

1. Find someone who already have Xandros running and copy vmlinuz and initrd from /boot
2. Use a USB drive to boot from it.
3. Xandros allows you to boot from a floppy too. You can use that.

September 3, 2007 11:56 AM

Anonymous
said...

for ubuntu, installing from hard drive using grub usually need to download a special kernel file and initrd.img from their website, do you think using kernel file and initrd.img picked out from iso image as your description in this article also work?

September 3, 2007 5:27 PM

Kaushik
said...

Its not any special kernel file but the same one present on the disc. It will work.

September 3, 2007 8:51 PM

Anonymous
said...

For Ubuntu, you cannot use initrd.gz file extracted from iso file for hard drive installation, that's why Ubuntu provide a special initrd.gz for user's download.

The kernel file is same.

September 4, 2007 8:10 AM

Anonymous
said...

JFYI, installign Debian from Windows is easy via goodbye-microsoft.com

September 6, 2007 9:10 PM

Антон Баранов
said...

Hello. I do not have your permission, but issued a translation of your post on the Russian language at my blog. Translation is available here: http://demonjaka.blogspot.com/2007/09/blog-post_07.html

September 8, 2007 8:20 AM

Kaushik
said...

@Антон Баранов:

No problem. :)

September 8, 2007 12:35 PM

Anonymous
said...

There used to be a utility 'loadlin' which came with redhat in old times. maybe it can be used instread of grub.

September 10, 2007 4:38 PM

Gangsar
said...

I've tried this to install Linux Mint from harddisk.
But I got an error message like this:
Error 17: File not found
Booting 'find /boot/grub/menu.lst'
Error 20: Select cylinder exceeds maximum supported by BIOS
Something wrong?

September 14, 2007 7:16 AM

Kaushik
said...

Are you sure the file /boot/grub/menu.lst is actually there? Have you placed grldr on c:\?

September 14, 2007 9:08 PM

Gangsar
said...

I have copied grldr on c:\
and my menu.lst is on c:\boot\grub\ folder
Or maybe it just not work on Linux Mint?

September 15, 2007 7:31 AM

Anonymous
said...

Brilliant! This is exactly what I was looking for. Thanks

September 20, 2007 4:17 PM

Oscar
said...

This article has even higher potential, not only saves DVDs for Linux updates, but also allows to install distros from scratch in machines with no DVD drive AND BOOT THEM FROM XP. I did as the article reads, installed Fedora in a HD not used by XP, selecting "No boot" during installation. Then deleted unwanted titles in menu.lst and added a new "Title Boot Fedora" with same lines described in the article BUT POINTING TO THE NEW vmlinuz and initrd.img that Fedora created in the installation. Now I can boot into XP (default) or GRUB, and then choose either to boot Fedora or install it. Note that GrubForDos version 0.4.1 works as described, but version 0.4.2 does not, has different files. Note that the vmlinuz and initrd created by Fedora in the boot area have long names including several dots that may need renaming to work. You may need to install a driver in XP that allows you read Ext2fs partitions and rename files. It can be found in http://www.fs-driver.org/

September 23, 2007 7:22 AM

Kaushik
said...

@Oscar:

Thanks for the valuable inputs. Indeed, this method has a much higher potential.

Does Grub4Dos ver 0.4.2 not work? I didn't know that. Actually, I tried this stuff almost a year ago. Probably the version I used then was 0.4.1. I have been using that ever since.

September 23, 2007 12:20 PM

DJ Gentoo
said...

I'm amazed that I missed this. Thanks for pointing out the obvious (in a good way) for me, this is just what I've been looking for.
On a related note: Are you sure it works on openSUSE? It keeps track of package repositories on the CDs using their labels, and... Well, there's always the network install, but what if you want to install it right off the image? It shouldn't work, but if you say you've tested it, I'll take your word for it.

September 28, 2007 9:38 PM

WebGk.com
said...

I have always used "upgrade" from my ubuntu box. Eats up some bandwith and my valuable time.
This is a great alternate you have giver here. Thanks for sharing with all of us.

September 30, 2007 6:30 PM

Dnmt
said...

how i should write path to file in the grub?
my suse cdimage (su.iso) is on C:\ disk.
when i'm selecting hdd as a source for installation, his asking me for path to the file and when I write C:\su.iso or su.iso,su,C:\su..., -grub cant find em. =\

October 28, 2007 8:50 PM

dnmt
said...

i have tried to put iso file on fat32 partition, tried to extract whole iso in folder and that did not helped.

October 28, 2007 9:23 PM

Kaushik
said...

@dnmt:

Linux does not understand drive c,d etc. Your C drive is most likely to be called sda1. So the path name will be

/sda1/su.iso

October 28, 2007 10:06 PM

Dins'
said...

Hi, Its a great Guide... Thanks.

I've Successfully did it a few days ago, it worked good with the Win Xp, but on vista it is giving error as there is no boot.ini to add the entry "C:\grldr="Start Linux", and can't create "boot" folder, as it is already there but with no access to it, though I copied the required files to the "boot" folder from Command Line,
and also I Tried to add the entry "C:\grldr="Start Linux", with the bcdedit.exe but avail no result ... it says ".../Windows/system32/hal.dll missing"

If you have also faced this and got the solution please Let me know the Solution...

October 29, 2007 4:13 AM

Anonymous
said...

how to do it with free bsd? bsd?

October 29, 2007 7:52 PM

飞扬跋扈
said...

I do not agree with! You can not do this with the Gentoo distro!

October 31, 2007 3:51 PM

peter
said...

hi,
the "/boot" folder is no longer available from grub4dos 0.4.2 and up.
update of this guide would be appreciated ... I will use the old G4D, probably works fine, thanks!

November 7, 2007 11:21 PM

Kaushik
said...

Guide updated with working links.

Thanks.

November 8, 2007 11:01 AM

marshieparshie
said...

to do this with debian images, do not use the kernel and ram disk files from the ISO. these support installs from cds or the internet only. the files you need can be found on debian mirrors in:
/dists/*release*/main/installer-*architecture*/*version*/..
..images/hd-media/gtk/

the files i needed were located in:
http://debian.osuosl.org/debian/dists/Debian4.0r1/main/..
..installer-i386/current/images/hd-media/gtk/
for the latest version of etch for i386

November 9, 2007 7:05 PM

Kaushik
said...

@marshieparshie:

Thanks for that. I didn't have time and the iso files of all the distros to test it.

November 9, 2007 8:29 PM

nikoz
said...

that's how I did with sodilinux (based on ubuntu 7.04)

create a fat16 partition (hd0,1) /dev/hda1
mkdir /media/fat16
mount /dev/hda1 /media/fat16
mkdir /cdrom
mount ubuntu.iso /cdrom
cp -av /cdrom/* /media/fat16

modify /boot/grub/menu.lst adding:

################################################
title setup ubuntu
root (hd0,1) #second partition
kernel (hd0,1)/casper/vmlinuz file=/cdrom/preseed/ubuntu.seed boot=casper
initrd (hd0,1)/casper/initrd.g
######################################

umount /cdrom
umount /media/fat16

reboot

at boot select "setup ubuntu"

NiKoZ

November 16, 2007 9:14 PM

Rascalico
said...

I've got to the stage just after i choose Install Linux and it says stuff about each of these
kernel (hd0,0)/boot/vmlinuz
initrd (hd0,0)/boot/initrd.img
in a few lines but then just freezes with the cursor flashing - is this part suppost to take a while or has something gone wrong? Any ideas?

November 17, 2007 6:55 PM

Rascalico
said...

... more info:

Here's what i'm getting after I choose 'Install Linux':

kernel (hd0,0)/boot/vmlinuz
[Linux-bzImage, setup=0x1e00, size=0x1e3354]
initrd (hd0,0)/boot/initrd.img
[Linux-initrd@0x7976000, 0x5695c0 bytes]

(is this usual)

forgive me im reading my atrocious writing, some 0s may be os, 1s may be ls or Is and es may be cs but the rest it what im getting defo.

this remains on screen but all i get is a cursor flashing underneath and nothing else happens! help, please i've been trying to get this installed for ages!!

Iam intending to use Fedora7-i386 DVD iso which i have placed both in the root of on my windows C drive and the F drive which i want to install linux onto.

I have just converted both these from NTFS to FAT32 using partion magic.

But I haven't even been asked where the source file is and where i want to instll linux, it's just frozen at the point I mentioned.

I thought i had done everything correctly - i extracted both those files into c:\boot, extracted that other one into c:, extracted the grub folder from within the boot dir in the zip into the boot dir in c, edited the menu.lst, then edited the boot.ini.

Any thoughts?

November 17, 2007 9:02 PM

Kaushik
said...

@Rascalico:

The first thing is: you can't install linux on your F drive. Linux can't be installed on FAT32 or NTFS. It has it's own file system. To install linux you need to have free space on your hard disk - space free of any partition. During installation process you should "tell" the setup program to use the free space. If you don't have much experience about installing linux, you could try installing it inside a virtual machine. Search on Google.

Regarding to your actual problem, I don't remember exactly whether it shows such information. Usually, as soon as you choose "Install Linux", it displays some mesage like "kernel found" and then "uncompressing kernel image" etc. After a few more messages (different files loading etc), the graphical interface takes over.

Check whether the files vmlinuz and initrd.img are inside c:\boot.

November 17, 2007 9:40 PM

Rascalico
said...

^ (thanks i've merged my partitions now)

Still no luck though, the files are defo. in c:\boot, i tried a few different things but same thing is happening :-(

November 18, 2007 12:07 AM

laks
said...

If you want to do this for a system running Windows Me. Here is what worked for me.

+ boot Windows in safe mode
+ C>: bootlace 0x80

follow the steps mentioned earlier - of copying Grub and menu.lst to C: . You will be on your way to booting from the distro on the hard disk.

the following tutorial for grub is very useful.
http://grub4dos.sourceforge.net/wiki/index.php/Grub4dos_tutorial

In my case - Ubuntu7.10 could not recognize my hard disk - (my systems is a Dell Inspiron 8100), so I had to switch to Fedora.

December 28, 2007 6:33 PM

Dulwithe
said...

Thanks for your tutorial! It was AWESOME and did exactly what I needed.

Now I have PCLinuxOS installed dual-boot with WinXP on my Toshiba R100. Suspend to disk works with PCLOS, and the recent updates to PCLOS's printer databases have allowed me to enable my Canon Pixus i560, i4200, and network Brother MFC-7820N.

AWESOME!!! Thanks again.

February 5, 2008 11:37 PM

Dulwithe
said...

PS - For anyone who is interested, I didn't reformat my drive with a FAT32 partition for the ISO file before installing. I un-archived the .iso files and saved them on a USB card reader (1Gb SD card).

So, I suppose I could easily use this same technique for install to a USB memory stick.

AWESOME!!!

February 5, 2008 11:40 PM

Kaushik
said...

@Dulwithe:

I'm happy to learn that my tutorial worked for you. And yes, most new linux distros has inbuilt NTFS support and can be booted from the USB drive too.

February 6, 2008 8:44 PM

need help.......amin
said...

does the c:/ refer ot your pendrive or hardrive and i hav a problem for the hd0 number changing..i hav 2 hardrive and my windows is at hd 2 and i want to install ubuntu on hardrive 1...can somebody do it for me?? thanks :)

February 10, 2008 10:35 AM

need help.......amin
said...

and what does the distro refer to?

title Install Linux
root (hdX,X)
kernel /distro/Linux_kernel
initrd /distro/Ram_disk

February 10, 2008 10:59 AM

Kaushik
said...

@amin:

C:\ refers to the c drive of your hard disk.

Since you have Windows installed on your second HDD, you will have to copy kernel, ramdisk, grub etc files to the second HDD.

(hd0,0) will change to (hd1,0) assuming the 2nd HDD is assigned 2nd in the BIOS configuration.

Copy the iso files to whichever HDD you want. Just rememeber to mention the correct path when it asks you to point to the iso file. HDD1 will be /dev/hda and HDD2 will be /dev/hdb

What is distro?
http://en.wikipedia.org/wiki/Distro

February 10, 2008 5:39 PM

cristo
said...

I own an obsolete ThinkPad 560x laptop without CD or FDD. I find your method perfect for giving a new life to my old IBM. But I realized I have no boot.ini file on my system (Win98SE). How to proceede then?

February 14, 2008 5:58 PM

Kaushik
said...

@cristo:

This won't work with Win98. Win98 doesn't have boot.ini file or any boot manager. Since both the CD drive and the FDD are broken, the only option you have got is to install Windows XP or Linux from a USB drive, provided the BIOS supports booting from USB. Another way is to use network install. If you can network your laptop to a PC, you can install any OS into your laptop.

February 14, 2008 6:57 PM

Anonymous
said...

Could I boot grub from my USB device and how ???

Problem: I don't see list of options when I'm starting GRUB which is allocated on ntfs C: partition.

February 17, 2008 6:50 PM

Kaushik
said...

^^ We aren't using Grub to boot the PC. The PC is booted using Windows bootloader. After the windows is booted the control is transfered to grub to load the Linux installer. So this process will work only if you have some mechanism to boot your PC - either through Windows or Linux or even an USB drive provided that you have the proper booting files on the USB drive.

February 19, 2008 11:41 AM

Anonymous
said...

You are right. I use Windows XP SP2.
But I was interesting how could I load grub from USB. And why data from menu.lst are not displayed when I load grub from ntfs ?

February 19, 2008 11:59 PM

Kaushik
said...

You can load grub from USB. Copy all the grub files on to the USB stick and add the line to the boot.ini file.

If you are unable to load GRUB from ntfs partition then maybe the distro you are trying doesn't have NTFS support. In that case you have use Fat32.

February 20, 2008 11:33 AM

Anonymous
said...

What shoud I write in C:\boot.ini in case of USB ?
I can't convert my NTFS file system to FAT32.

February 23, 2008 12:02 AM

Kaushik
said...

Find out what letter Windows assign to the USB drive by plugging it to your PC. Then replace "C" in C:\grldr=”Start GRUB” with the drive letter. You should have GRUB on the USB drive.

Since the linux you are trying can't recognize ntfs you will need to have atleast one fat32 partition where you should place the iso file. There is no way to convert ntfs to fat32 without reformatting.

February 23, 2008 12:55 PM

Anonymous
said...

Had you tried it ?
I've tried change letter C: and it didn't work. Grub even didn't load.
Probably I should write smth like "sd(0)..." or "hd(1).." (because it is SATA HDD, connected via USB). I don't know.

February 23, 2008 6:11 PM

Anonymous
said...

Kaushik,
Have you tried this:

http://www.google.com/search?
sourceid=navclient&ie=UTF-8&rls=SKPB,SKPB:2008-06,SKPB:en&q=Confert+NTFS+to+FAT32

???
:)))

February 23, 2008 6:17 PM

Kaushik
said...

Windows does not allow converting ntfs to fat32 natively. But of course, there are tools like Partition Magic that can do that and even resizing and merging of partitions without losing data. But there is a risk factor involved and if the process fails all your data will be lost. Even Partition Magic displays this disclaimer. I wouldn't advise you to do that because there is a high chance of screwing up your data.

For your main problem, does your BIOS support booting from USB? First find that out. And names such hda, hd0 are for linux. the grub should be loaded by boot.ini file which does not recognise such names. You have to give the usual windows letter names.

February 24, 2008 12:20 PM

Anonymous
said...

Thanks, I've tried it. But it doesn't work :(((.
My BIOS supports booting from USB.
I couldn't do something with my main HDD because it is on my workplace. I don't want to damage my Windows XP system too. I'll try smth else.

February 25, 2008 4:33 PM

cracks.host.sk
said...

If you burn a cdrom for every distro you download, and install from disk only once, that burn is not wasted if you pass the disk on to a friend or stranger.

Regards,
http://cracks.host.sk

March 8, 2008 10:42 PM

Anonymous
said...

I followed your instructions exactly.. But I still get a error said: unknown command...

the only difference is the version of grub4dos.. I am using grub4dos v0.4.3 right now.. I just rename the grub4dos folder to grub because i can't find the grub folder which you mentioned above..

so, about this new version, what should i do?

I am really looking forward your help..

March 31, 2008 3:26 PM

Kaushik
said...

grub4dos v0.4.3 does not work. There is nothing you can do. Use version 0.4.1

March 31, 2008 4:36 PM

Swathy
said...

how to deal with the command line interface which starts up when one chooses start GRUB as the choice for installing LINUX? What commands are used for installation?

April 19, 2008 11:07 PM

Anonymous
said...

What happens if you want to partition the whole drive?

May 7, 2008 9:05 AM

Myself
said...

I tried using this to install Minime PCLinuxOS 2008. I got to the windows boot part, but when I go to GRUB, it says "missing MBR-helper."

June 3, 2008 8:33 AM

VijayR
said...

URGENT HELP REQ.
STUCK IN INSTALLATION.

I did all steps and the grub started. I selected the "Install Linux".

then the ubuntu installer started.
I finished the region and keyboard selection.

next, it asks for the ubuntu image from my cd rom.
The option there only has install from cd rom (I think so).
and since my ubuntu iso is not in cdrom, I have to abort the installation.

It gave an option to run the ash shell. but I did not know what to do from there.

please help.

June 16, 2008 6:39 AM

Knight
said...

I also got the same problem, i ran into the ash shell. nothing to do from there :/

June 21, 2008 8:45 AM

Malachias
said...

My favorite way has been to make an additional 750 megabyte partition on the hard-drive, and format it as ext3 - have it in /mnt/fakecd. Then do the following:

$ mkdir /tmp/install
$ sudo mount -o loop /path/to/cd/iso /tmp/install
$ sudo cp * /tmp/install /mnt/fakecd
$ sudo cp .* /tmp/install /mnt/fakecd

Now edit your /boot/grub/menu.lst to add an entry:
title Install Linux
root (hd0,1)
kernel /casper/vmlinuz
initrd /casper/initrd.gz

Note: this is for an *Ubuntu live-cd. For other distributions, your grub entry may be different, depending on where vmlinuz and initrd.gz are located. Also note that "root" will depend on what your fakecd partition is. Mine's /dev/sda2, hence (hd0,1).

Now when you reboot, select Install Linux and it'll be exactly like running it off the CD, except a fair bit faster since you're reading from the HD.

July 10, 2008 9:38 PM

N
said...

Hi,

I am trying to do this from within PCLOS to install OpenSUSE. It crashes:

:Failed to detect CD drive !

I have grub's menu.lst editted correctly. Tried it with the iso fully extracted, as well as only linux and initrd extracted + full iso file copied to my dedicated 1.3 Gb drive for HDD version of LiveCD.

The only distro that successfully works so far is PCLOS.

Any help? You can mail me direct @

dulwithe [at] myrealbox [dot] com

- Dulwithe

July 30, 2008 8:24 PM

Kaushik
said...

@Dulwithe: Why does the installation try to detect the CD drive? Are you sure you haven't mixed up the paths of the CD drive and the hard drive?

You should not extract the ISO file but copy it intact to the hard drive. And are you trying to install linux from a live CD? I'm not sure whether that is possible.

July 31, 2008 10:52 AM

N
said...

Thanks for your response, Kaushik.

I don't know why certain distros crash with the same type of hdd "LiveCD" method. I've tried extracting just the kernel and RAM disk files, and put them with the ISO file on the "LiveCD" partition.

I have had mixed results. I got Mepis to work yesterday. Some distros don't work with this method, others do. I have NO idea why.

My guess with the SUSE distro is that its kernel or RAM disk is directed to look exactly for a cd drive and boot from there. If no cd drive is found, "reboot in 120 sec..." Apparently suse 10 worked this way, but suse 11 doesn't (but I don't want to try and install a year-old distro).

. D.

July 31, 2008 8:07 PM

Kaushik
said...

Apparently, Live CDs are different from normal installation CDs. Live CDs are programmed to look for the Cd drive and load from it. I suggest you get a normal cd and try that, or you can continue with your experiments. :)

August 1, 2008 10:32 AM

abhi
said...

hi,
I got preinstalled Vista on my laptop. I removed all the partitions by installing
Ubuntu 8.04 making some partitions and keeping other space free for XP. But when I am installing XP from the bootable CD it says hard disk not found. Please help me how to get rid of this problem.

abhi

August 11, 2008 5:26 PM

Kaushik
said...

@abhi: Installing Windows after Linux is always going to create problems. Anyway, try this:

If Winxp can't detect your hard drive, then you will have to boot from a Win98 CD. If you don't have the Win98 disk then download the boot disk image from here and burn it to a CD.

Now boot from the disk, and at the commad prompt issue this command:

fdisk /mbr

This will rewrite the MBR and you can now load windows. After you have finished installing WinXP, install ubuntu's bootloader to dual boot WinXP and Ubuntu.

August 11, 2008 9:29 PM

Vasu
said...

Hi Malachias,
Very good to hear a nice tip from you, and especially booting Ubuntu live cd from hard disk. I tried the way you mentioned above but, it didn’t work. At the copy commands,"$ sudo cp * /tmp/install /mnt/fakecd
$ sudo cp .* /tmp/install /mnt/fakecd
" I got “directories ignored” error message. I thought that may be 'coz of root security and I manually copied the total iso files in to 750MB new partion. Then I rebooted my system and got into ubuntu installation and I found the same error "mount CD failed. no device exist". Then I opted for command line. I found "cdrom" folder in '/' directory, and I thought it is place where cd drive is mounted and I mounted my 750MB drive to '/cdrom' and tried to install. Now, our 750MB drive works as a CD drive. Happy to get what we desire, but when I format swap partion it shows "device is use" error message. And here i got struck. And I also found that 750MB drive must be ext3/ext2/cdfs file system type. 'coz at the time of installation kernel cant mount a FAT file system.

Any help is appreciated.

August 25, 2008 9:40 AM

Porn Girlz
said...

That's what I'm looking for. Thanks for saving my life : )

August 31, 2008 5:11 PM

Malachias
said...

Vasu,

I'm very sorry, that was a typo on my part. Instead of

$ sudo cp * /tmp/install /mnt/fakecd
$ sudo cp .* /tmp/install /mnt/fakecd

I meant

$ sudo cp -R /tmp/install/* /mnt/fakecd
$ sudo cp -R /tmp/install/.* /mnt/fakecd

Basically the idea is to get all the files into the fakecd partition.

Hope that helps!

-Mala

September 4, 2008 7:40 AM

malachias
said...

Erk, my bad again - don't do the .* one as that'll catch everything in ../ as well =P Replace the second line with
$ sudo cp -R /tmp/install/.disk /mnt/fakecd

Sorry again >_<

--mala

September 4, 2008 10:12 AM

mldarshana
said...

Is it possible to for me to install Linux on Extended partition ?

If so my other question is ......

I am going to install Linux Mint on Extended partition.

What is the correct entry for Step 5, that is when i am going to edit the menu.LST ?

PS: I have one hard drive and i have installed Win XP in primary partition and i have 4 logical drives in extended partition.

Thanks in Advance

September 14, 2008 2:26 PM

Kaushik
said...

@mldarshana: You can install Linux in the extended partition. No problem with that. I have always used the extended partition for linux.

The step5 will be the same. No change, since you have only 1 HDD. So it will look something like this:

title Install Linux
kernel (hd0,0)/boot/vmlinuz
initrd (hd0,0)/boot/initrd.img

Make sure you use the correct file names.

September 15, 2008 4:06 PM

blossa
said...

I think I have followed your instructions... I have two HDs:
*One that has one big FAT32 partition(dev/hda1). On this one I have the iso-file (called su.iso), boot directory with grub and the original windows installation
*The other hd (dev/hdc1) is empty and here is where I plan to install Linux (gentoo).

When I boot and have selected to install linux i get to a point where I get this message:
!!Could not mount specified ROOT, try again.
!!Could not find the root block device in .

Any suggestions about what I have missed?

Teh iso that I am using is the "Gentoo 2008.0 Minimal CD/InstallCD" for x86 found at http://www.gentoo.org/main/en/where.xml

Thanks in advance! / Anders

September 16, 2008 12:20 AM

Anonymous
said...

I have copied disk image image.nrg to partion 'H' having fat32 file system and and my 'C' drive is having ntfs file system which is used by windows operating system.
I extracted the file vmlinuz & initrd to c:\boot
also the grub. Also added the lines with exact replacement to menu.lst under the grub.
I restarted the PC and selected "Install Grub" option, it shows...
Booting 'Install Linux'
kernel (hd0,0)/boot/vmlinuz
error 14: Invalid or unsupported executable format

how to get out of this problem.....any suggestions...

September 28, 2008 9:22 PM

Kaushik
said...

You can't use .nrg format. You need ISO file. Convert it to ISO.

September 28, 2008 9:44 PM

Anonymous
said...

thanks to reply kaushik....
as i was suspecting the same
but can it be converted to iso format......

September 28, 2008 9:57 PM

Anonymous
said...

how to convert nrg to iso format ?????

thanks in advance....

September 28, 2008 9:58 PM

Anonymous
said...

I have converted .nrg format image to .iso format but it is still showing the following error.....

Booting 'Install Linux'
kernel (hd0,0)/boot/vmlinuz
error 14: Invalid or unsupported executable format
Press any key to continue.........

now what to do ....i'm not getting the things causing to happen it....
how to resolve this error...any suggerstion???

September 29, 2008 3:11 AM

Anonymous
said...

I have converted .nrg format image to .iso format but it is still showing the following error.....

Booting 'Install Linux'
kernel (hd0,0)/boot/vmlinuz
error 14: Invalid or unsupported executable format
Press any key to continue.........

now what to do ....i'm not getting the things causing to happen it....
how to resolve this error...any suggestion ???

September 29, 2008 3:11 AM

Anonymous
said...

i did the whole steps, i just cant select the instalation source, with a ubuntu server
i just go the option to use the cdrom has a source (at the instalation menus)

October 2, 2008 8:19 PM

Post a Comment

Post a Comment

Newer Post

Older Post

Subscribe To instant fundas

Get Free updates via email:

Powered by FeedBlitz

RSS Feeds

Recent Posts

Popular Posts

120+ sites to watch TV and movies online

100+ sites to look for Photoshop tutorials

1 Gigabyte is Not Equal to 1024 Megabytes

Install Linux directly from hard disk without burning DVD

20 (most) beautiful themes for Windows XP

21 most beautiful mouse cursors for Windows

How to create Windows XP Live CD, complete with preinstalled programs

15 Free CD/DVD burning alternatives to Nero

Can you answer this one?

Recent Photos

Roadsworth's incredible street stencil art

How girls download Youtube videos

Britain's 50 Foot Spider

Fingermaze - The world's largest fingerprint

Capacitor Bikes

Archive

Archive
October (18)
September (41)
August (36)
July (40)
June (37)
May (35)
April (35)
March (33)
February (27)
January (36)
December (22)
November (28)
October (34)
September (37)
August (36)

Topics

Astronomy

(6)

Audio/Video

(31)

Bloggers n Webmasters

(38)

Ebooks

(6)

Educational

(10)

Email

(23)

Firefox

(45)

Free Stuff

(25)

Fun n Leisure

(48)

General Science

(18)

Google

(41)

Graphics

(29)

Humour

(9)

Internet

(109)

Linux

(13)

Microsoft Office

(14)

Mobile Applications

(3)

Other Browsers

(27)

Productivity Tools

(54)

Random

(9)

Security

(29)

Software

(239)

Tech Knowledge

(18)

Tutorials n Tips

(80)

Windows

(102)

Featured Free Ebooks

7 Key Criteria for Choosing a Managed File Transfer Solution

Backup and Recovery Best Practices for Microsoft SQL Server 2005

eWeek

Google Apps: Quick Tour

Blind SQL injection: are your web applications vulnerable?

Google's Universal Search for Universities

Comprehensive Review of Security and Vulnerability Protections for Google Apps

From OpenView to Open Source

Software Test & Performance

Oracle Magazine

Other stuff

• Register domain

• 35 Millimeter

• Best Desktop Wallpapers

• Windows Live Toolbar

• Windows Live OneCare - Helps keep your PC trouble-free

Further Reading

Recent Comments

© 2007-08 instant fundas All Rights Reserved
Fresh Blogger Template Designed by Wolfgang Bartelme

Contact Me
Privacy Policy