Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

tenmiles

macrumors newbie
Original poster
Sep 27, 2010
6
0
I have a config file, /etc/my.cnf that has permissions set via the finder gui to have read/write for anyone that's an "admin". My user is an admin (turns out I'm the only user as well), but when I open this file (it's plain text) in text edit it gives me an error on save saying that I don't have permissions for the folder that it's in. I can, however, use nano via the terminal and modify the file without any issues.

I don't want to set read/write permissions on /etc to everyone, so how do I make it so TextEdit (and thus other programs having the same problem) can write to that file?
 
I have a config file, /etc/my.cnf that has permissions set via the finder gui to have read/write for anyone that's an "admin". My user is an admin (turns out I'm the only user as well), but when I open this file (it's plain text) in text edit it gives me an error on save saying that I don't have permissions for the folder that it's in. I can, however, use nano via the terminal and modify the file without any issues.

I don't want to set read/write permissions on /etc to everyone, so how do I make it so TextEdit (and thus other programs having the same problem) can write to that file?

How about entering this in Terminal:

Code:
sudo open -e /etc/my.cnf
 
Looking into it more Text Edit tries to auto save which is what it was complaining about with the directory because it wants to create a new file that is the backup which is something that my other program does as well.
 
Looking into it more Text Edit tries to auto save which is what it was complaining about with the directory because it wants to create a new file that is the backup which is something that my other program does as well.

Is there a reason why this config file needs to be in /etc? This seems like a bad location.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.