Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
This I think is simple but I can't make it work. I want to boot an iso from hard disk using grub in a repeatable fashion
The case for it is two fold. I have a system that I want to upgrade the OS on but It has no CD OR floppy. It does however have a spare partition and disk space.
I can also use this to test a live CD I want to build. I know that I can mount an iso in loopback mode but then I wouldn't be able to boot it.
I'm thinking that I can dd a bootable iso image into the partiton and then boot from that partition next boot. This would allow me to boot any OS installer really easily without having to have a CD-RW to hand.
OK so I am doing this which works OK with no errors if the partition is big enough.
# dd if=boot.iso of=/dev/hda4
I can mount this OK using mount -t iso9660 /dev/hda4 /mnt/iso
It's the grub config that gets me. Why doesn't chainloading the disk work? the grub entry is this:
title Boot ISO
root (hd0,3)
chainload +1
This fails and goes back to the grub menu.
I've also tried this config for linux boot cds (Suse 9.1)
title boot suse installer
kernel (hd0,3)/boot/loader/linux
initrd (hd0,3)/boot/loader/initrd
but this fails because grub cannot read iso9660 filesystems. I can boot the CD by copying the kernel and initrd to the /boot on the linux partiition. However this is not going to help me when I want to boot a different os (eg a windows/dos/BSD boot iso)
I'm stuck here, help appreciated. Am I on the right track or should I be trying a different approach?
Booting an ISO is not possible IMO. But for testing ISO files without burning them, there's maybe a solution: BOCHS. This virtual machine should be able to boot and test an ISO file.
Hello Boffin,
How are you doing???
You seem to be knowl'ble person, so please tell me that can I install Linux from the ios images stored on the Hard Disk after booting the system from floppy or CD, if yes How can I make it happen. I am new to Linux but eager to get to the core.
Please help...
I think what things like that do is 'jump start' the boot, so you are still booting from CD first, and then jumping into the ISO. So directly booting from the ISO wouldn't work, but an intermediate source, for example a bootable CD like knoppix, would get you going and then mount up the ISO and launch it as the OS.
Looking at your original post - you shouldn't need to 'dd' the iso image. Mounting it as a loop device will make it 'readable' and from there you can copy it to your new partition with somehting like
Code:
cd /mnt/point
find . -xdev | cpio -pmv /path/to/new/partition
The loop device is just a virtualized filesystem, not a permanent one, and that's why you can't see it when you reboot.
Well, I hear dd and I hear "just copy the files". Solution is simple, but by no means one-step. First format the partition. Then you mount the loopback and copy all the files. Then configure and install grub or lilo into the PARTITION BOOT SECTOR. Live cds use isolinux, so dd will end up copying that. I'm not sure how exactly that would work on a hard drive, but it sounds wierd.
Not to seem disputatious, BUT. I had a similar situation. I d/l'd an ISO, but didn't have a cd-r to burn it to cd. After googling for a while, I found a document which said, quite simply:
If you have room on your harddrive, create a small partition. format it as though it were a cd (iso9660) and install the iso there as though you were burning a cd. Then mount and install from there.
If you have a floppy drive but not a CD drive, you can use bootstrap floppies (e.g. Debian provides bootstrap floppies, such as boot.img and root.img) and tell the system manually to use a block device rather than the CD drive. Moreover, I think you can mount floppies with chainloader, but I haven't tried it myself (though I know it's possible to mount a floppy on a hard drive).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.