LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-08-2002, 06:58 PM   #1
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Rep: Reputation: 0
LILO Problem


I tried to set my LILO with restricted (with password) mode but it's don't work. Does it's normal that i can't do it if i boot with a diskette ? I have win2000 on my 1st HDD and RedHat 7.3 on the 2nd HDD and when i boot with my diskette, i want that it's boot on linux but i want to password my lilo. That is my lilo.conf :

prompt
timeout=50
default=DOS
boot=/dev/hdc1
map=/boot/map
install=/boot/boot.b
message=/boot/message
linear

image=/boot/vmlinuz-2.4.18-3
label=linux
password=mypasswordforsingleboot
restricted
initrd=/boot/initrd-2.4.18-3.img
read-only /* i try also without read-only */
root=/dev/hdc3

other=/dev/hda1
optional
label=DOS

If someone know ..
Thx

tifus
 
Old 07-08-2002, 07:18 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
Are you running /sbin/lilo after making the changes and saving to activate the settings ?? If not, then run it and it should make the changes.
 
Old 07-08-2002, 07:19 PM   #3
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Original Poster
Rep: Reputation: 0
yes i did lilo -v after ..
maybe because i boot with a diskette ?!
 
Old 07-08-2002, 07:35 PM   #4
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
You might need to specify where to save to.. -v is just verbose that I know of, might not do the job.. man lilo for more options..
I believe it might be the -s flag and then specify where to save and make the changes to..
 
Old 07-08-2002, 08:16 PM   #5
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
Your boot disk is probably the problem. If it was created with the mkbootdisk program, then it will ignore the lilo.conf file on your hard drive. I checked Red Hat's site and 7.3 does have the mkbootdisk program.

What you need to do is make a new boot disk with the mkbootdisk program. As root run:

uname -r
mkbootdisk --device /dev/fd0 <kernelversion>

When you run uname, it will give you the kernel version that you will need to use in the mkbootdisk program. Just substitute it for <kernelversion>. After you make the new boot disk, try it out to make sure it works.

Next, you will need to mount the boot disk so that you can edit the lilo.conf file on it. Try as root:

mount -t ext2 /dev/fd0 /mnt/floppy

I hope you have the /mnt/floppy directory. If not, then run:

mkdir /mnt/floppy

If you get an error about file type, try minix in place of ext2. If it still gives an error about file type, try vfat.

After you get it mounted, edit the lilo.conf file. If you have it mounted at /mnt/floppy, the path to the lilo.conf file would be /mnt/floppy/etc/lilo.conf. When you are done editing and saving the file, run:

/sbin/lilo -r /mnt/floppy
umount /mnt/floppy

Then try out the new disk.
 
Old 07-09-2002, 07:52 AM   #6
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Original Poster
Rep: Reputation: 0
Thx a lot linuxcool .. i'll try it in 2-3 minutes...

But is it possible that the lilo.conf stay on the computer ?

Because i'm in a school and i don't want that people in the class can get root of is computer but if the lilo.conf is in a diskette, everyone can edit it and see the password.

Because i had make a server with NIS and NFS then every workstation can login on the server but to do that; i need to mount the /home of the server on each workstation but if someone get the root on is workstation; i'll be able to do everything with the /home of everyone .... ;(

Or do you know a other secure way than NIS to log in workstation on a server ?

Thanks

tifus
 
Old 07-09-2002, 12:15 PM   #7
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Original Poster
Rep: Reputation: 0
Or someone know a other way to block lilo or single boot (or init=/bin/sh) if i boot with a diskette ?
I need to block the lilo but not put the lilo.conf on the diskette because everyone can read the password on a disquette .. ;/
 
Old 07-09-2002, 08:15 PM   #8
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
I know of one way to use the lilo.conf on the hard drive and have very little code on the floppy disk. I have used this before, but sometimes it stops working. So, you will want to make more than one disk. Edit this line in your lilo.conf file on your hard drive:

boot=/dev/hdc1

Change it to:

boot=/dev/fd0

Put a floppy disk in the drive and run /sbin/lilo. That's it. Try booting with it.
 
Old 07-10-2002, 01:40 PM   #9
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Original Poster
Rep: Reputation: 0
Hello linuxcool
it's appear to don't work ..
i had tried many time but every time it give me this error after /sbin/lilo when i want to mount my disquette :

FAT: bigus logical sector size 5376
VFS: Can't find a valid FAT filesystem on dev 02:00.

And my diskette no longer boot on linux ... it automaticly bot on windows 2000...

U know why ?? Thanks ..

tifus

Last edited by tifus; 07-10-2002 at 04:58 PM.
 
Old 07-10-2002, 08:49 PM   #10
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
I'm a little confused as to what happened. So, let's see if I can figure out what you did.

It sounds like you used the floppy disk that you use to boot with to make the new boot disk. You were supposed to use a new floppy disk to make the new boot disk.

After you make the disk, you won't be able to mount it.

It seems that the new boot floppy worked. You said that it would boot automatically into windows 2000. According to your lilo.conf file, it will boot into windows 2000 because it is the default os to boot into. This line default=DOS is what causes it to boot into windows 2000 if you don't press any keys for five seconds after the prompt appears on the screen.

If you want linux to boot up automatically instead of windows 2000, edit the line to look like this: default=linux. Then run /sbin/lilo. When you do this make sure that your boot disk is in the floppy drive.

To edit lilo.conf, you'll have to boot into linux. Boot up with the new boot floppy that you made and at the prompt on the screen, the prompt could be LILO boot: or boot:, type linux and then press <ENTER>. That should boot linux.

To make a new boot disk like the one you had before, boot up into linux. Next, get a new floppy disk and put it into the floppy drive. Then run:

uname -r
mkbootdisk --device /dev/fd0 <kernelversion>

The uname -r command will print out the kernel version number. Use that number in the mkbootdisk --device /dev/fd0 <kernelversion> command. Then reboot and see if the new boot disk works.
 
Old 07-11-2002, 08:57 AM   #11
tifus
LQ Newbie
 
Registered: Jul 2002
Posts: 11

Original Poster
Rep: Reputation: 0
ok thanks a lot
i only missed to change the default= line
It's work fine if i boot with the new floppy (i didn't see the LILO and it's boot automaticly) but if i use the other floppy ( which i create with mkbootdisk ) i can use linux single .. does it's normal ?

thx tifus
 
Old 07-11-2002, 10:16 PM   #12
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
The reason you can use linux single with mkbootdisk disk is that the lilo.conf on the floppy disk has the prompt line in it. The mkbootdisk disk is for emergency use only. Like when the other boot disk that I told you how to make doesn't work anymore. Just use the mkbootdisk disk to boot linux and make a new boot disk.

The disk I told you how to make by editing lilo.conf and running /sbin/lilo should have given you a prompt. Then when you entered linux, it should have asked for the password. If you had put the lines in lilo.conf for a password.
 
  


Reply


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
yet another lilo problem killahsmurf Slackware - Installation 6 04-23-2005 11:33 PM
Lilo vs Grub - PROBLEM with lilo nelsonnery Linux - Software 2 09-09-2004 11:09 AM
LILO problem CommandoHamster Linux - General 4 07-22-2003 11:52 AM
LiLo Installation problem ?and (GNOME and KDE problem) hitesh_linux Linux - Software 1 01-01-2002 04:56 AM
Problem with Lilo not updating (yes I ran lilo after changing the conf) webguy Linux - General 2 06-24-2001 07:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 12:40 PM.

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