 |
|
| Linux Forum Index » Linux - Slackware Forum » Automatic login CLI... |
|
Page 1 of 1 |
|
| Author |
Message |
| Handover Phist... |
Posted: Sun Oct 18, 2009 10:25 pm |
|
|
|
Guest
|
I've done this once before a few years back, but forgot how I did it
exactly. The idea is to log in on CLI, run .bashrc to start a single
prog in X with no WM.
The work flow started in /etc/inittab with (I think) rc.[45] as default. I
modified it to run a shell as a certain user, then the scripts took over
from there. I have no problem with the scripts, but as far as I can tell
agetty wont do an automatic login as $USER. I dont remember putting
mingetty on the old machine or what the hell I did in that instance.
Could /bin/sh be placed in inittab, with the restart option, in place of
a getty work? How do I specify a user if I do that?
--
There are two ways to write error-free
programs; only the third one works.
www.websterscafe.com |
|
|
| Back to top |
|
|
|
| Handover Phist... |
Posted: Mon Oct 19, 2009 8:29 am |
|
|
|
Guest
|
emmel :
Quote: Thus Handover Phist spoke:
I've done this once before a few years back, but forgot how I did it
exactly. The idea is to log in on CLI, run .bashrc to start a single
prog in X with no WM.
The work flow started in /etc/inittab with (I think) rc.[45] as default. I
modified it to run a shell as a certain user, then the scripts took over
from there. I have no problem with the scripts, but as far as I can tell
agetty wont do an automatic login as $USER. I dont remember putting
mingetty on the old machine or what the hell I did in that instance.
Could /bin/sh be placed in inittab, with the restart option, in place of
a getty work? How do I specify a user if I do that?
Inittab doesn't handle that kind of thing. Have a look at /etc/passwd -
That's where the login shells (or whatever else) are specified.
The section I was thinking of is:
# These are the standard console login getties in multiuser mode:
c1:1235:respawn:/sbin/agetty 38400 tty1 linux
c2:1235:respawn:/sbin/agetty 38400 tty2 linux
c3:1235:respawn:/sbin/agetty 38400 tty3 linux
c4:1235:respawn:/sbin/agetty 38400 tty4 linux
c5:1235:respawn:/sbin/agetty 38400 tty5 linux
c6:12345:respawn:/sbin/agetty 38400 tty6 linux
From what I remember, I removed c3-c5, and modified c1 to run a shell as
$USER instead of agetty. I dont believe the user had a password, and the
machine I'm building doesn't need one either. It wont be network
connected and is intended as a music machine playing MP3s in a little
wine shop.
--
Those aren't WINOS -- that's my JUGGLER, my AERIALIST, my SWORD
SWALLOWER, and my LATEX NOVELTY SUPPLIER!!
www.websterscafe.com |
|
|
| Back to top |
|
|
|
| emmel... |
Posted: Wed Oct 21, 2009 12:17 am |
|
|
|
Guest
|
Thus Handover Phist spoke:
Quote: emmel :
Thus Handover Phist spoke:
I've done this once before a few years back, but forgot how I did it
exactly. The idea is to log in on CLI, run .bashrc to start a single
prog in X with no WM.
The work flow started in /etc/inittab with (I think) rc.[45] as default. I
modified it to run a shell as a certain user, then the scripts took over
from there. I have no problem with the scripts, but as far as I can tell
agetty wont do an automatic login as $USER. I dont remember putting
mingetty on the old machine or what the hell I did in that instance.
Could /bin/sh be placed in inittab, with the restart option, in place of
a getty work? How do I specify a user if I do that?
Inittab doesn't handle that kind of thing. Have a look at /etc/passwd -
That's where the login shells (or whatever else) are specified.
The section I was thinking of is:
# These are the standard console login getties in multiuser mode:
c1:1235:respawn:/sbin/agetty 38400 tty1 linux
c2:1235:respawn:/sbin/agetty 38400 tty2 linux
c3:1235:respawn:/sbin/agetty 38400 tty3 linux
c4:1235:respawn:/sbin/agetty 38400 tty4 linux
c5:1235:respawn:/sbin/agetty 38400 tty5 linux
c6:12345:respawn:/sbin/agetty 38400 tty6 linux
From what I remember, I removed c3-c5, and modified c1 to run a shell as
$USER instead of agetty. I dont believe the user had a password, and the
machine I'm building doesn't need one either. It wont be network
connected and is intended as a music machine playing MP3s in a little
wine shop.
I guess that would work, but you'd always be running the shell as root.
Just tell agetty to use a different login program (with the -l option).
That should be cleaner and avoid possible pitfalls. |
|
|
| Back to top |
|
|
|
|
|
All times are GMT - 5 Hours
The time now is Sun Nov 29, 2009 4:42 am
|
|