[OT] dedicating a runlevel for a single app
I want to dedicate a run-level to a single task such that when I boot, at the lilo prompt, I enter that runlevel number, lets say "4", and the machine will not ask for a login but only run this app. When I exit the app it will reboot. I cannot have a login prompt, just this non-graphical app running. I see that Suse has filrewall stuff setup for level-4. I can get rid of that I know. My major problem seems to be the login prompt. How do I get rid of it for only the run-level I want to use for this app? And if I find a way to do it how can I still interactivly interact with the app??? Thanks in advance -- Mark Hounschell dmarkh@cfl.rr.com
Mark Hounschell wrote:
I want to dedicate a run-level to a single task such that when I boot, at the lilo prompt, I enter that runlevel number, lets say "4", and the machine will not ask for a login but only run this app. When I exit the app it will reboot. I cannot have a login prompt, just this non-graphical app running. I see that Suse has filrewall stuff setup for level-4. I can get rid of that I know. My major problem seems to be the login prompt. How do I get rid of it for only the run-level I want to use for this app? And if I find a way to do it how can I still interactivly interact with the app???
I may be misunderstanding what you want, but you probably can put your commands in boot.local. It will run the apps before the first boot prompt occurs. I've never tried it, but you may be able to even run X programs, by a shell script in boot.local. Like startx my app shutdown -r
I'd suggest you read the documentation on "init". If you edit the /etc/inittab file and edit this block to read: 1:235:respawn:/sbin/mingetty --noclear tty1 2:235:respawn:/sbin/mingetty tty2 3:235:respawn:/sbin/mingetty tty3 4:235:respawn:/sbin/mingetty tty4 5:235:respawn:/sbin/mingetty tty5 6:235:respawn:/sbin/mingetty tty6 Then, runlevel 4 will not present you with a login prompt(only 2, 3 and 5, and level S, single user mode, of course). You may still get a remote prompt via telnet or ssh, but you have to investigate it. Remember that you need a number of daemons in your machine in order to have some services like: inet, network, NFS, printer, system logging, etc. If you use one of the runlevels for just one program, you should investigate whether you need some other services or not. Rafael
Thanks all. I believe I have enough info to to what I need. Much appreciated... -- Mark Hounschell dmarkh@cfl.rr.com
On 31 Oct, Mark Hounschell wrote:
I want to dedicate a run-level to a single task such that when I boot, at the lilo prompt, I enter that runlevel number, lets say "4", and the machine will not ask for a login but only run this app. When I exit the app it will reboot. I cannot have a login prompt, <snip>
Can I ask why you are trying to do this? What is running that requires you boot into it, then boot out? Another option would be to have an application running on a virtual terminal. There's a utility called "qlogin". I don't remember where the source is. But a Web search should find it. This utility will skip the login sequence. -- Robert Wohlfarth rjwohlfar@galaxyinternet.net "Is not life more important than food, and the body more important than clothes?" -- Matthew 6:25b
participants (4)
-
Mark Hounschell
-
Rafael E. Herrera
-
Robert Wohlfarth
-
zentara