Damn Small Linux (DSL) Forums

Damn Small Linux => Laptops => Topic started by: Benny on July 17, 2013, 01:42:12 PM

Title: How to boot DSL using grub - frugal?
Post by: Benny on July 17, 2013, 01:42:12 PM
I've been trying to boot frugally DSL at a VAIO for years without any success. Recently, made some changes in the menu.lst file at DSL's section and obtained something different: a rather long list of messages that didn't fit on the screen. Although it didn't boot I've some (probably/hopefully) useful/starting tips offered by the system? that might be useful for someone with the right knowledge (not me).

Below, I'm posting what I've written by hand of the last full screen seen (what's interesting for me, not all the page):

... contents of previous lines unknown)
kmod: failed to exec /sbin/modprobe -s -k scsi_hostadapter, error = 2
ibid = last line repeated right away
...jump forward some lines

VFS: Cannot open root device "(hd0" or 00:00
Please append a correct root=" boot option.
Kernel panic: VFS: Unable to mount root fs on 00:00

BTW, is there a way of redirecting all those messages to a pre-determined (log)file for later examination?

Thanks in advance for any tips/help on this!

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 18, 2013, 09:21:15 AM
Are you trying to boot from the HDD or the CDROM (i.e. what you were trying to do on your HP laptop?). If you are booting from the HDD then it looks like you have the wrong HDD/partition set as the "root" in menu.lst.

If you can boot from CD, look in all the HDD partitions in the /mnt directory and when you find one that has the Linux directories (bin, boot, opt, etc.) take note of it and enter it into menu.lst after "root=/dev/". If your HDD only has one partition, then it will probably be "hda1", so enter "root=/dev/hda1" into menu.lst.

If you can't boot the CD, tell me the model of your VAIO. I have an old one and could try booting DSL myself if it's a similar model.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 18, 2013, 02:22:00 PM
Thanks for replying, CNK!

Technically speaking, I'm booting from the HDD all my bootable distros; these are: 1) Puppy Linux 528.005, 2) PL 511, 3) PL 525, 4) Wary512 {this folder's now empty because had to make room for Slacko 5.5.4G but it was booting up OK} and 5) Puppy Studio. All of what precedes this sentence is in reference to the VAIO laptop.

At the HP laptop I'm booting up DSL from a 'pendrive' only because at that one I've no HDD. AFAIK, the DSL version at this 'pendrive' is an old one, ~2005 version.

Note the following: at the VAIO, my HDD is partitioned in three sections named sda1 (ntfs), sda2 (Home for all puppies (ext3)) and sda5 (ntfs). At the Home partition have one folder for each of my distros, each containing the necessary files for booting; one of those is DSL. Today I received at another forum in relation to another booting issue not related to DSL a message to check how my specific Home partition was named at the running distro (PL 528), i.e., sda# vs. hda# because apparently there're issues with some systems in relation to the naming of devices...; this might bring some problems to booting DSL as well I think. In any case, I've to boot from a live cd to run a <fsck> command because no partition should be mounted to run this. All this's at the VAIO. Need to search for more info on this command before proceeding.

Before making any changes at the menu.lst file in relation to DSL, which is located at sda2/boot/grub folder, the line starting with "kernel..." showed [root=boot something, which didn't make any sense to me. These entries were Copied/Pasted as suggested by some DSL user somewhere. My actual DSL entry is as follows:

7) Linux bootable partition config begins
  title Damn Small Linux
  rootnoverify   (hd0,1)
  kernel /dsl/linux24 root=/dev/(hd0,1) ro lang=us toram noeject frugal> initrd /dsl/minirt24.gz
# Linux bootable partition config ends

Yes, I noticed that it says hdo while at my desktop (running PL528) it says sda. This issue of device naming isn't resolved in my mind yet.

As part of the changes you suggest, should I also change the entry at the line containing "rootnoverify (hd0,1)" according to what I find? You might benefit understanding my present HDD's layout. I'll do my best below.

  • HDD broken in 3 primary partitions.
    • sda2 partition has 14 folders from which 7 are for OS booting.
      • DSL folder has 14 items of which 4 are folders (knopix, qemu, etc.).

