PDA

View Full Version : i installed knoppix on one of my drivers but now...



DimGR
04-14-2004, 02:18 AM
i did the installation sudo knoppix-installer

everything went fine. I did a reboot and it did not ask me what to load. windows or knoppix. boot loader was written on a disk and it was inserted. HOw can i boot to knoppix? i really do not like to boot off the cd everytime....


thanks

fingers99
04-14-2004, 03:28 AM
Please post your /etc/lilo.conf here, together with details of your system.

Durand Hicks
04-14-2004, 04:22 AM
What version of windows do you have and what type of partition is it residing on? LILO can't be written directly to the windows partition if it is ntfs. If fat or fat32, then all you need to do is boot your knoppix cd, mount your knoppix installation (hdb1?) and chroot to it. I'm assuming you're using win ME or earlier, and LILO is installed to your mbr. Like so:
1) Boot cd
2) Open console as root and type: mount /dev/hdx# /mnt/hdx# -o rw
3) chroot /mnt/hdx#
4) mcedit lilo.conf
5) lilo
6) mount -t vfat /dev/hda1 /mnthda1 -o rw
7) dd if=/dev/hdx# of=/mnt/hda1/bootsect.lin count=1 bs=512
8) umount /mnt/hda1
9) exit
10) umount /mnt/hdx#
11) exit or reboot
x and # is the partition letter and number of your knoppix installation. If your using nt-based OS on ntfs, you would have to transfer bootsect.lin to/from floppy, or fat/fat32 partition and edit c:\boot.ini from windows and add this to the end of the file: c:\bootsect.lin="Linux". Close file and reboot and you'll see an option to boot into linux from nt,w2k, or xp's bootloader.

HTH,

Durand

DimGR
04-14-2004, 05:27 AM
What version of windows do you have and what type of partition is it residing on? LILO can't be written directly to the windows partition if it is ntfs. If fat or fat32, then all you need to do is boot your knoppix cd, mount your knoppix installation (hdb1?) and chroot to it. I'm assuming you're using win ME or earlier, and LILO is installed to your mbr. Like so:
1) Boot cd
2) Open console as root and type: mount /dev/hdx# /mnt/hdx# -o rw
3) chroot /mnt/hdx#
4) mcedit lilo.conf
5) lilo
6) mount -t vfat /dev/hda1 /mnthda1 -o rw
7) dd if=/dev/hdx# of=/mnt/hda1/bootsect.lin count=1 bs=512
8) umount /mnt/hda1
9) exit
10) umount /mnt/hdx#
11) exit or reboot
x and # is the partition letter and number of your knoppix installation. If your using nt-based OS on ntfs, you would have to transfer bootsect.lin to/from floppy, or fat/fat32 partition and edit c:\boot.ini from windows and add this to the end of the file: c:\bootsect.lin="Linux". Close file and reboot and you'll see an option to boot into linux from nt,w2k, or xp's bootloader.

HTH,

Durand

it is winXP but before i did the hard drive installation i created new partitions on the 2nd drive and formated them as ext3 and journalised and linux swap. I also chose to have the boot loader installed on a floppy disk


i will check all the things you mentioned later and i will post the results

thanks

Durand Hicks
04-14-2004, 06:07 AM
I figured as much. For your NT system, do steps 1 > 5. Step 6 and beyond should go like this:
6) mount -t vfat /dev/fd0 /mnt/fd0 -o rw <----- to mount your floppy, this is necessary
7) dd if=/dev/hdx# of=/mnt/fd0/bootsect.lin count=1 bs=512 <--- to copy bootsect.lin to floppy
8) umount /mnt/fd0 <--- unmount floppy
9) exit
10) umount /mnt/hdx# <--- unmount linux installation
11) exit or reboot
12) Boot to windows xp and copy bootsect.lin from floppy to c:\.
13) Edit boot.ini and add this to the end:
c:\bootsect.lin="Linux", save and exit file and reboot.

DimGR
04-14-2004, 01:36 PM
What version of windows do you have and what type of partition is it residing on? LILO can't be written directly to the windows partition if it is ntfs. If fat or fat32, then all you need to do is boot your knoppix cd, mount your knoppix installation (hdb1?) and chroot to it. I'm assuming you're using win ME or earlier, and LILO is installed to your mbr. Like so:
1) Boot cd
2) Open console as root and type: mount /dev/hdx# /mnt/hdx# -o rw
3) chroot /mnt/hdx#
4) mcedit lilo.conf
5) lilo
6) mount -t vfat /dev/hda1 /mnthda1 -o rw
7) dd if=/dev/hdx# of=/mnt/hda1/bootsect.lin count=1 bs=512
8) umount /mnt/hda1
9) exit
10) umount /mnt/hdx#
11) exit or reboot
x and # is the partition letter and number of your knoppix installation. If your using nt-based OS on ntfs, you would have to transfer bootsect.lin to/from floppy, or fat/fat32 partition and edit c:\boot.ini from windows and add this to the end of the file: c:\bootsect.lin="Linux". Close file and reboot and you'll see an option to boot into linux from nt,w2k, or xp's bootloader.

HTH,

Durand





/etc/lilo.conf
bash: /etc/lilo.conf: Permission denied
root@ttyp0[knoppix]# mount /dev/hdb6 -o rw
mount: /dev/hdb6 already mounted or /mnt/hdb6 busy
mount: according to mtab, /dev/hdb6 is already mounted on /mnt/hdb6
root@ttyp0[knoppix]# chroot /mnt/hdb6
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied
bash: /dev/null: Permission denied



now what?

