Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Allow non-root users to write to /dev/ttyS0
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
anderiv
Tux's lil' helper
Tux's lil' helper


Joined: 29 Mar 2004
Posts: 79

PostPosted: Mon Aug 22, 2005 1:29 pm    Post subject: Allow non-root users to write to /dev/ttyS0 Reply with quote

What's the easiest way to allow non-root users to write to a serial port? I've tried using chgrp/chmod to change the permissions, but it doesn't appear that the kernel will allow you to do that. Here's my info:
    - kernel-2.6.7-gentoo-r11
    - devfsd-1.3.25-r8 (yes I know...switching to udev isn't an option on this system)

Thanks!
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Mon Aug 22, 2005 1:44 pm    Post subject: Reply with quote

AFAIK there is a "serial" group to provide this feature. Make sure youre user is in the serial group and you should be done. Or is it called "modem", no I think that was suse :roll:
Back to top
View user's profile Send private message
anderiv
Tux's lil' helper
Tux's lil' helper


Joined: 29 Mar 2004
Posts: 79

PostPosted: Mon Aug 22, 2005 2:04 pm    Post subject: Reply with quote

fangorn wrote:
AFAIK there is a "serial" group to provide this feature. Make sure youre user is in the serial group and you should be done. Or is it called "modem", no I think that was suse :roll:

Hrm - I have no serial group. There is a "tty" group, which I added my user to, but that didn't help.
Back to top
View user's profile Send private message
pmn
n00b
n00b


Joined: 25 Mar 2005
Posts: 17
Location: Helsinki

PostPosted: Mon Aug 22, 2005 4:40 pm    Post subject: Reply with quote

What is the group that is set to /dev/ttyS0 on boot? And the mode?

I mean if the mode is 660 or similiar you should be able to write to /dev/ttyS0 by adding user to that group that 'owns' this device. (Just like fangorn said).

In my gentoo system it is "tty":
Code:
root@barton ~ $ ls -la /dev/ttyS0
lrwxrwxrwx  1 root root 5 Aug 20 14:01 /dev/ttyS0 -> tts/0
root@barton ~ $ ls -la /dev/tts/0
crw-rw----  1 root tty 4, 64 Aug 20 14:01 /dev/tts/0
root@barton ~ $


After adding non-root user to group "tty" (or what it is on your system) try relogin the user.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum