LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-08-2017, 11:23 AM   #1
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Rep: Reputation: Disabled
boot .iso file from grub [fash/usb drive]


Hi guys,

im facing a problem with grub cfg (i swear grub related)

- having a usb drive (16gb) with grub installed
- having a puppylinux.iso

I want to make this usb bootable (already success)
I want make a boot entry with puppylinux as an option
I want to boot puppylinux from grub

----------

my usb files:

ivan@ivan-K52JU:/media/ivan/ISO-POOL$ tree -L 2
.
├── boot
│** └── grub/ ... grub.cfg
├── clonezilla-live-2.5.0-25-amd64.iso
└── slacko-6.3.0.iso <- i want to boot this one

my grub.cfg:

ivan@ivan-K52JU:/media/ivan/ISO-POOL$ cat boot/grub/grub.cfg
set timeout=10
set default=0

menuentry "Run slacko!" {
loopback loop /slacko-6.3.0.iso
linux (loop)/vmlinuz
initrd (loop)/initrd.gz
}

when i boot this usb, grub shows well, and it appears the menu entry. But something goes wrong while loading files:

"puppy_slacko.sfs not found dropping out to initial ramdisk console"

and it doesnt load anymore (i have to reboot)

Im sure to be missing something in grub configuration.

thanks in advance cheers
 
Old 04-08-2017, 12:49 PM   #2
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,363

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Quote:
Originally Posted by ciroreed View Post
... when i boot this usb, grub shows well, and it appears the menu entry. But something goes wrong while loading files:

"puppy_slacko.sfs not found dropping out to initial ramdisk console"

and it doesnt load anymore (i have to reboot)

Im sure to be missing something in grub configuration.

thanks in advance cheers
Hi ciroreed,

This is a common issue with the puppies and yes, you are correct in guessing it is grub-related. Puppy requires specific options on the kernel line of the boot loader for it to boot properly - and these vary a bit from one puppy version to the next.

Google "kernel boot options for puppy linux" online. If you can't find the right answer, get back to us, but I would be surprised. This is, as previously mentioned, a common issue. On my side, if I have a second, I'll check my last puppy install and get back to this thread.

Cheers.
 
1 members found this post helpful.
Old 04-08-2017, 12:52 PM   #3
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,363

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
... following up on my previous post, here is a good starting point:

http://puppylinux.org/wikka/BootParameters

Cheers.
 
Old 04-08-2017, 02:39 PM   #4
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: PCLinux, Slackware, Ubuntu
Posts: 9,980

Rep: Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329
You are not telling it which partition to look for. An example of a successful boot of Puppy from iso is at the video link below. Note the "from iso" part of the menuentry shown in the video.

https://www.youtube.com/watch?v=4M1ufJVxJmU
 
Old 04-08-2017, 03:50 PM   #5
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by yancek View Post
You are not telling it which partition to look for. An example of a successful boot of Puppy from iso is at the video link below. Note the "from iso" part of the menuentry shown in the video.

https://www.youtube.com/watch?v=4M1ufJVxJmU
Puppy is not installed on some partition, it is just on the iso.
 
Old 04-08-2017, 03:50 PM   #6
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Rickkkk View Post
... following up on my previous post, here is a good starting point:

http://puppylinux.org/wikka/BootParameters

Cheers.
im testing this one. http://puppylinux.org/wikka/GRUB

thanks, i hope it works
 
Old 04-08-2017, 04:25 PM   #7
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
it doesnt work...

(attachment) same error
Attached Thumbnails
Click image for larger version

Name:	IMG_20170408_180013.jpg
Views:	117
Size:	62.7 KB
ID:	24730  
 
Old 04-08-2017, 04:45 PM   #8
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
testing this one

ivan@ivan-K52JU:~$ cat /media/ivan/ISO-POOL/boot/grub/grub.cfg
set timeout=10
set default=0

menuentry "Run slacko!" {
set isofile='/slacko-6.3.0.iso'
loopback loop $isofile
linux (loop)/vmlinuz boot=live config findiso=$isofile
initrd (loop)/initrd.gz
}


getting another error..
Attached Thumbnails
Click image for larger version

Name:	IMG_20170408_233705.jpg
Views:	100
Size:	77.6 KB
ID:	24731  
 
Old 04-08-2017, 04:55 PM   #9
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
Ill download another puppy distro. Though slacko is a little anyoing to setup on a flash drive.

(i was able to boot it with dd [disk override])
 
Old 04-08-2017, 06:13 PM   #10
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: PCLinux, Slackware, Ubuntu
Posts: 9,980

