Till now, probably you know how to install linux by burning the ISO image to a cd/DVD or using a USB flash drive with softwares like UNETBOOTIN and others. Now, If I tell you that you don’t need any CD or DVD or even a USB pendrive to install Linux in your Hard Drive, would you believe it?

In my previous video I have shown How to install any Linux Distro in WUBI Directlly from ISO image –

The main disadvantage of WUBI is that it installs the OS inside Windows, inside a Folder. As Windows still uses NTFS file System a large amount of root.disk (which is actually a EXT3/EXT4 filesystem) can cause a inaccessible FRAGMENTED file which can harm your magnetic Hard disk.

So, after you get familiar with the linux Environment, It’s Time to respect Linux as an Operating System and not as a program that you can remove from control Panel.

Here I will show you How to Install any Linux Distribution in a separate partition Directly from an ISO image stored in the hard Drive alongside Windows – Dual Boot.

In Windows booting from an ISO file is not possible, whether in Linux, a small Tweak in the Grub configuration lets you do that easily.

We can do ISO BOOT using a program called EASYBCD –
But it seems to depend on latest version of .NET Framework and will not work on Windows XP only machines.

So, here is the HACK. We are gonna install GRUB in Windows.

Download the Grub2Win zip file from here –

Extract Grub2 in your C: drive and run Grub2Win.exe
You can customize boot options. Now, we will use the POWER of Grub2 to boot from Linux LIVE CD/DVD images.

How to add and customize the boot entries manually?
You can tweak the available options in grub2win window to customize the boot menu, but here I’m gonna show you how to do it manually.
Don’t change any thing and click OK. this will just make an BCD entry in Windows 7 with just one boot entry – Windows 7 (default).
Close grub2Win. You can find that the program creates a new file named “GRUB.CFG”

Now, we will add the MINT boot entry in the GRUB configuration file. Open the GRUB.CFG file in a text editor like NOTEPAD.
Add an extra menuentry just after the default “Windows” menuentry –
________________________________

menuentry “Linux Mint” {
set isofile=”/linuxmint-17.1-cinnamon-32bit.iso”
loopback loop (hd0,1)$isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile noprompt noeject
initrd (loop)/casper/initrd.lz
}
_______________________________
Remember: Here in this case the ISO file is in the first partition of the first disk so, the file location is (hd0,1), if you put the ISO file elsewhere change the loop device location accordingly.

You can add any ubuntu based linux distro like this way, all you need is to check the casper folder inside the iso file for correct initrd file extension (it may be .xz, .gz, etc.) and change the menuentry settings accordingly.

Once restarted, you will see an extra boot entry “Grub 2 For Windows”. Select Mint and you will enter the LIVE session.

Now if you try to install mint in your Hard Drive, it will give you a prompt to Unmount all the Drive to change or resize the partition table, but it won’t let you do that easily. It’ll tell you the drive can’t be unmounted becauose of the /ISODEVICE is there. If you go to that folder you will see all the contents of your Drive along with the ISO file itself is there.

So, what do we get from this?
The Drive itself is mounted in the /ISODEVICE folder and to unmount the Drive we need to forcefully unmount the /ISODEVICE first, which makes the ISO file iteself unavailable for the rest of the process.

Is this even possible? The Computer is currently running from the ISO file as we have virtually inserted the Mint Disk inside the DVD Drive. If we unmount The ISODEVICE, wouldn’t the computer FREEZE ?
As we’ve successfully boot from the ISO file and entered the LIVE session, we don’t need the ISO file any more.

Okay, now how to unmount the ISODEVICE?
open terminal and enter the following command –
sudo umount -l -r -f /isodevice

Voilà, you have now unmounted the partition and see the computer don’t hangs.

Now you can resize the partition and Continue to install mint like you always do.

Nguồn: https://codeigniterbrasil.com

Xem thêm bài viết khác: https://codeigniterbrasil.com/lap-trinh-linux/

45 Comments

Dumitru Grajdieru

May 8, 2020

Where exactly should stay the iso file

Reply

Vaibhav Tyagi

May 8, 2020

Please help followed every bit but my linux mint 19.3 is not found please give me code for it

Reply

Just_X

May 8, 2020

Please , give me a completed .cfg file for grub!

Reply

Mohd labu

May 8, 2020

Anybody know how to solve this ? Linux mint 19.2
Link to my problem
https://youtu.be/chezF2yXzO0

Reply

SWODEEP SAHOO

May 8, 2020

Can you/anyone help me with ubuntu dual boot and edit in cfg?
The cfg file has changed ..please guide accordingly.

Thanks

Reply

george9559

May 8, 2020

Can i use that method to install Ubuntu 18.04 LTS?

Reply

valen flitz

May 8, 2020

It works for me, thank you bro

Reply

cesar sil

May 8, 2020

please i need to boot MenuetOs, help me, the code please.

Reply

file fill

May 8, 2020

Please fix a problem with me and download Windows 7 32 – bit and when you access it from the boot menu do not work and show in this screen the message
:

GRUB4DOS 0.4.5c 2014-01-17, Mem: 635K/3013M/992M, End: 356201

[ Minimal BASH-like line editing is supported. For the first word, TAB

lists possible command completions. Anywhere else TAB lists the possible

completions of a device/filename. ]

grub>

Reply

kittu reddy

May 8, 2020

what should i edit for kali linux 2019.1 file

Reply

MS RAO

May 8, 2020

Will it work on windows 10?

Reply

Tomy Power

May 8, 2020

Yes I shall you

Reply