When you say if I can boot from cd and look for something at /mnt in the HDD it confuses me to see that you expect me to find boot besides the other folders, if I understood correctly your exposition. I do have the other folders but no boot folder (I don't have a Windows OS system at this VAIO).

The model of this laptop is: Sony VAIO VGN AR250G Notebook + 512MB RAM.

Hope I gave you the necessary data on all areas, thanks!

EDIT: Now that I've paused for a while I remember that I'm using grub as a bootloader & that it identifies HDDs as hd0, hd1, etc. &, with respect to primary partitions they're (hd0,0), (hdo,1), etc. for the case of just one HDD.

The above means that my usage of device identifiers within menu.lst is correct; after all, if it would be wrong none of my puppies would boot.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 19, 2013, 11:16:28 AM
I suppose I was a bit ambiguous with the "root=" command as GRUB has its own "root" command (and similar "rootnoverify" command), in this case the equals sign makes all the difference.

The "kernel" command in GRUB passes everything after the location of the kernel, to the kernel once it is loaded. Therefore the "root=/dev/hda1" line would be interpreted by the DSL kernel with its "hd" disk designations, not by GRUB. Specifying "root=/dev/(hd0,1)" is asking the kernel to look for the item "(hd0,1)" in the "/dev" directory, which you can see for yourself is not there using a file manager. This, I suspect, it what the error "VFS: Cannot open root device "(hd0" or 00:00" indicates.

Section of the GRUB docs about the "kernel" command. (http://www.gnu.org/software/grub/manual/legacy/kernel.html#kernel)

As for the "sda" naming Vs "hda", this is related to the kernel versions. DSL uses "hd" to label IDE HDDs and "sd" to label SCSI, SATA, USB devices. Most modern linux distros (probably including Puppy) call all the drives "sd". Therefore if your desired partition is called "sda2" in Puppy, it will be "hda2" in DSL and hence your "root=" line after the "kernel" command would read "root=/dev/hda2". Also, I haven't tried this myself, but I figure if you want to run DSL in your "dsl" directory on hda2, then make the "root=" entry "root=/dev/hda2/dsl". Just to be clear, "rootnoverify" is a GRUB command, so keep the "(hd0,1)" format for it.

It looks like your VAIO is a few generations ahead of mine. As for the "boot" folder, I forgot you had a frugal install so the folders are a bit different. It doesn't matter.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 19, 2013, 11:49:28 AM
Looking some more at the rest of your "kernel" command line, I think "initrd /dsl/minirt24.gz" should be on a line by itself beneath the "kernel" command. The ">" character after "frugal" shouldn't be there either.
Look here for an example: (http://www.damnsmalllinux.org/wiki/installing_grub.html#Booting_the_first_time) Don't know if "makeactive" is strictly required, but it wouldn't hurt.

You should have a look at this page as well: (http://www.damnsmalllinux.org/wiki/cheat_codes.html)
The commands there are meant to come after the "root=" command on the "kernel" line. A couple of the ones you have strangely aren't on the list (are you using the old version of DSL on this machine too?).

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 19, 2013, 05:05:12 PM
WOW, you gave me a lot of detailed info AWA a lot to read, thanks CNK!

Going this time backwards, I'll start saying that I'm tring to boot at the VAIO the newest DSL version I have.

I hope the changes introduced at the menu.lst file today will prove satisfactory for getting closer to boot DSL at this computer. The DSL section now is as follows:

# 7) Linux bootable partition config begins
  title Damn Small Linux frugal in sda2 dir dsl
  rootnoverify (hd0,1)
  kernel /dsl/linux24 root=/dev/hda2/dsl ro lang=us toram noeject frugal
  initrd /dsl/minirt24.gz
# Linux bootable partition config ends

BTW, my HDD is a SATA drive but for a trial I'm going to stick with this entry as it is even though it might be wrong. If it doesn't work the first time I'll edit at boot time while using grub & check it out.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 20, 2013, 12:48:51 PM
After trying to boot with the changes in the last post in effect I got farther in my quest. I finished with a very limited shell (text only environment). But, probably, the most important thing is the message I saw at the screen then:

Can't find KNOPPIX filesystem, sorry.
Dropping you to a (very limited) Shell.
Press reset button to quit.
Additional builtin commands available: cat insmod mount umount rmmod lsmod

I never saw the said "reset" button, so I pressed the Power button to force a shutdown sequence.

After getting this message I tried various things at the menu.lst line starting with "initrd /dsl...", thinking that this part was the one grub was trying to execute for finding 'KNOPPIX', I inserted {/hda2} in front of /dsl, with the same result. Then added {/dev} in front of hda2 but still obtained the same thing.

Any clue(s) as to what might be happenning?

PS. At the top of the page I saw a message in relation to VFS & to check the filesystem. It's curious but the day before I received a message from another forum that advised me to run <fsck> due to another distro's inability to boot, I checked it & it showed no problem, so I'm disregarding this message, for now.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 21, 2013, 01:34:25 AM
If you've got a SATA HDD, then you will likely need to put "sata" at the end of the "kernel" line (I do suggest you look at the table on the "cheatcodes" page in the Wiki). The drive will also be recognised as "sda", as mentioned before.

If that doesn't work, check the BIOS settings. I've rarely used DSL with SATA hardware (never tried to install), but it may be worth fiddling with the SATA settings such as IDE Emulation (maybe have a look through the archive of the old forum). Remember to take note of what settings you had to start with though.

The error basically means that GRUB is loading things happily, but the kernel can't find the drive/files for DSL. This might be because it is being told to look in the wrong place, it hasn't detected the drive (such as where SATA support isn't enabled), the filesystem is corrupt or there is a problem with the DSL files or directory structure.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 25, 2013, 04:16:56 PM
I revisited the wiki page you mentioned at a previous post & decided to introduce some changes in the light that, after the minor changes last introduced, the boot process gave me the same result.

I've a doubt in relation to the section there titled "Other boot labels". I want to add <ide1=0x180,0x386> label appearing at almost the end of the table because I'm using a VAIO but don't know if it has to go before the kernel line or right after it (first guess is to put it before, but I'm commenting it for now).

See below for some other entries in my menu.lst file that are working OK:

# 5) Linux bootable partition config begins
#  title Puppy Wary 512 frugal in sda2 dir wary-512
#  rootnoverify (hd0,1)
#  kernel /wary-512/vmlinuz pmedia=atahd psubdir=wary-512 acpi=off
#  initrd /wary-512/initrd.gz
# Linux bootable partition config ends
# 6) Linux bootable partition config begins
  title Puppy Studio frugal in sda2 dir puppystudio
  rootnoverify (hd0,1)
  kernel /puppystudio/vmlinuz pmedia=atahd psubdir=puppystudio
  initrd /puppystudio/initrd.gz
# Linux bootable partition config ends
# 7) Linux bootable partition config begins
  title Damn Small Linux frugal in sda2 dir dsl
  rootnoverify (hd0,1)
#  ide1=0x180,0x386 
  kernel /dsl/linux24 root=/dev/sda2/dsl froomhd=/dev/sda2 knoppix_dir=dev/sda2/dsl knoppix_name=KNOPPIX ro lang=us restore=/dev/sda2 toram frugal sata
  initrd /dev/sda2/dsl/minirt24.gz
# Linux bootable partition config ends

Thanks for your support, CNK!

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 26, 2013, 04:42:58 PM
After introducing all the changes last posted I received a "file nor found" error. It kept appearing even after deleting (progressively) each of the changes presented (from the grub editor).

It could help me more (possibly) to know how grub really works; is it just passing along certain data in a certain format for the kernel to understand or it serves as a deeper layer (at least until the boot process is finished)?

One source of confussion in my case surges after comparing the lines starting with kernel, let say DSL entry #7 & Puppy Studio entry #6. pmedia=atahd & psubdir=puppystudio at the #6 entry serve well its purpose but the related entries at the DSL #7 entry, doesn't have a close representation. It appears to be more intricate & specific/detailed to a lower or basic level. Is this due to specific demands of the OS's kernel?

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 28, 2013, 01:34:58 AM
The "initrd" command shouldn't have "/dev/sda2" in the directory name. That is a command to GRUB which already knows what HDD you're talking about from the "rootnoverify" command, so you only need to tell it the directory and file name inside the drive.

I don't know about the "ide1" command. The wiki describes how to use it when booting from CD (where you have to type "dsl" before other startup commands), but I don't know how it applies to HDD booting. I'd put my money on it not being relevant to your modern VAIO anyway.

As I said before, I've never tried booting DSL inside a directory on the HDD. You should be able to get it to work, but you might find problems along the way (I'm not sure your current troubles are a result of that though).

How GRUB works:
I'm working off memory so this may be a bit general, but it should give you an idea.

When you boot a PC, the BIOS checks all the hardware and enables itself to behave as an interface between an Operating System and the PC hardware. In the days of DOS, this BIOS interface was used for all access to the HDD and FDD (this was before the days of CDs, so they wern't supported in this manner).

Nowadays Operating Systems ignore this and use their own driver software to access the hardware. However there is one stage where the BIOS is still important, in initial loading of the OS from the HDD. To do this the BIOS reads a specific area on the HDD named the Master Boot Record (MBR) where a tiny program is located which instructs the computer where and how to begin in loading the components of the OS.

The MBR is not a partition of the disk and it has no file system, it is simply a set area of the disk which is reserved for the tiny machine language loading program. The problem is that this reserved area is only 512 bytes. This is enough for a basic loader to start windows or DOS, but in multi boot systems, there is not enough room to store all the options and the interface of a multi-boot loader such as GRUB.

The solution is splitting the boot loader into stages. The first stage of GRUB is run from the MBR and simply runs a second stage that contains the code to enable the loading of the third stage which contains the menu and booting system. It is this third stage that we see and interact with using menu.lst.

All these stages are working in your case.

The "rootnoverify" (or "root") command tells GRUB which HDD/partition you want to work with (in case it is a different one to that on which GRUB resides). From there on, it is able to access the file system on that partition and load various components of the operating system. This process is specified through the commands in "menu.lst".

As a result, GRUB commands for OSs designed for booting using GRUB are standardised and should behave similarly in every case (unless they are incorrectly used of course). The exception to this is the commands after the initial directory specified in the "kernel" line (in your case "/dsl/linux24"). These are not used by GRUB, rather they are passed on to the kernel of the OS loaded. Therefore they are individual to each OS used and must use its system for specifying HDDs/partitions (Linux uses the "/dev" directory) as it does no know of the "rootnoverify" command passed to GRUB.

That was probably more detailed than you needed, but hopefully it clears up some of your uncertainty. The GRUB docs I linked to earlier have all the practical info such as the command descriptions for "menu.lst".

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 29, 2013, 06:17:58 PM
Thanks for replying, CNK, very interesting!

So, the BIOS is still working in a dormant state (standby) or simply terminated after a modern linux OS is up. In any case, grub is indeed a running program for the initial states and not simply a set of scripts to be followed by another program. In fact, if I understood you correctly, it does both things: executes instructions as well as passes data to another program (the OS).

I already took care of the initrd entry thing at menu.lst you mentioned. Working from memory, I also took out all the leading "/" characters after the "=" signs that appear at the kernel line. Now my entries look like this:

# 7) Linux bootable partition config begins
  title Damn Small Linux frugal in sda2 dir dsl
  rootnoverify (hd0,1)
  kernel /dsl/linux24 fromhd=dev/sda2 home=dsl restore=dsl root=dsl ro lang=us frugal sata
  initrd /dsl/minirt24.gz
# Linux bootable partition config ends

If it keeps doing a partial boot up I'm planning to insert little modifications to the kernel line (making annotations of what I'm doing) and, in the case something different happens, I'll post that here.

One of the first things I'm considering to eliminate is that of "fromhd=dev/sda2", starting with its 'dev/' part.

Modification (Edit): After deleting each at a time [dev/ - fromhd=sda2 - restore=dsl - home=dsl] I always ended up with that limited dsl console version. Strange things indeed happen!

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 30, 2013, 07:24:13 AM
OK, let's try a different tact. Let me walk you through your menu.lst...

The first command to GRUB is "rootnoverify" which sets the active partition to (hd0,1). This is good.

Now we have that "ide1" thing which isn't a GRUB command (http://www.gnu.org/software/grub/manual/legacy/Commands.html#Commands). It is meant for a CD booting application and I don't know how to use it in this circumstance, but it likely has no relevance to your modern laptop and certainly won't mean anything to GRUB when you specify it as a command. Leave it out.

Now the kernel line which seems to have been the source of much confusion. "/dsl/linux24" is good, as long as "linux24" is a file located in the "/dsl" directory on the partition (normally it would be in a directory named "boot" or in "boot/isolinux/", but it makes no difference). Drop "fromhd=" as it relates to booting from a cd image which I don't believe you are trying to do. considering all the problems you're having, probably best to leave "home=" and "restore=" out for now too (they should state the drive sda2 though). Root should be back to "/dev/sda2/dsl", you could try the more standard "/dev/sda2", but this would probably create a lot of DSL folders in the "/" directory where you don't seem to want them. I don't know what "ro" does, it isn't in the list on the Wiki or in the default DSL "menu.lst", so I'd leave it out for now at least. "lang=us" is the default anyway, so this is a waste of bits and might as well be removed. "frugal", well yes, then "sata" which I told you to put there.

If you decide to use "/" as the root and therefore make the "root=" command read "root=/dev/sda2", add "knoppix_dir=dsl/KNOPPIX" to the kernel line so that Linux still knows where the KNOPPIX directory is.

The initrd line looks good now, as long as the file "minirt24.gz" is in the "/dsl" directory (again it would normally be in "/boot", or in this case case "/dsl/boot".

As I said before, I'm not 100% sure the "makeactive" command is required, but it won't hurt.

Of course there is nothing wrong with "boot", let's just hope it does.

Seeing as the contents of the "boot" directory are in the root "/dsl" directory, I do suppose that the KNOPPIX directory is inside /dsl with the file KNOPPIX inside it, eg. /dsl/KNOPPIX/KNOPPIX? Otherwise you will need to use the commands "knoppix_dir=" and "knoppix_name=" to tell it where the KNOPPIX file is (or better yet just put it where its meant to be).

How about opening a terminal when running Puppy and changing to the "/dsl" directory, then doing "ls -R" and posting the output? That would show how your DSL files are arranged in case it isn't the way DSL that expects.

EDIT- To clarify, this is the menu.lst entry I am suggesting (as long as the directory structure is mostly normal):
 title Damn Small Linux frugal in sda2 dir dsl
  rootnoverify (hd0,1)
  kernel /dsl/linux24 root=/dev/sda2/dsl frugal sata
  initrd /dsl/minirt24.gz

Simple, isn't it?

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on July 30, 2013, 03:51:58 PM
Right now I'm running with PL528 &, when I changed/introduce that line starting with "ide", I must have been using probably another distro, so I didn't find in my web-history anything in relation to the page where I took that advise from. In any case I put it there because it was stated that certain VAIO laptops required this.

I also went to the site you specified for grubs' manual & browsed extensively but failed to see anything in relation to the above. I bookmarked the page for later study. I did removed the entry from menu.lst.

In relation to the "fromhd" part, I do have an iso file at sda5 which I might try to boot as a cd image (newest DSL version, if I'm not wrong). But I won't do it, for now.

I re-introduced the changes you propose after previously deleting them, one by one. I'll show my final menu.lst file below (I re-checked the paths to the required files & they seem to be correct):

# 7) Linux bootable partition config begins
  title Damn Small Linux frugal in sda2 dir dsl
  rootnoverify (hd0,1)
  kernel /dsl/linux24 root=/dev/sda2 knoppix_dir=dsl/KNOPPIX knoppix_name=dsl/KNOPPIX/KNOPPIX frugal sata #home=dsl restore=dsl  ro
  initrd /dsl/minirt24.gz
# Linux bootable partition config ends

Now, my area of interest looks like this:

.     automake     dev     initrd     lost+found     opt     root     selinux     tmp     var
..     bin     etc     lib     mnt     proc     sbin     sys       usr
___.     home     sda1     sdd1     +mnt+home+puppy528-005+virtualbox-4.1.14.sfs     sda5
___..     sr0
______.     fonts     netbootmein     puppystudio     wary512_empty     general_downloads
______..     puppy511     SAVEMARK     boot     java       puppy525     Slacko-5.5.4G     dsl
______lost+found     puppy528-005     VirtualBox
_________.     german.kbd     netbootme.iso     gpxe.krn     netbootme.usb     1st-boot.bat
_________..     isolinux.bin     pendrive-bat.old     autorun.inf       isolinux.cfg     qemu
_________boot.cat       KNOPPIX       readme.txt     boot.msg     ldlinux.sys     RECYCLER
_________dsl-base-bat.old     linux24       Shortcut to EXPERIMENTO (E).lnk
_________dsl-vhd-bat.old     logo.16     syslinux.cfg     f2     minirt24.gz     variousfiles
_________f3     netbootme.dsk

In any case, the ouput from ls -R follows:

sh-4.1# ls -R
1st-boot.bat     gpxe.krn    netbootme.iso
autorun.inf     isolinux.bin    netbootme.usb
boot.cat     isolinux.cfg    pendrive-bat.old
boot.msg     KNOPPIX    qemu
dsl-base-bat.old  ldlinux.sys    readme.txt
dsl-vhd-bat.old   linux24    RECYCLER
f2        logo.16    Shortcut to EXPERIMENTO (E).lnk
f3        minirt24.gz    syslinux.cfg
german.kbd     netbootme.dsk  variousfiles


bios.bin  License     qemu.exe   sdl.dll      vgabios-cirrus.bin
fmod.dll  linux_boot.bin  qemu-img.exe   vgabios.bin

license  README-SDL.txt  readme.txt


Desktop.ini  Regv.exe

gtktetris  gtktetris-0.6.2-pup4.files  gtktetris.desktop

Hope I haven't introduced any more errors nor confusion!

Title: Re: How to boot DSL using grub - frugal?
Post by: james c on July 31, 2013, 05:32:52 AM
For whatever it's worth, here's a copy of my menu.lst that successfully boots DSL ....... and about 10 or 12 Puppy installs.

title Puppy Raring in sda8
rootnoverify (hd0,7)
kernel /pup15/vmlinuz pfix=fsck pdev1=sda8 pmedia=atahd psubdir=pup15 nosmp acpi=force nouveau.noaccel=1
initrd /pup15/initrd.gz

title DSL-frugal-base-norestore (hda8)
root (hd0,7)
kernel /boot/linux24 root=/dev/hda8 base norestore
initrd /boot/minirt24.gz

title DSL-frugal-toram-mydsl-restore (hda8)
root (hd0,7)
kernel /boot/linux24 root=/dev/hda8 toram mydsl=hda8 restore=hda8
initrd /boot/minirt24.gz

Notice that I needed to use "hda" instead of the "sda" ,that I used with Puppy, because of DSL's 2.4.X kernel.
That basic menu entry ,with the exception of different partition numbering, works with 3 different DSL installs.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on July 31, 2013, 09:34:25 AM
@james c
As he is using a SATA HDD, the device is named "sda", even in DSL.

The hash (#) on the kernel line won't stop the following commands, that only works at the beginning of a new line. You will have to delete the unneeded commands (you can always save a copy of your last menu.lst).

Your "KNOPPIX" cloop file and its directory are in the standard place, so with the kernel command "root=/dev/sda2/dsl", you shouldn't need "knoppix_dir=" and "knoppix_name=". That's assuming DSL doesn't mind running in your "dsl" directory.

You would have got the "ide1" command from the DSL WIki Boot Commands page. (http://www.damnsmalllinux.org/wiki/cheat_codes.html#Other_boot_labels)

What is the error you receive with the GRUB entry I suggested in my last post?

Title: Re: How to boot DSL using grub - frugal?
Post by: james c on July 31, 2013, 05:48:26 PM
@james c
As he is using a SATA HDD, the device is named "sda", even in DSL.

Thanks for letting me know that my DSL installs,which do happen to be on SATA drives, are not supposed to be booting.Now I need to break the bad news to my computers...... :)

Good luck to you Benny.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 01, 2013, 07:56:57 AM
Presumably you've got your BIOS set to make SATA emulate IDE HDDs. I've run DSL on at least a couple of SATA systems (in one case to reformat a bunch of SATA HDDs, so I got used to the device names) and they always get named as "sd".

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 01, 2013, 05:15:59 PM
Thanks for replying, CNK & james c!

I've failed to check out that BIOS emulation thing but I'll do at next boot. I'm glad you clarify the # usage at a grub line, I wasn't sure that it was going to work but decided to try it out in the open in hope if it wasn't used correctly someone like you would state so.

Before trying the latest changes to the menu.lst file but with the expression after the '#' still present there I received the error message: cannot find knoppix... or something very much like that.

If this fail again I've thought of examine all the possibilities, one by one, until something different happens. I'm talking about of taking each grub entry line, see what might be brought in that's new, try it until I've to jump to the next line; repeating the process all over again until all the possibilities are exausted. But for now I'm glad that I've both of you to follow...

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 02, 2013, 10:50:58 PM
Just a thought (that should really have occoured before), what file system is on your sda2 partition? ext2 and ext3 should be supported by DSL, but some other ones aren't.

If you don't know, the best way to check (as fdisk lists all Linux file systems as type "Linux") is to boot Puppy, open a terminal and type "mount". One of the lines listed should start with "/dev/sda2" and further along that line, after the word "type" your file system should be stated.

EDIT: Whoops, seems I didn't ask that before because you already mentioned it was ext3. Oh well.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 03, 2013, 03:27:27 PM
Thanks CNK! I think I should re-state, this time correctly, what the message I receive after booting dsl is: "Can't find knoppix filesystem".

After the process is complete & I'm facing that limited console, am I looking/using a limited dsl OS or this's something grub gives me as 'something to work with'? I think if it's the former then grub indeed found dsl's folder, if not then I've been confused & wrong all the time...

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 04, 2013, 02:21:12 AM
That minimal console is the kernel on its own. Most of what makes Linux is additional software that is loaded by the kernel and your kernel can't find its files to load, so all it can give you is the basic system of built-in tools used for initial loading.

In relation to the bootloader, this means that GRUB has loaded the kernel and killed itself (that's a good thing, I coudn't think of another way to put it). The problem is that the commands passed to the kernel by GRUB (reading from the "kernel" line in menu.lst, hence why I've been talking about it so much) are not being properly understood or executed thereafter. In other words the kernel can't find its files (which are in "/dsl") based on the instructions you are giving it in the "kernel" line of menu.lst.

I can think of three potential causes for this in your case:
1. Your commands in the "kernel" line are incorrect.
2. The DSL kernel can't load its files from inside a sub-directory on a partition (your "/dsl" folder).
3. The kernel can't read data on the sda2 partition (eg. due to hardware incompatibility, data corruption or use of an unsupported file system).

Unless we are both missing something major and specific to your circumstance, then the kernel lines suggested by the Wiki, "james c" and myself should be correct, which makes no. 1 less likely.

If you can boot DSL from a CD etc. (with the "sata" boot code) and read the "/dsl" folder of the sda2 partition, then it is less likely that cause no. 3 is the problem. However it could perhaps be a problem that occours only at the early boot process.

Therefore I'm afraid that cause no. 2 seems rather likely. It would be worth doing some in-depth searching with Google for people who have tried booting the 2.4 kernel in a sub-directory of a partition, in case it was a known problem that was fixed in later kernels (such as the one used by Puppy).

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 04, 2013, 03:27:02 AM
Thanks for replying CNK! Specially interesting is what you state in relation to that limited console.

I'm about to test something now so I'll edit this post later to complete it.

Edit: I decided to make some basic changes to my approach. I already shrank my Ist partition to 8 GB with the intention of putting in there DSL only (still ntfs). While reading a wiki on this they were using loadlin as a loader & a FAT32 fs & including dos there. By my part, it made me think of including at that partition, if at all advisable/possible, freedos. This last possibility restricts the possible fss that can be used there; which brings me back to what is more important to me right now: what fs is better for booting up DSL frugally? If it can hold freedos, better.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 06, 2013, 10:16:25 AM
Yep, FreeDOS with FAT32 should work and I think almost certainly in a sub-directory (have done such a thing myself with another Linux distro). Might be a good way to go.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 07, 2013, 04:33:17 PM
After having read some info at some web pages I decided to format that partition as ext2 because it was advisable for DSL. I already have there the necessary files/folders & re-configured the menu.lst file to fit these other circumstances. After booting up I ended with a "limited console only", again...

My DSL section from the grub config file is shown below:

"# 7) Linux bootable partition config begins
  title Damn Small Linux 4.4
#  frugal in sda2 dir dsl
  root (hd0,0)
#  rootnoverify (hd0,1)
  kernel /isolinux/linux24 root=/sda1/isolinux/dsl knoppix_dir=/KNOPPIX knoppix_name=KNOPPIX
#  kernel /dsl/linux24 root=/dev/sda2/dsl knoppix_dir=/dsl/KNOPPIX knoppix_name=KNOPPIX frugal sata
  initrd /isolinux/minirt24.gz
# Linux bootable partition config ends"

I also tried it after editing at boot time, with the following cut: /sda1 at the kernel line & at the 'root' entry with the same results.

I'm out of ideas now... Could things be different if I format the partition as FAT32? What if I just put the iso as it's right there only, because I've read somewhere that both, DSL can be booted up from the iso file as well as that grub can boot an iso image?

Apart from the above, and before doing anything as mentioned there, is there something you can see that could be tweaked at the menu.lst file?

Thanks CNK for your follow up with this!

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 10, 2013, 06:55:45 PM
I found near the iso file I'm using for booting DSL that I had another DSL iso ending with initrd in its name. Its' version is 1 or 2 steps behind the one I'm trying to boot now. I put it besides the other one but I think that just been sitting there won't make any diference. Nevertheless, I can extract its' contents and substitute the present one with this, that's if you think it might help on this. What do you say?

Also, is it too diferent/dificult to boot from the iso file directly? I've read that it can be done. Do you think that's a good second choice? Maybe first choice?

Thanks for any tips on this.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 11, 2013, 12:50:39 AM
So you're installing DSL in its own partition now? No more trying to make it live in harmony on the same partition as Puppy in a directory named "dsl"? Well in that case your task should be a lot easier.

Move everything from your "dsl" folder to the root directory of the sda1 partition, you might want to put "linux24" and "minirt24.gz" into a folder named "boot" so you can follow the norm. Make sure the the KNOPPIX folder is in the root directory with the KNOPPIX file inside it.

Now if your DSL partition is at sda1 and you have put the "linux24" and "minirt24.gz" files in the "/boot" directory, then the following menu.lst entry should boot DSL:
title Damn Small Linux frugal in sda1
  root (hd0,0)
  kernel /boot/linux24 root=/dev/sda1 frugal sata
  initrd /boot/minirt24.gz

If you want to boot the iso then perhaps the "fromhd" boot command might work, but it is probably only for booting from a CD (then loading an image from the HDD).

For the record, ext3 is backwards compatible with ext2, so even if DSL didn't support ext3 (which I believe it does), it should still work fine running it as an ext2 partition without need to reformat. FAT32 is definately not preferred for booting DSL and I don't know if it works at all (I may assume not).

What was wrong with booting using LoadLin, if you still want to run in the "dsl" directory on sda2?

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 11, 2013, 05:55:29 PM
Thanks for the info CNK! I already made the changes to menu.lst you mentioned. Now all that's needed is to reboot & try it...

In relation to your last paragraph I'm afraid I don't understand it. I mentioned loadlin just because I've read about it & DSL is a linux OS & because it might have some other tricks for making DSL boot on my hardware. Did I understood your point correct? Not that I'm about to start that route now; still not finished with my grub trials.

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 12, 2013, 06:35:17 AM
I thought you meant that you were going to install FreeDOS and use that to boot DSL using LoadLin. That would work better if you really want DSL on the same partition as everything else. However if that isn't especially important, then go ahead and install DSL in its own partition (sda1), as I said before it makes things a lot simpler.

Title: Re: How to boot DSL using grub - frugal?
Post by: Benny on August 12, 2013, 12:58:23 PM
Thanks very much for your support CNK!

 Now that I introduced the last changes as you mentioned above finally DSL booted up normally. I liked the desktop it shows very much, as well as the group of icons on the it. I haven't tried it fully yet & didn't make a backup, I tried it but failed to put the info it required there because I was in a hurry & had to go. Today, I'm going to try again with more calm.

I don't know if I'm going to encounter more issues in relation to DSL but if I do, do you think is better to start another thread for it/them? How should I mark this issue as SOLVED? By adding the word SOLVED to the Subject line?

Thanks again, CNK, for your great help!

Title: Re: How to boot DSL using grub - frugal?
Post by: CNK on August 13, 2013, 09:26:30 AM
Of course I'm no authority on the matter, but I certainly feel that it would be helpful to post new questions as separate topics. This makes them easier for others to find (both now and in the future), while also keeping the topics relevent to the sub-forum they are in.

As for adding "SOLVED" to the topic name, I personally wouldn't, it would be obvious that the problem is solved by simply looking at the end of the discussion. It really comes down to personal preference though, I can't imagine anyone complaining either way.

I haven't really done much with backup and restore (I usually run HDD Installations), but you should be able to set the backup location with the tool in the DSL menu under "System>Backup/Restore". You may need to add "restore=sda1" to the end of the "kernel" line in the menu.lst entry. More info can be found on the Wiki page. (http://www.damnsmalllinux.org/wiki/persistence.html)

Title: How to boot DSL using grub frugal
Post by: antiftermam on October 26, 2017, 10:04:42 PM
Repair Kali Boot after installing a new OS ex: Windows

    hello guys thanks for instructing through the boot-process repair, I wasnt unable to repair my boot for a long-time, and because I have a kali using my USB for boot, it doesnt come with grub, so to fix the boot process it should be like:
    apt-get install grub
    mount /dev/sda3 /mnt
    mount --bind /dev /mnt/dev
    mount --bind /dev/pts /mnt/dev/pts
    mount --bind /proc /mnt/proc
    mount --bind /sys /mnt/sys
    chroot /mnt
    grub-install /dev/sda

    and now reboot, thats it,
    Thanks again.
    P.S is there a way without using apt-get install grub?

Powered by SMF 1.1.20 | SMF © 2013, Simple Machines