Rep: Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329
If I'm reading your posts correctly, you appear to have a Slacko Puppy iso as well as clonezilla on the flash drive, is that correct? Can you boot clonezilla? I tested the menuentry from the link I posted earlier. Didn't work, same error.

The problem is not Grub, it is Puppy. If you google the error you report in your initial post you will find hundreds, maybe thousands of threads at the Puppy and other forums on the problem with various versions of Puppy. I've managed to boot dozens of Linux iso files of different distributions but never had any luck with Puppy. Grub is perfectly capable of booting an iso directly but the distribution must also be capable of being booted as an iso.

Two options that I know work as I've tested them. The first menuentry below worked booting the slacko iso which was on the root of the partition but not until I loop mounted the iso and copied the puppy_slacko_6.3.2-sfs and zdrv_slacko_6.3.2.sfs files from the loop mounted iso location to the root of the partition. I came across that suggestion at a Puppy forum.

menuentry "Slacko-6.3.2"{
loopback loop /slacko-6.3.2-uefi.iso
set root='hd1,msdos3'
linux (loop)/vmlinuz iso-scan/filename=/slacko-6.3.2uefi.iso
initrd (loop)/initrd.gz
}

The other option is to loop mount the iso then create a 'puppy' directory on the root of the partition and copy all the files into the puppy directory. The entry below will boot it.

menuentry "Slacko-Extracted" {
set root='hd1,msdos3'
linux /puppy/vmlinuz
initrd /puppy/initrd.gz
}

The entries above show hd1,msdos3 which is equivalent to sdb3. If you are booting from a flash drive you would need to change that to hd0,msdos1.

Quote:
Puppy is not installed on some partition, it is just on the iso.
??The puppy iso is on a flash drive,correct? You should have a partition on the flash drive where you put the Puppy iso. Do you have Grub installed to the flash drive? In order to boot it, you have to point to the specific files you need which are on the iso. Have you loop mounted it to see what files are there? If you do that, you will see the .sfs files. If you want to boot Slacko this way, you either simply copy the iso file to the flash drive partition or use the second option I suggested above.

Quote:
Though slacko is a little anyoing to setup on a flash drive.
I don't know what that comment means. If you have Grub on the flash drive and want to boot Puppy also on the flash drive, there is no setting up involved. You simply copy the iso to whichever partition you want it on the flash drive and put a proper menuentry in grub.cfg.

You might do a little reading on Grub works, specifically with iso files.

Last edited by yancek; 04-08-2017 at 06:17 PM.
 
1 members found this post helpful.
Old 04-09-2017, 03:39 AM   #11
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
I don't know what that comment means. If you have Grub on the flash drive and want to boot Puppy also on the flash drive, there is no setting up involved. You simply copy the iso to whichever partition you want it on the flash drive and put a proper menuentry in grub.cfg.

Quote:
Originally Posted by yancek View Post
You might do a little reading on Grub works, specifically with iso files.
yep, TODO list.

Quote:
Originally Posted by yancek View Post
menuentry "Slacko-6.3.2"{
loopback loop /slacko-6.3.2-uefi.iso
set root='hd1,msdos3'
linux (loop)/vmlinuz iso-scan/filename=/slacko-6.3.2uefi.iso
initrd (loop)/initrd.gz
}
this doesnt work because partition table in flashdrive isnt msdos -> current: "Disklabel type: gpt"