I3lood Crysis

May 8, 2020

Trojan bitch

Reply

Shahalam Ahmed

May 8, 2020

Sudo commund not found,…. I trying to install mint 18.3

Reply

andygoku110

May 8, 2020

Error error linux unable to find a medium containing a live file system español

Reply

bimal

May 8, 2020

B ing Su/Man sir, I have downloaded 2017.3 latest version of Kali Linux. will this code work? what should I edit? Iso file name is:
"kali-linux-2017.3-amd64"
please help

Reply

Pepe

May 8, 2020

can i make this with linux zorin ?

Reply

Sai Mourya

May 8, 2020

i am not gettting it i try to install kali linux 2017 but it gives the error 'out of range' and 'you need to start kernal first' can anyone please help me out

Reply

Brad Marsh

May 8, 2020

hey can i ask some advice please? this looks like it will work for me but when i boot into grub and select the menu entry it says it cannot find the iso. i left it on the root of C: in windows like you did and iincluded the line: set isofile="/myiso.iso" but it says it cant find it when i boot from grub. what am i doing wrong? thanks very much

Reply

Sky Kast

May 8, 2020

I tried and it's not working… I'm trying mint 18.1

Reply

Mobile-Tech Bangla

May 8, 2020

i downloaded linux mint but that is a disk image file,not a iso file.is disk image file and iso file same??

Reply

kn knkn

May 8, 2020

Bro i neeed urgent help… Can give ur whatsapp or 8861665082 dm on wtsapp plz i have lot of doubt

Reply

Ahmed Mohamed Loay Ahmed Abdulla

May 8, 2020

Does windows slow down Linux or Linux slow down windows?

Reply

ZONA DIJE

May 8, 2020

Whether it can be for KALI LINUX 2017????

Reply

demetrio dario

May 8, 2020

it installed but there still error on the bootup it said cannot write byte pipe something like that

Reply

demetrio dario

May 8, 2020

hope this boot

Reply

demetrio dario

May 8, 2020

its installing now.. thanks dude i got my fingers crossed

Reply

demetrio dario

May 8, 2020

what should i do if let say i want to install ubuntu 12.04

Reply

Vishalkumar Sonawane

May 8, 2020

please guide me, I wanna install mint alongside win 8.1in my case I already have a fully empty (E) drive and I want to install mint on that.
What should I do?

Reply

PhysicalRobloxers

May 8, 2020

I used the this tool and it fried my motherboard as a bang could be heard as you booted from the grub warning do this if you want a fried pc

Reply

firdous ahmad

May 8, 2020

and i'm using windows 8

Reply

firdous ahmad

May 8, 2020

i can't find any partition drive on dual boot. when i click new partition button it says you have selected an entire device to partition if you proceed with create a new partition table on the device then all current partition will be removed

Reply

V SANGARSHANAN 15BCB0093

May 8, 2020

is it u stephen hawking ?

Reply

Vahagn Shahnazaryan

May 8, 2020

Thank you !!!

Reply

eshan pandita

May 8, 2020

hi i am installing mint18.1 but it starts in terminal mode and doesnt start gui, tried start x also no luck
menuentry "Linuxopen Mint" {
set isofile="/linuxmint-18.1-cinnamon-64bit.iso"
loopback loop (hd0,4)$isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile noprompt noeject
initrd (loop)/casper/initrd.lz

Reply

taxgun

May 8, 2020

i want full not :/

Reply

Lyricboiii

May 8, 2020

DO i need any cd dvd or a usb stick ?

Reply

Iterator

May 8, 2020

it saying me "out of range" and " you need to load kernel first" and not booting. Help me pls!

Reply

drummerdp

May 8, 2020

Hi All,

Grub2Win now has the ability to add an ISO boot entry from within the program. You no longer need to edit the grub.cfg file.

Drummerdp

Reply

Adrame Kone

May 8, 2020

hello just have some issue
error: read ouf of range

Reply

ahmad Modi

May 8, 2020

Hey I have a problem accessing Linux mint after installing it.
because grub doesn't detect it.
can try give me a menu enter for mint cinnamon 64bit
the partition should be 7

Reply

Abhishek Prabhakar

May 8, 2020

man you are saviour…..thanks your video helped me to install mint 18 on my old pc

Reply

Hristo Hristov

May 8, 2020

Great tuto, but how do we boot Ubunto after it's installed? Obviously we need to change the grub config file. I did it trough the GUI so I ended up with this:

menuentry 'Ubuntu' –class ubuntu –class icon-ubuntu {
set root='(hd1,2)'
linux /vmlinuz root=/dev/sdb2 verbose nomodeset
initrd /initrd.img
savelast 1 'Ubuntu'
}

but it is not working. Can't find vmlinuz file. I tried with '(hd1,3) and '(hd1,4) and it said "no such partition" . The reason I think it should be 3 and 4 is because I see those empty drives (no letters assigned) under windows disk management. I let Ubunto allocate a partition for itself (obviously it allocated 2) during installation in my storage drive (G), because I didn't have enough space on the SSD where windows is installed.

Reply

chaithanya bonthala

May 8, 2020

Thank you very much for this video…. Am trying to put redhat linux in this way… Showing 2 errors…. Disk '(hd0, 1)not found(even though my iso file is in c-drive only… And second one is NO SERVER SPECIFIED unaligned pointer 0xc2d5b2b8
What should i do…? can u Please suggest me the solution……

Reply

Matthew McAdams

May 8, 2020

Will this work on Windows 10?

Reply

Leave a Reply