Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a file /dev/ttyS0. And every time I boot, Its file permission is changed to default (unwritable) by the system. So, i have to run chmod command every time i boot-up. How to change it's file permission permanently.

share|improve this question
    
What does it means "unwritable by the system"? Please show the output of ls -l /dev/ttyS0. –  enzotib Dec 14 '11 at 8:15
    
Why does this down vote? we use linux, isn't that mean we have freedom to set what chmod we want. –  GusDeCooL May 9 '13 at 19:46
    
@enzotib Every time reboot, the chmod back to 660 –  GusDeCooL May 9 '13 at 19:47
    
Here may answer you question: askubuntu.com/questions/58119/… –  GusDeCooL May 9 '13 at 19:49
add comment

closed as too localized by Luis Alvarado Mar 14 '13 at 16:57

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer

Changing the file permission is not a good idea. I think /dev/ttyS* are designed to be accessed by user space applications, so you dont need to make it accessible to everybody. Instead you should give permission to use the serial ports to users that need access. If I am not wrong, you can do this by adding your user to the group uucp which can be done by running the following command in the terminal:

usermod -aG uucp <you_user_name> 

If this does not solve your issue, try posting a bit more details on what you are doing. What device are you accessing and explaining how are you writing to it, and perhaps providing some code snippets will help give more specific answer.

share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.