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 |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
08-14-2004, 01:50 AM
|
#1
|
|
LQ Newbie
Registered: Aug 2004
Posts: 8
Rep:
|
shutdown option on boot
Is it possible to have an option in lilo where if Someone enters a password wrong or if too much time elapses then the computer shuts down. I'm using the settings the install put in it for me. Also I'd like to start linux in the command line and then if i want to start the Graphical mode.
|
|
|
|
08-14-2004, 05:22 AM
|
#2
|
|
Senior Member
Registered: May 2004
Location: Leipzig/Germany
Distribution: Arch
Posts: 1,684
Rep:
|
It is possible - but needs some work..
password-protecting the booting is not difficult - but it needs more setup to do, what you want - shutting the machine down after a certain time.
I don't know of an option in lilo, which counts, how many times a password can be entered and acts on that accordingly - so, what I know about this is, that it not possible to allow only 3 attempts for instance and the deny further inputs.
As for the shutting down - to do that, you will have to configure lilo to boot anyway (after a timeout - to a runlevel - which you can set up - which will immediately shut down the system without anyone being able to even attempt to log in.
This needs to be done this way, because lilo is a boot-manager - and cannot by itself shut down the system - the system has to do this.
But I'm not sure if this works together with mandatory passwords!?
try:
man lilo.conf
and/or post your /etc/lilo.conf
the options needed are:
mandatory ...and... password=<password>
and the option
restricted
has to be disabled - in favour of: mandatory
for the timed booting...
timeout=...
As for not starting in graphics-mode:
you need to disable the startup of your display-manager (xdm or kdm or gdm) - which is started via the init-scripts in /etc/rc.d or /etc/init.d/...
|
|
|
|
08-14-2004, 05:58 PM
|
#3
|
|
LQ Newbie
Registered: Aug 2004
Posts: 8
Original Poster
Rep:
|
I was told to boot into runlevel 0 for the shutdown image but i tried "append = runlevel=0" but that didn't seem to change anything (I did remember to rerun lilo to update the bootloader).
Also where do the password and manditory arguments go? I don't remember seeing them in the man pages
here's my current lilo.conf
boot = /dev/hda
compact
root = /dev/hda1
image = /zImage
label = awdr
image = zImage
label = default
append = runlevel=0
other = /dev hda3
label = zscf
other = /dev/hda4
label = qxev
|
|
|
|
08-15-2004, 03:08 AM
|
#4
|
|
Senior Member
Registered: May 2004
Location: Leipzig/Germany
Distribution: Arch
Posts: 1,684
Rep:
|
# global section
boot = /dev/hda
compact
root = /dev/hda1
# waits for input
# sets timeout to 5 minutes and then boots the default image
# which is not password-protected
prompt
timeout=3000
# per image settings
image = /zImage
label = awdr
restricted
password=<password>
image = zImage
# make this the default to boot up after timeout
default
label = turn_off_machine
# this should be correct to boot up zImage to runlevel 0
append ="init=0"
#bypass
# this may be needed in case the password is recognized as a global setting
other = /dev/hda3
label = zscf
restricted
password=<password>
other = /dev/hda4
label = qxev
restricted
password=<password>
#end /etc/lilo.conf
The default level is "mandatory" so - no need to give that...
each image which needs to be protected, gets a "restricted" and a "password=..."
the one image you want to use to shut down the machine has to be the default - I changed the name to: turn_off_machine
You could put the password option just once in the global section - if it is to be the same for all images, but then you would need the option "bypass" for the default-image - which is now commented out
...I have not tried this - I hope it will work as expected
the man-page is: man lilo.conf
|
|
|
|
08-16-2004, 12:45 AM
|
#5
|
|
LQ Newbie
Registered: Aug 2004
Posts: 8
Original Poster
Rep:
|
Works perfectly. All my security problems are now fixed.
|
|
|
|
08-16-2004, 02:32 AM
|
#6
|
|
Senior Member
Registered: May 2004
Location: Leipzig/Germany
Distribution: Arch
Posts: 1,684
Rep:
|
cool - I'm glad it worked!
|
|
|
|
08-16-2004, 02:32 AM
|
#7
|
|
Senior Member
Registered: May 2004
Location: Leipzig/Germany
Distribution: Arch
Posts: 1,684
Rep:
|
...my browser was not responding - tried to reload the page and go back and forth - and this way it got send two times - please take that out
Last edited by jomen; 08-16-2004 at 02:36 AM.
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 09:36 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|