Durand Hicks
04-14-2004, 04:14 PM
If I'm reading your post correctly, it looks like you didn't chroot to your knoppix installation. If you can, post the contents of fdisk -l /dev/hdb > hdb.txt here. Something didn't seem right, but my list is sound. Sometimes when booting the cd, your knoppix installation is already mounted but not always. The swap partition should have been mounted unless you typed at boot:
knoppix noswap dma idebus=66 If you attempted to mount the knoppix partition and it tells you that it's already mounted then do this in a console as root:
1) umount /mnt/hdb6 <---to make sure it wasn't automounted by knoppix
2) mount -t ext3 /dev/hdb6 /mnt/hdb6 -o rw <-- to mount it correctly as read/write
3) chroot /mnt/hdb6 <--- switching to your knoppix installation you should get a new prompt as root
4) cd /etc <-- change to /etc directory where lilo.conf resides
5) mcedit lilo.conf <-- make sure root=/dev/hdb6 and boot=/dev/hdb6 is in there and save file
6) lilo <---- to create lilo bootblock in /dev/hdb6 if you see 1+0 instead of 0+1 then it's good
7) mount -t vfat /dev/fd0 /mnt/fd0 -o rw <-- mount floppy
8) dd if=/dev/hdb6 of=/mnt/fd0/bootsect.lin count=1 bs=512 <--- to transfer bootsect.lin to floppy
9) umount /mnt/fd0 <-- unmount floppy because we're done
10) exit <-- leave knoppix install
11) umount /mnt/hdb6 <-- unmount knoppix install
12 ) exit or reboot <-- leave console or just reboot computer, make sure you remove cd
The rest can be done by copying bootsect.lin from floppy to c:\ using windows xp and editing boot.ini to direct nt to boot linux.

Does that help sort it out?

Durand

DimGR
04-14-2004, 05:14 PM
If I'm reading your post correctly, it looks like you didn't chroot to your knoppix installation. If you can, post the contents of fdisk -l /dev/hdb > hdb.txt here. Something didn't seem right, but my list is sound. Sometimes when booting the cd, your knoppix installation is already mounted but not always. The swap partition should have been mounted unless you typed at boot:
knoppix noswap dma idebus=66 If you attempted to mount the knoppix partition and it tells you that it's already mounted then do this in a console as root:
1) umount /mnt/hdb6 <---to make sure it wasn't automounted by knoppix
2) mount -t ext3 /dev/hdb6 /mnt/hdb6 -o rw <-- to mount it correctly as read/write
3) chroot /mnt/hdb6 <--- switching to your knoppix installation you should get a new prompt as root
4) cd /etc <-- change to /etc directory where lilo.conf resides
5) mcedit lilo.conf <-- make sure root=/dev/hdb6 and boot=/dev/hdb6 is in there and save file
6) lilo <---- to create lilo bootblock in /dev/hdb6 if you see 1+0 instead of 0+1 then it's good
7) mount -t vfat /dev/fd0 /mnt/fd0 -o rw <-- mount floppy
8) dd if=/dev/hdb6 of=/mnt/fd0/bootsect.lin count=1 bs=512 <--- to transfer bootsect.lin to floppy
9) umount /mnt/fd0 <-- unmount floppy because we're done
10) exit <-- leave knoppix install
11) umount /mnt/hdb6 <-- unmount knoppix install
12 ) exit or reboot <-- leave console or just reboot computer, make sure you remove cd
The rest can be done by copying bootsect.lin from floppy to c:\ using windows xp and editing boot.ini to direct nt to boot linux.

Does that help sort it out?

Durand



root@ttyp0[knoppix]# fdisk -l /dev/hdb

Disk /dev/hdb: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdb2 * 2 14946 120045712+ f W95 Ext'd (LBA)
/dev/hdb5 2 12773 102591058+ 7 HPFS/NTFS
/dev/hdb6 12774 13985 9735358+ 83 Linux
/dev/hdb7 13986 14839 6859723+ b W95 FAT32
/dev/hdb8 14840 14946 859446 82 Linux swap


everything works till i get to this point:

root@ttyp0[etc]# mount -t vfat /dev/fd0 /mnt/fd0 -o rw
mount: mount point /mnt/fd0 does not exist

OErjan
04-14-2004, 06:00 PM
mkdir /mnt/fd0
that is making a directory in /mnt caled fd0, that will solve the problem you have above.
mount is basicly saying that you have no directory named fd0 in /mnt.
You could also do the comands below and get it working.

mkdir /mnt/floppy

mount -t vfat /dev/fd0 /mnt/floppy
[/code]

Durand Hicks
04-14-2004, 06:25 PM
O'Erjan,

Thanks for the assist, I appreciate it. :)

OErjan
04-14-2004, 07:06 PM
?why?
i try to help where i can, that is a common "typo" (do it myself on occasion).
if we all try to help where we can, and not expecting any thanks or rewards... try not to be patronizing or bullies, some more people might enjoy linux in the near future.
we just have to remember being humble and patient...
not all know everything, i certainly do not, but how i wish i did.
i have just 4 years of linux, so i am still new to it (in my eyes).

Durand Hicks
04-14-2004, 07:37 PM
I was thanking you for your correction, as I made a boo-boo and you stepped in to put things right. A little credit couldn't hurt, especially if it's deserved and due. I wasn't being sarcastic or anything like that, just glad you helped. Sure, I made a typo, and didn't see it, I wasn't expecting any thanks, I just wanted to make sure that I helped the op get the job done so he can enjoy linux and help spread the word. I don't know everything either, and I've started linux back in mid-january/early feb. I wound up scouring the net for any tips I could get my hands on and implementing them, so if someone else came along and wanted to do the same, at least I would be able to help in that regard, as long as I've done it before.