Linux - NewbieThis 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!
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.
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I am using Equinox SST serial port boards on a Red Hat Enterprise 3 server. I have installed the equinox drivers, and set up the ttys in /etc/inittab with entries that look like this:
1a2:2345:respawn:/sbin/agetty 19200 ttyQ1a1 wy60
Everything works fine when you login on the serial port, and my software application also works fine. The problem is with the /dev/tty permissions for "slave" printing. My software allows for "slave" printers to be attached to the ttys so you can use the terminal, and also print through the port to an attached printer.
Before I login on any port, the permissions for the /dev/tty look like this:
crw-rw-rw- 1 root root 253, 0 Dec 9 15:33 ttyQ1a1
After I login on the port, the login program (or some other one?) changes the owner, group, and permissions on the /dev/tty file. For example, if I am user "dog" then the /dev/tty file I login on looks like this after I login:
crw--w---- 1 dog tty 253, 0 Dec 21 08:33 ttyQ1a1
Notice that the owner becomes "dog", group gets changed to "tty" and the permissions are restricted. This is a problem since any other user wishing to print to the attached printer on this tty gets a permission denied error. Well, I solved that by adding the group "tty" to all my users so that while someone is logged in it works.
The real problem though is when I log off. The /dev/tty file gets changed again to :
crw------- 1 root root 253, 0 Dec 21 08:33 ttyQ1a1
Now I am really stuck since only root can use the port. Id there any way to get login, or whatever is changing these permissions to leave things alone? Or at least put things back the way they were: