[SOLVED] Help with permissions for new /data partition

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
User avatar
enchance
Level 3
Level 3
Posts: 107
Joined: Mon Nov 19, 2007 3:36 am
Contact:

[SOLVED] Help with permissions for new /data partition

Post by enchance » Mon Jan 04, 2010 12:50 am

EDIT: *Made post easier to understand*

I just reinstalled Mint8 and created a /data partition for all my files. What kind of permissions should I use for it? I applied chmod -Rfv 755 /data/ (rwxr-xr-x) since all other folders in / have the same permissions, but in doing so, I have write access only to subfolders and files of /data but /data itself I have no write access.

For example, I can't make the file /data/sometext.txt or a directory /data/somedir. I'm guessing my permissions are messed up.

EDIT: I checked and saw that /home is 755, and /home/username is also 755. Difference is I have no write access in /home but I do in /home/username. Could it be that the system is telling me something?
Last edited by enchance on Mon Jan 04, 2010 1:22 am, edited 2 times in total.
It's not that hard to train a pengiun to do stunts. Just say, sudo roll-over or sudo play-dead.
Caffeine-induced designs by http://www.johnimbong.com


Image

User avatar
Fred
Level 10
Level 10
Posts: 3339
Joined: Fri Jan 04, 2008 11:59 am
Location: NC USA

Re: Help with permissions for new /data partition

Post by Fred » Mon Jan 04, 2010 1:09 am

enchance,

Read through the link below and follow the links. :-)

http://forums.linuxmint.com/viewtopic.p ... ss#p197520

Fred
Insanity: Doing the same thing over and over and each time expecting a different result.

Democracy is 2 wolves and a lamb voting on the menu. Liberty is an armed lamb protesting the electoral outcome. A Republic negates the need for an armed protest.

User avatar
enchance
Level 3
Level 3
Posts: 107
Joined: Mon Nov 19, 2007 3:36 am
Contact:

Re: Help with permissions for new /data partition

Post by enchance » Mon Jan 04, 2010 1:21 am

I got it! Apparently, I was too absentminded to see that /data is owned by root (not by myusername) which is why I can't write in it. All I did was run

Code: Select all

sudo chown -Rv myusername:myusername /data
which fixed everything.
It's not that hard to train a pengiun to do stunts. Just say, sudo roll-over or sudo play-dead.
Caffeine-induced designs by http://www.johnimbong.com


Image

rivenought
Level 5
Level 5
Posts: 779
Joined: Wed Apr 09, 2008 10:34 am

Re: [SOLVED] Help with permissions for new /data partition

Post by rivenought » Mon Jan 04, 2010 10:28 am

I have used the following with success. I am going to use your forum name in the example:

Code: Select all

sudo chown enchance.users /data
It is simple enough for me, and I have not had any problems in using the above method (as yet). I am always open to suggestions for improvements. :D

User avatar
enchance
Level 3
Level 3
Posts: 107
Joined: Mon Nov 19, 2007 3:36 am
Contact:

Re: [SOLVED] Help with permissions for new /data partition

Post by enchance » Mon Jan 04, 2010 11:35 am

rivenought wrote:I have used the following with success. I am going to use your forum name in the example:

Code: Select all

sudo chown enchance.users /data
What's enchance.users? How come there is a dot? What does it do?
It's not that hard to train a pengiun to do stunts. Just say, sudo roll-over or sudo play-dead.
Caffeine-induced designs by http://www.johnimbong.com


Image

User avatar
Fred
Level 10
Level 10
Posts: 3339
Joined: Fri Jan 04, 2008 11:59 am
Location: NC USA

Re: [SOLVED] Help with permissions for new /data partition

Post by Fred » Mon Jan 04, 2010 11:39 am

enchance wrote:
What's enchance.users? How come there is a dot? What does it do?
Nothing. It should be a colon.

Fred
Insanity: Doing the same thing over and over and each time expecting a different result.

Democracy is 2 wolves and a lamb voting on the menu. Liberty is an armed lamb protesting the electoral outcome. A Republic negates the need for an armed protest.

User avatar
enchance
Level 3
Level 3
Posts: 107
Joined: Mon Nov 19, 2007 3:36 am
Contact:

Re: [SOLVED] Help with permissions for new /data partition

Post by enchance » Mon Jan 04, 2010 12:03 pm

Fred wrote:enchance wrote:
What's enchance.users? How come there is a dot? What does it do?
Nothing. It should be a colon.

Fred
Oohh.

EDIT: This is my 100th post! Yay! :mrgreen:
It's not that hard to train a pengiun to do stunts. Just say, sudo roll-over or sudo play-dead.
Caffeine-induced designs by http://www.johnimbong.com


Image

rivenought
Level 5
Level 5
Posts: 779
Joined: Wed Apr 09, 2008 10:34 am

Re: [SOLVED] Help with permissions for new /data partition

Post by rivenought » Mon Jan 04, 2010 12:12 pm

Yeah, Fred, that is what I was meaning about any suggestions. I found that the code I pasted above as a solution shared by one of the Debian guys over in that forum.

I had originally set up one Debian Lenny machine with a /swap, /root, and a /data partition, but then could not do anything with that /data partition due to the permissions issue. I was given the above code to run, and then I had full access to that /data partition. I have seen the code written with a colon as in your suggestions, but that was after I had done my setup with the period. It does work with the period, honestly.

I just put together a Linux Mint 8 64-bit machine over the holidays and used the code with the period. It works for what I do, but maybe it does not work as good for other instances as the code with the colon. I have not tested it with extreme conditions, and I am going to look into this further.

This might just be two different ways to achieve the same result. I always like to learn new ways and options.

Post Reply

Return to “Newbie Questions”