Quote:
Originally Posted by yancek View Post
menuentry "Slacko-6.3.2"{
??The puppy iso is on a flash drive,correct? You should have a partition on the flash drive where you put the Puppy iso. Do you have Grub installed to the flash drive? In order to boot it, you have to point to the specific files you need which are on the iso. Have you loop mounted it to see what files are there? If you do that, you will see the .sfs files. If you want to boot Slacko this way, you either simply copy the iso file to the flash drive partition or use the second option I suggested above.
root@ivan-K52JU:/home/ivan# mount -o loop /media/ivan/ISO-POOL/slacko-6.3.0.iso /mnt
mount: /dev/loop0 is write-protected, mounting read-only
root@ivan-K52JU:/home/ivan# ls /mnt
boot.cat help.msg isolinux.cfg README.HTM
boot.msg initrd.gz logo.16 vmlinuz
help2.msg isolinux.bin puppy_slacko_6.3.0.sfs zdrv_slacko_6.3.0.sfs

grup was installed by this way:

119 grub-install --force --removable --boot-directory=/media/ivan/ISO-POOL/boot /dev/sdb

Hope that help.

last cfg:

root@ivan-K52JU:/home/ivan# cat /media/ivan/ISO-POOL/boot/grub/grub.cfg
set timeout=10
set default=0

menuentry "precise-5.7.1-retro.iso" { <- (another puppy distro)
set isofile='/precise-5.7.1-retro.iso'
set root='hd0,msdos1'
loopback loop $isofile
linux (loop)/vmlinuz iso-scan/filename=$isofile
initrd (loop)/initrd.gz
}

many thanks
 
Old 04-09-2017, 03:41 AM   #12
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
im gonna redo all the process, create a new partition table (msdos)

ill post it
 
Old 04-09-2017, 04:12 AM   #13
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
Steps to reproduce the problem


0 - download slacko-6.3.0.iso
0 - usb flash drive

1 - format usb flash drive
1.1 - create msdos partition table
1.2 - create a partition sdX1 (fat32)

2 - install grub
2.1 - sudo mount /dev/sdX1 /mnt/USB/
2.2 - sudo grub-install --force --removable --boot-directory=/mnt/USB/boot /dev/sdX

3 - copy slacko-6.3.0.iso to usb flash drive
3.1 - having the following dir on flash drive:

ivan@ivan-K52JU:/mnt/USB$ tree -L 2
.
├── boot
│** └── grub
└── slacko-6.3.0.iso

3.2 - having the following files inside .iso (puppylinux)

ivan@ivan-K52JU:/mnt/USB$ sudo mount -o loop /mnt/USB/ /mnt
boot/ slacko-6.3.0.iso
ivan@ivan-K52JU:/mnt/USB$ sudo mount -o loop /mnt/USB/slacko-6.3.0.iso /mnt
mount: /dev/loop0 is write-protected, mounting read-only
ivan@ivan-K52JU:/mnt/USB$ cd
ivan@ivan-K52JU:~$ tree -L 2 /mnt/
/mnt/
├── boot.cat
├── boot.msg
├── help2.msg
├── help.msg
├── initrd.gz
├── isolinux.bin
├── isolinux.cfg
├── logo.16
├── puppy_slacko_6.3.0.sfs
├── README.HTM
├── vmlinuz
└── zdrv_slacko_6.3.0.sfs

0 directories, 12 files


4 - setup grub.cfg
4.1 sudo mount /dev/sdX1 /mnt
4.2 nano /mnt/boot/grub/grub.cfg ...

summary: im gonna re-test with msdos partition table
 
Old 04-09-2017, 06:52 AM   #14
ciroreed
Member
 
Registered: Jul 2015
Posts: 47

Original Poster
Rep: Reputation: Disabled
Guys, thanks but I think im going to post this on puppyforum. I tested all of the options but none work
 
Old 04-09-2017, 08:33 AM   #15
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: PCLinux, Slackware, Ubuntu
Posts: 9,980

Rep: Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329Reputation: 2329
Quote:
this doesnt work because partition table in flashdrive isnt msdos -> current: "Disklabel type: gpt"
You could try just changing the entry to 'hd1,gpt3' or whatever the partition is. I don't use GPT but see that on other threads dealing with GPT. Simple enough to test if your partition table is still GPT.

Reviewing your more recent posts, it appears you have mis-read my earlier posts. The first method suggested in post 10 did come from a Puppy forum and seemed a little weird to me. I've never done any thing like that with any other Linux iso but it did boot. You got the steps right until the part about copying the sfs files. After loop mounting the slacko.iso, copy these two sfs files to the root of the partition, where you have the iso file: puppy_slacko_6.3.0.sfs zdrv_slacko_6.3.0.sfs When you then look at the partition, you should then see the two .sfs files, the slack.iso and the boot directory. Using the first menuentry I posted above should then boot Puppy.

The second method requires you to loop mount the slack.iso, then create a puppy directory on the flash drive on the root of the partition, and copy all the files from the loop mounted directory to the puppy directory on the flash drive and use the second menuentry I posted above and put in in your grub.cfg file on the flash drive. With this method, you are not booting the iso but rather the 'extracted' files and you can delete the iso file of slacko from the flash drive.
 
  


Reply

Tags
boot, grub, puppy, usb


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] how to boot using grub from iso on usb stick ddsglq Linux Mint 13 09-08-2015 10:13 PM
[SOLVED] How to boot from GRUB version 1 on an ISO on the hard drive. kevinbenko Linux - Newbie 5 01-12-2013 09:17 AM
Grub File Not found Grub Rescue Error on External Sata to USB Drive imayneed Linux - Newbie 11 08-22-2012 02:56 AM
[SOLVED] how to boot to a Linux iso file image when installed onto a USB external hard drive ? james2b Linux - Newbie 2 11-30-2009 12:26 AM
boot from any .iso file on a USB pen drive browny_amiga Linux - General 10 04-07-2008 04:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:56 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration