How to install a distro (e.g. LMDE) with no DVD or USB boot

Write tutorials here
There are more tutorials here http://community.linuxmint.com/tutorial/welcome
Forum rules
Please don't add support questions to tutorials,start your own thread in the appropriate sub-forum instead. Before you post please read this
User avatar
beefstu
Level 5
Level 5
Posts: 653
Joined: Tue Dec 29, 2009 10:22 am
Location: Southampton, UK

How to install a distro (e.g. LMDE) with no DVD or USB boot

Postby beefstu » Wed Jan 26, 2011 1:47 pm

If your computer is only equipped with a CD drive and cannot boot from USB drives, here's a work around. It could also be used if you have forgotten your BIOS password and cannot change the boot device. It requires that you already have Linux installed (or at least grub installed) before hand and a 1GB or higher memory stick. For the purposes of this, I'll assume the distribution is LMDE, however it should work fine with any.

1. Download LMDE.iso

2. Install unetbootin

Code: Select all

apt install unetbootin
and use it to write the .iso to your memory stick

3. Boot into any live CD, go to GParted and resize your current Mint partition to as small as you can and format the newly created space as EXT4 (or whatever file system you want to use)

4. Boot back into the installed Mint

5. in a terminal

Code: Select all

sudo cp /boot/grub/grub.cfg /boot/grub/grub.cfg.bac
to backup the grub.cfg, then

Code: Select all

gksudo gedit /boot/grub/grub.cfg


6. scroll down until you find the line ### BEGIN /etc/grub.d/10_linux ### and under that write

Code: Select all

menuentry "Linux Mint Debian Installer" --class linuxmint --class gnu-linux --class gnu --class os {
        set root='(hdX,Y)'
        linux /casper/vmlinuz ro boot=live live-media-path=/casper quiet splash --
        initrd /casper/initrd.lz
}


where (hdX,Y) need to have the X changed to the number of hardrives within your computer and Y to the partition number you have installed the iso to on your USB. For example, I only have 1 harddrive in my laptop and only 1 partition on my memory stick (same is true for the majority), therefore, mine reads '(hd1,1)'

DONT CHANGE ANYTHING ELSE IN THIS FILE

7. Reboot and boot into the new option on the grub screen. Its important not to have any other external media attached at this point

8. Install LMDE as normal, using the new partition created earlier. NOTE: when the installer asks you to install grub, either untick it (as I did as I was concerned to mess up grub, just in case, and besides, its already installed) or make sure it is set to your harddrive (probably sda), not the memory stick you are installing off of.

9. Reboot and go back to your original installation, run

Code: Select all

sudo update-grub
then

Code: Select all

sudo cp /boot/grub/grub.cfg /boot/grub/grub.cfg.bac2
then

Code: Select all

gksudo gedit /boot/grub/grub.cfg
scroll down to the menu item for your new installation, (i.e. menuentry "Debian GNU/Linux.....") and check that the UUID's (a long string of letters and numbers) in the entry's (two in the normal entry and 2 in the "recovery mode" entry) match eachother as mine did not and produced a busybox. If they match, go ahead and reboot and your new installation should be waiting for you, then continue to step 10. If they do not match, goto step "UUID" first.


10. boot into a live Cd and use GParted to delete the old LM9 installation and extend the LMDE partition to use all the space

11. in a terminal (still on live CD), run

Code: Select all

sudo update-grub
Reboot and voila!


"UUID" - this step is taken if your UUIDs in your menu entrys do not match. (I have no idea why this happens)

On your original installation, goto GParted (it may not be installed, in which case

Code: Select all

apt install gparted
) then right-click on the new installation partition and press information. on there there is a UUID written, copy this and carefully replace the four UUIDs in the menu entrys (it will probably be the same as 2 of them) and reboot. When you next run update-grub, you may have to do this again. As you have to run it in step 11, its definitely worth checking after you have run it that the UUIDs match by running

Code: Select all

gksudo gedit /boot/grub/grub.cfg
before you reboot to avoid complications. now carry on from step 10.


-----------------------------------------------------------------------------------------------
Taken and edited from here http://bobpeers.com/linux/hard_drive_install and here http://www.instantfundas.com/2007/08/in ... -from.html and my own experiments!!

if you have any issues let me know!
Please go through the steps here when posting a question. Once your question has been resolved, edit the original question post and add [Solved] to the subject. Both of these will help others use the forum effectively.

Return to “Tutorials”

Who is online

Users browsing this forum: No registered users and 3 guests