serial port setup - Setup
This is a discussion on serial port setup - Setup ; I posted this in comp.linux.misc before I realised it was full of
adverts for fake watches and not many genuine posts so apologies if
you have read this already.
I have an odd problem with my serial port /dev/ttyS0 on ...
-
serial port setup
I posted this in comp.linux.misc before I realised it was full of
adverts for fake watches and not many genuine posts so apologies if
you have read this already.
I have an odd problem with my serial port /dev/ttyS0 on a redhat ES 4
update 5 server.
The defaults permissions as set in /etc/udev/udev.permissions/50-
udev.permissions are;
ttyS*:root:uucp:0660
This gives me permissions on /dev/ttyS* of crw-rw---- root:uucp,
except on /dev/ttyS0, the device I want to use. It has default
permissions of crw------- root:root. Why is this? I can't see another
config file that changes these permissions.
I have a second problem with the same device. In my inittab I step
down the baud rate to 2400 using;
s0:2345
nce:/sbin/agetty 2400 ttyS0
Works fine, but sometimes the port resets itself and a couple of other
settings change. The output from stty -F /dev/ttyS0 -a shows the
following;
-cread clocal
This changes randomly or after a reboot to "cread -clocal" i.e. the
wrong way round for my needs. How do i configure this to stay as "-
clocal cread"? Another inittab entry?
Thanks for any help.
Steve
-
Re: serial port setup
Hi Steve,
I remember, from the deep dark recesses of my fading memory, that I
had a similar problem once and as I recall my problem was the use of
the /dev/ttyS0 as the console. I remember that I also needed to use
ttyS0 for something else and I couldn't. My solution was to mknod for
a /dev/console and tell inittab and others to use that. As I say, I
can't fully remember what my problem was but is in the same general
area as yours.
Chris.
-
Re: serial port setup
On Wed, 2008-03-12 at 04:01 -0700, clipper74@googlemail.com wrote:
> I posted this in comp.linux.misc before I realised it was full of
> adverts for fake watches and not many genuine posts so apologies if
> you have read this already.
>
> I have an odd problem with my serial port /dev/ttyS0 on a redhat ES 4
> update 5 server.
>
> The defaults permissions as set in /etc/udev/udev.permissions/50-
> udev.permissions are;
> ttyS*:root:uucp:0660
>
> This gives me permissions on /dev/ttyS* of crw-rw---- root:uucp,
> except on /dev/ttyS0, the device I want to use. It has default
> permissions of crw------- root:root. Why is this? I can't see another
> config file that changes these permissions.
Uh... /etc/inittab, agetty running on the device maybe? See what
you wrote below...
>
> I have a second problem with the same device. In my inittab I step
> down the baud rate to 2400 using;
> s0:2345
nce:/sbin/agetty 2400 ttyS0
>
> Works fine, but sometimes the port resets itself and a couple of other
> settings change. The output from stty -F /dev/ttyS0 -a shows the
> following;
>
> -cread clocal
>
What do people use to access the machine via the agetty running
on the serial port? Normally people would assume one device, but
there are some variables... so I'm just curious.
With regards to the stty change... my guess is that's happening
due to settings someone has for their particular login (??).
Again... just a guess (see another guess below)...
>
> This changes randomly or after a reboot to "cread -clocal" i.e. the
> wrong way round for my needs. How do i configure this to stay as "-
> clocal cread"? Another inittab entry?
So it always changes on reboot? Hmmmm... not sure.
Maybe BIOS defaults, maybe BIOS does see something attached to
the serial port and does something (some of the time)??
Might just have to put something in a startup file.... maybe
in a system wide login/logout profile to set this. My guess
is that perhaps the value depends on how the serial device
connects to the system... but again, it's just a guess.
For example a serial device that is more or less physically
bounced attached to the serial port might confuse some things.
>
> Thanks for any help.
>
> Steve