Perlfect Solutions  
 
 

Understanding UNIX permissions and chmod

Introduction

This is a topic that has been beaten to death both in books and on-line. For some reason, it seems that it is one of the most common misunderstandings that people have to face when learning how to write and/or configure their first cgi programs. This tutorial aims to clarify the concepts involved. Note that we will be referring to UNIX in a generic sense in this article. Most of what we are going to discuss here applies to all UNIX flavours. (such as Linux, SVR4, BSD etc.) It is also a good idea to type man chmod to check for the specific details on your system, too.

Users

A UNIX system serves many users. Users are an abstraction that denotes a logical entity for assignment of ownership and operation privileges over the system. A user may correspond to a real-world person, but also a type of system operation. So, in my system, I have user 'nick' that corresponds to me, but I also have user 'www' which corresponds to the privileges necessary to operate the local webserver. UNIX doesn't care about what the user means for me. It just knows what belongs to any given user and what each user is allowed to do with any given thing (file, program, device, etc) on the system. UNIX identifies each user by a User ID (UID) and the username (or login) such as 'nick' and 'www' is just an alias to the UID that makes humans more comfortable.

Groups

Users can be organized in groups. A user may belong to one or more groups of users. The concept of groups serves the purpose of assigning sets of privileges for a given resource and sharing them among many users that need to have them. (perhaps because they are all members of a project working team and they all need access to some common project files) So, on my system user 'nick' and user 'www' both belong to the group 'perlfect'. This way, they can have some shared privileges over the files for this site. User 'nick' needs them to edit the site, and user 'www' needs them to manage the webserver that will be publishing the site.

Ownership

Every file in UNIX has an owner user and an owner group. So, for any file in the system, user 'nick' may have one of the following ownership relations:
  • nick owns the file, i.e. the file's owner is 'nick'.
  • nick is a member of the group that owns the file, i.e. the file's owner group is 'perlfect'.
  • nick is neither the owner, nor belonging to the group that owns the file

Permissions

Every file on the system has associated with it a set of permissions. Permissions tell UNIX what can be done with that file and by whom. There are three things you can (or can't) do with a given file:
  • read it,
  • write (modify) it and
  • execute it.
Unix permissions specify which of the above operations can be performed for any ownership relation with respect to the file. In simpler terms, what can the owner do, what can the owner group do, and what can everybody else do with the file. For any given ownership relation, we need three bits to specify access permissions: the first to denote read (r) access, the second to denote (w) access and the third to denote execute (x) access. We have three ownership relations: 'owner', 'group' and 'all' so we need a triplet for each, resulting in nine bits. Each bit can be set or clear. (not set) We mark a set bit by it's corresponding operation letter (r, w or x) and a clear bit by a dash (-) and put them all on a row. An example might be rwxr-xr-x.What this means is that the owner can do anything with the file, but group owners and the rest of the world can only read or execute it. Usually in UNIX there is also another bit that precedes this 9-bit pattern. You do not need to know about it, at least for the time being.

So if you try ls -l on the command prompt you will get something like the following: [nick@thekla src]$ ls -l -rwxr-xr-x 1 nick users 382 Jan 19 11:49 bscoped.pl drwxr-xr-x 3 nick users 1024 Jan 19 11:19 lib/ -rwxr-xr-x 1 nick users 1874 Jan 19 10:23 socktest.pl

The first column here shows the permission bit pattern for each file. The third column shows the owner, and the fourth column shows the owner group. By the time, the information provided by ls -l should be enough for you to figure out what each user of the system can do with any of the files in the directory.

Directories

Another interesting thing to note is that lib/ which is a directory has permissions, too. Permissions take a different meaning for directories. Here's what they mean:
  • read determines if a user can view the directory's contents, i.e. do ls in it.
  • write determines if a user can create new files or delete file in the directory. (Note here that this essentially means that a user with write access toa directory can delete files in the directory even if he/she doesn't have write permissions for the file! So be careful with this.)
  • execute determines if the user can cd into the directory.

chmod

To set/modify a file's permissions you need to use the chmod program. Of course, only the owner of a file may use chmod to alter a file's permissions. chmod has the following syntax: chmod [options] mode file(s)

The 'mode' part specifies the new permissions for the file(s) that follow as arguments. A mode specifies which user's permissions should be changed, and afterwards which access types should be changed. Let's say for example: chmod a-x socktest.pl This means that the execute bit should be cleared (-) for all users. (owner, group and the rest of the world) The permissions start with a letter specifying what users should be affected by the change, this might be any of the following:
  • u the owner user
  • g the owner group
  • o others (neither u, nor g)
  • a all users
This is followed by a change instruction which consists of a +(set bit) or -(clear bit) and the letter corresponding to the bit that should be changed.

Let's see some examples: $ ls -l socktest.pl -rwxr-xr-x 1 nick users 1874 Jan 19 10:23 socktest.pl* $ chmod a-x socktest.pl $ ls -l socktest.pl -rw-r--r-- 1 nick users 1874 Jan 19 10:23 socktest.pl $ chmod g+w socktest.pl $ ls -l socktest.pl -rw-rw-r-- 1 nick users 1874 Jan 19 10:23 socktest.pl $ chmod ug+x socktest.pl $ ls -l socktest.pl -rwxrwxr-- 1 nick users 1874 Jan 19 10:23 socktest.pl* $ chmod ug-wx socktest.pl $ ls -l socktest.pl -r--r--r-- 1 nick users 1874 Jan 19 10:23 socktest.pl

Strange numbers...

You might have encountered things like chmod 755 somefile and of course you will be wondering what this is. The thing is, that you can change the entire permission pattern of a file in one go using one number like the one in this example. Every mode has a corresponding code number, and as we shall see there is a very simple way to figure out what number corresponds to any mode.

Every one of the three digits on the mode number corresponds to one of the three permission triplets. (u, g and o) Every permission bit in a triplet corresponds to a value: 4 for r, 2 for w, 1 for x. If the permission bit you add this value to the number of the permission triplet. If it is cleared, then you add nothing. (Some of you might notice that in fact, the number for a triplet is the octal value corresponding to the three-bit pattern - if you don't know what an octal value is, it doesn't really matter, just follow the intstructions) So if a file has rwxr-xr-x permissions we do the following calculation:

Triplet for u: rwx => 4 + 2 + 1 = 7
Triplet for g: r-x => 4 + 0 + 1 = 5
Tripler for o: r-x => 4 + 0 + 1 = 5
Which makes : 755

So, 755 is a terse way to say 'I don't mind if other people read or run this file, but only I should be able to modify it' and 777 means 'everyone has full access to this file'

Further reading...

  • It is a good idea to take a look at the manual page for chmod (you can do this with man chmod) where you will find out more details and options on how to set permissions, plus some other kinds of permissions that we avoided to discuss here for the sake of simplicity and clarity.

Comments

Your name:
Your comments:

Security check *

 

Gopi   

Posted at 12:47am on Monday, March 5th, 2007

what about the "s"

Ravi   

Posted at 1:55am on Monday, March 26th, 2007

Nice description...Really helpful...

test   

Posted at 1:38am on Thursday, April 19th, 2007

test

Ninad   

Posted at 4:12am on Thursday, April 19th, 2007

Good Post :)

Anonymous   

Posted at 4:47am on Tuesday, April 24th, 2007

Good Description for Chmod command

balu   

Posted at 5:06pm on Tuesday, May 8th, 2007

well! i want to be a gud unix programmer although i m a electronics engineer. But i am a new unix user..found this
page very helpful

Anonymous   

Posted at 6:52pm on Saturday, May 12th, 2007

thanx a bunch. This is about the simplest quickest tut on chmod i've seen yet.

Roger Graham   

Posted at 4:46am on Sunday, May 13th, 2007

I've always never bothered to look into unix permissioning (and just done a 777 instead of actually understanding what's going on behind the scenes). Thanks for writing such a clear concise tutorial which has cleared things up!! ;-)

neil   

Posted at 3:50am on Sunday, June 3rd, 2007

very simple an quick thanks

ace   

Posted at 12:33pm on Monday, June 4th, 2007

Hi
at the command prompt, I am only able to view directories. when I try to change permissions, i get 'permission denied' eventhough I am the owner and no-one else has access to my computer. No matter what command I put in, i get 'permission denied'. please help as i have run out of ideas.

thanks

ace

suraj   

Posted at 12:06am on Tuesday, June 5th, 2007

in proc file system,
what 'p' flag specifies?

waste..   

Posted at 12:09am on Tuesday, June 5th, 2007

ace,
are you logged in as root?
can you paste o/p of
#whoami
#ls -l
#df -k

waste..   

Posted at 12:15am on Tuesday, June 5th, 2007

Suraj,
p : named pipe
use by system
In computing, a named pipe (also FIFO for its behaviour) is an extension to the traditional pipe concept on Unix and Unix-like systems, and is one of the methods of inter-process communication. The concept is also found in Microsoft Windows, although the semantics differ substantially. A traditional pipe is "unnamed" because it exists anonymously and persists only for as long as the process is running. A named

Ruth   

Posted at 6:58am on Tuesday, June 12th, 2007

This is very useful. I have installed Tomcat and set User variables in .cshrc file. and when I type
$CATALINA_HOME I am getting error
/home/tomcat: Permission Denied.

I think it is Directory permissions problem.
Help please...

sm   

Posted at 3:59pm on Wednesday, June 13th, 2007

Thanks very help

-sm

wae   

Posted at 3:57pm on Saturday, June 16th, 2007

Fantastic tutorial. Much clearer than the man page.

irina   

Posted at 1:55am on Wednesday, June 27th, 2007

really useful

vks   

Posted at 2:34am on Monday, July 2nd, 2007

Its really very useful.. I was also unaware about chmod XXX. But after reading this tutorial, got the concept behind. Thanks !

ak   

Posted at 9:40pm on Monday, July 2nd, 2007

good one.. appreciate thinks like this in future too..

Deii   

Posted at 2:48am on Wednesday, July 4th, 2007

1 question> I notice the "*" suffixed at the end of the filename for certain ls command lines - the first and the penultimate line; Can shed some light on that?? [i.e. filename.pl* as opposed to filename.pl]

shankar   

Posted at 11:34pm on Wednesday, July 4th, 2007

I want to delete a file of a different owner. What permission should that different owner can give while creating that file to do the same?

shankar   

Posted at 12:08am on Thursday, July 5th, 2007

Just by giving "rwx" permissions to all users at the folder level. I am novice to unix. Thanks, if anybody made a try.

Murtaza   

Posted at 12:07pm on Saturday, July 14th, 2007

@Roger Graham - using 777 without understanding it, is really stupid, anyways glad this post has you thinking again. LOL. Sorry offense meant...

Shyam   

Posted at 10:19pm on Thursday, August 16th, 2007

It `s really helpful

Shyam   

Posted at 10:19pm on Thursday, August 16th, 2007

Good one

NP   

Posted at 7:36am on Wednesday, August 22nd, 2007

@Murtaza - nobody likes a smart arse!

Naveen Kanakam   

Posted at 11:19am on Friday, September 14th, 2007

Thanks for help..Its really great...

Sandy   

Posted at 11:38pm on Monday, September 17th, 2007

OK cool Nice info i will delete few files now

asif   

Posted at 4:59am on Tuesday, September 25th, 2007

nice one !

sriram   

Posted at 6:38am on Tuesday, September 25th, 2007

is there any other command to change the attributes(using c)

Hariharan   

Posted at 3:36am on Wednesday, October 3rd, 2007

Best one

Nilesh   

Posted at 2:08pm on Saturday, October 6th, 2007

Nice, cleared some stuff up - thanks!

Dhawal   

Posted at 4:22am on Thursday, October 11th, 2007

Great! The example cleared my doubts completely

raj   

Posted at 10:41pm on Monday, October 15th, 2007

yes 777 is used to be the way to go for me. But now i clearly understand. Thanks for making my day

rsom   

Posted at 6:04am on Tuesday, October 16th, 2007

What does the 'c' permission define for permissions, 'crw-rw-rw-'?

pete   

Posted at 7:40am on Sunday, October 21st, 2007

in reply to rsom:
'c' represents a character device e.g. a serial port or a terminal - note these process data in bits.
'b' represents a block device e.g. hard drive, cdrom etc.. these process data in blocks or bytes.
'l' represents a symbolic (soft) link as in a Windows shortcut
'd' represents directory
'-' represents a file

Daniel   

Posted at 11:12am on Sunday, October 21st, 2007

Nice Description.. it really help me..

Mikael   

Posted at 7:58pm on Friday, November 2nd, 2007

I always use 4 2 1 and just add the numbers, makes more sense for me :-)

4 2 1 read write execute and "user group world" is all you need to put into memory!

Eben   

Posted at 7:55am on Monday, November 5th, 2007

This relevant manual has cleared my previous misunderstanding about chmod. This is good

imkat   

Posted at 3:02pm on Tuesday, November 6th, 2007

rili helpful. thanks...

Ravi   

Posted at 8:36pm on Tuesday, November 6th, 2007

Simple and easy ...very good

Ben   

Posted at 12:19pm on Wednesday, November 7th, 2007

What does the 'p' mean prwxr-xr-x?
Thx

Aps   

Posted at 6:37pm on Monday, November 12th, 2007

Hi everyone
It's my first time to use unix and I am having problem. I know that I logged in as root, because when I type pwd the output is "/" ( which I know is the root). Upon logging in this was the message I've got: "/etc/profile[145]: /home/alc10513: not found". Also I cannot modify a file nor make a directory. Please help me.
Thanks.

Aidan   

Posted at 7:00am on Tuesday, November 20th, 2007

@Aps
There are two kinds of root in unix, root user and the root of the filesystem. pwd prints the current working directory (which in your case is the root of the filesystem), it doesn't tell you who you are logged in as. To find that out, type whoami.

To become root user, type sudo -s (you will need to know root's password).

If you have no home directory and you can't make a file/directory, it sounds like your user account was not setup properly. You can make a new user by becoming root (sudo -s) then typing adduser yourname (replace yourname with whatever name you want). Type man adduser for more information.

Hasan Mehmood   

Posted at 11:27pm on Wednesday, November 28th, 2007

though the topic was not complex but the way you have described the chmod command make it soooooooo easy to understand. please let me know if you have written any book on Linx/Unix. hasandirect@yahoo.com

Elle   

Posted at 4:00pm on Friday, December 7th, 2007

does anyone know how to remove the set bit from a file. For example, I want the file permissions changed form -rw-rw-r--+ to -rw-rw-r--

TPot   

Posted at 8:00pm on Tuesday, December 11th, 2007

To quote the man page on AIX (which says it better than I can):
The mode displayed with the -e flag is the same as with the -l flag, except for the addition of an 11th
character interpreted as follows:
+
Indicates a file has extended security information. For example, the file may have extended ACL, TCB, or TP attributes in the mode.

The access control information (ACL) of a file is displayed by using the aclget command.


Try the acledit command.

Jasleen   

Posted at 8:36am on Thursday, December 20th, 2007

hey, thanks it was really a great help

KMK _TESTER   

Posted at 7:58am on Friday, January 11th, 2008

Nice tutorial

Was really useful for me in real time testing

Travler   

Posted at 9:42am on Wednesday, January 23rd, 2008

HUH? :)

Jim   

Posted at 12:15pm on Wednesday, February 6th, 2008

The question I have that this and everything else I've seen on the web talks right past is "in terms of web hosting, how does a server know if I am the owner or not when using a php (or other script) to upload a file or anything else requiring permissions?" IF that could be answered in 500 words or less, that would make this a great tutorial.

Abdullah   

Posted at 7:52am on Tuesday, February 12th, 2008

This is a great page! - I'm impressed.

Abhijit   

Posted at 3:05am on Friday, February 22nd, 2008

Really nice explanation of chmod command in unix. This will definitely help me in my new project wgich is 50% based on Unix env.

Cindy   

Posted at 5:58am on Friday, February 22nd, 2008

What does the "t" in the following permission setting stand for:

drwxrwxrwt

I'm confused :o(

nico   

Posted at 2:24pm on Wednesday, February 27th, 2008

Cindy, concerning the 't' which is sticky bit I just found this at linuxforums:

If you have a look at the /tmp permissions, in most GNU/Linux distributions, you'll see the following:

clem@pluto:/$ ls -l | grep tmp
drwxrwxrwt 10 root root 4096 2006-03-10 12:40 tmp

The "t" in the end of the permissions is called the "sticky bit". It replaces the "x" and indicates that in this directory, files can only be deleted by their owners, the owner of the directory or the root superuser. This way, it is not enough for a user to have write permission on /tmp, he also needs to be the owner of the file to be able to delete it.

In order to set or to remove the sticky bit, use the following commands:

chmod +t tmp
chmod -t tmp

The url to the article:
http://www.linuxforums.org/security/file_permissions.html

asifraheman   

Posted at 11:05pm on Thursday, March 27th, 2008

Really nice explanation of chmod command in unix. This will definitely help me in my new project wgich is 50% based on Unix env.

Anonymous   

Posted at 5:52am on Monday, April 7th, 2008

Its really very nice and helpful for any beginner. It gives me not only syntax idea but also detail impelementation knowledge. Site like this are very much helpful. Thanks

Mohammed Tahir Khanooni

gyanendra verma   

Posted at 1:33pm on Thursday, April 17th, 2008

I have created a script and for user i do not have execute permission. it is -rw-r--r--
still i am able to execute the script. what could be the reason

Addagirl   

Posted at 8:40pm on Monday, April 21st, 2008

I am installing an autoresponder and need to create a htaccess file and set the following permissions:
chmod for ar.cgi to 755
chmod for config.cgi to 755
chmod for activate.cgi to 755
chmod for lite.pm to 644
chmod for the autoresponder folder to 775.

I do not know how to set this up or the proper format it sould be written in so I can upload it as an htaccess file on my web server.

Can anyone help?

John   

Posted at 5:53am on Tuesday, May 6th, 2008

Really nice explanation of chmod command in unix.very useful.

Gowtham   

Posted at 3:25pm on Thursday, May 22nd, 2008

HI,

I am having some problem with permissions. In this document, I couldnot able to find it out.

My scenario is like this.

I am having a user "nick"(home path - /home/nick) and user "stick" (home path - /home/stick).
I am having a folder folder1 in nick folder. And I want to move that folder to Stick folder.
Even though I have 777 permission to all the files for folder1 and its subfolders , I am not able to move the folder to Stick home path.

Please let me know your coments.
If it is possible , please post the reply to sen_smarty@yahoo.co.in

indrajeet   

Posted at 8:28pm on Thursday, May 22nd, 2008

really use ful
i having the problem with the permissions
i want answer if possible please send me on
sonud6208@gmail.com

Raja   

Posted at 1:53am on Monday, May 26th, 2008

Nice tutorial...

Prosenjit   

Posted at 2:46am on Tuesday, May 27th, 2008

good enough...

Neeraj   

Posted at 2:06pm on Friday, May 30th, 2008

Nice info , explained quiet beautifully.

Visakh   

Posted at 1:49am on Friday, June 6th, 2008

Very helpul. It is easy to understand. Thanks :)

Sanjeev   

Posted at 5:36am on Tuesday, June 17th, 2008

Very well explained, easy to understand basics of permission and chmod command

Jenny   

Posted at 5:48am on Wednesday, June 18th, 2008

nice work.i now understand the concept of chmod though i just started learning UNIX.wud want more materials on UNIX

Amit   

Posted at 2:29am on Monday, June 23rd, 2008

thanks a lot for such a wonderful information....

James   

Posted at 6:00am on Wednesday, June 25th, 2008

Web TemplatesIt is really impressive work. Nice work man keep it up.

Rick   

Posted at 6:02am on Wednesday, June 25th, 2008

http://www.5050webs.com...Good online source to get information about Unix..

Chendhil   

Posted at 12:58am on Monday, July 7th, 2008

Good and easy to understand.
Thanks..!

michael   

Posted at 10:00pm on Thursday, July 10th, 2008

Yes. Very good. Suggestion to sharpen up the part on ownership.

Ownership

Every file in UNIX has an owner user and an owner group. So, for any file in the system, user 'nick' _has exactly_ one of the following ownership relations:

* nick owns the file, i.e. the file's owner is 'nick'.
* nick _does not own the filem but_ is a member of the group that owns the file, i.e. the file's owner group is 'perlfect'.
* nick is neither the owner, nor belonging to the group that owns the file

(The reason this is significant is because permissions are evaluated only for the particular relation - there is no conjunction going on. For example, if a user is both the owner, and a member of the group that owns the file, but permission is r--rwx--- then the user will not have permission to execute the file.)

Sys Admin pk   

Posted at 3:12am on Friday, July 11th, 2008

this is great information for beginners.......please continue such information sharing

KalarioS   

Posted at 2:35am on Friday, July 18th, 2008

Nice article .... explains the chmod in simple english

Dinesh   

Posted at 8:40pm on Saturday, July 19th, 2008

what about the "s" here drwxr-s--- ?
how to give "S" permision to new file ?

Parveez Khan   

Posted at 10:44pm on Monday, July 21st, 2008

Thanks a lot.....

Divya   

Posted at 2:13am on Monday, July 28th, 2008

Thanx for such a nice explanation for chmod.

Divya   

Posted at 2:15am on Monday, July 28th, 2008

is there any thing called chmod a=x? what is the use of =?

barking squirrel   

Posted at 5:39pm on Sunday, August 24th, 2008

Gotta respect an author who begins an article by putting down their reader; "For some reason, it seems that it is one of the most common misunderstandings that people have ..."
So what does the 's' mean?

Drive by   

Posted at 9:22am on Thursday, August 28th, 2008

s in the place where 'x' would normally go is called the set-UID or set-groupID flag.

Drive by   

Posted at 10:07am on Thursday, August 28th, 2008

The set user ID, setuid, or SUID permission. When a file for which this permission has been set is executed, the resulting process will assume the effective user ID given to the user class.

Anonymous   

Posted at 10:09am on Thursday, August 28th, 2008

Unless you are talking about the first character...
The first character indicates the file type:

- denotes a regular file
d denotes a directory
b denotes a block special file
c denotes a character special file
l denotes a symbolic link
p denotes a named pipe
s denotes a domain socket

Sush   

Posted at 4:01am on Friday, August 29th, 2008

Hi frenz.Could any1 help me out why doesnt chmod +w filename
doesnt reflect in the write permission field for all.I mean for user,group and others.I m confused !!! Please Help Me !!! Thanks Lads !!!

Karthick   

Posted at 12:14am on Wednesday, September 10th, 2008

Useful

Karthick   

Posted at 12:20am on Wednesday, September 10th, 2008

Hi Sush.While using chmod command you should specify to whom you are setting write permission.Check with this one
chmod ugo+w ..

Mansvi   

Posted at 10:16pm on Tuesday, October 7th, 2008

"Drive by
Posted at 10:07am on Thursday, August 28th, 2008

The set user ID, setuid, or SUID permission. When a file for which this permission has been set is executed, the resulting process will assume the effective user ID given to the user class. "

Can you please elaborate it further ..?

robertsb   

Posted at 9:50am on Monday, November 17th, 2008

nice post, simplified things a bit. thx

....   

Posted at 1:09pm on Tuesday, November 18th, 2008

Meep Meep

Kalai   

Posted at 7:40am on Tuesday, December 2nd, 2008

Hi,
Though I am "auser" the owner of the directory, i'm not able to write/create a file under that directory.

>ls -ld /MEC/reports
drwxr-xr-x 88 auser emc 4096 Dec 2 13:30 /MEC/reports
>touch /MEC/reports/testfile
touch: creating `testfile': Read-only file system

This was my error. Help me out plz.

kishore   

Posted at 2:22am on Wednesday, December 3rd, 2008

this is very usefull document.

Pydi   

Posted at 2:07pm on Wednesday, December 3rd, 2008

Good .... Still there is a gap for an examples..
Thank you!!!!!!!

Anonymous   

Posted at 11:24pm on Tuesday, January 6th, 2009

Gud One..very descriptive ..... Srinivas.M

Srinivas.M   

Posted at 11:25pm on Tuesday, January 6th, 2009

Gud One..very descriptive .....

Anonymous   

Posted at 8:50am on Saturday, January 31st, 2009

marvoloeus discription

Robert   

Posted at 9:26am on Tuesday, February 24th, 2009

its great it helped a lot.visit Effective Resume for making a great unix administrator resume.

sid   

Posted at 11:09pm on Sunday, March 1st, 2009

thanks man, i'm glad that there's an alternative to professors out on the internet

Amit Pawar   

Posted at 6:23am on Monday, March 2nd, 2009

A Perfect Description........

Thanks a lot.

Simon   

Posted at 1:37pm on Tuesday, March 3rd, 2009

Someone help: which command can I use to Make the permissions so only I can read/write permissions. Everyone else is read only.

Nitin   

Posted at 9:35am on Friday, March 6th, 2009

Hey ..

How do i know what permission is there on a file ?

Eg : file_a has 755.

so, what_command file_a sud give me back 755 ?

John P   

Posted at 12:56pm on Wednesday, March 11th, 2009

I just failed a Unix test at work.. They gave us 12 things to do in UNIX and I failed.. I had to become "root" and change the permissions... Im bummed out... :-( Any good books out there on UNIX or websites??? I need all the help i can get...

mogwai   

Posted at 10:14am on Friday, March 13th, 2009

4 read
2 write
1 execute
4+1=5 or read and execute which is whats needed to list a directory.
chmod -R 755 /path/dirname
will change all files within the directory to read and execute.
that covers all you need to know about chmod.

George   

Posted at 11:13pm on Thursday, April 2nd, 2009

I am working on a shell script which needs to get the permission of a file.My requirement is:

Check the permission on a particular file.
If the file is read only , then exit
else
edit it....

Now the problem is I need the permission on a file(only the permisson and not other details) in a variable. Can anybody help me?

Thanks in advance

Senthil   

Posted at 2:03am on Saturday, April 4th, 2009

Nice Hint

Niraj   

Posted at 10:56am on Saturday, April 4th, 2009

Brief and nice description

susanne   

Posted at 8:39pm on Thursday, April 16th, 2009

Thanks for the info. I've been asked for the 'autoresponder folder - which I can't find. However, if people are still asking the question - "This is a topic that has been beaten to death both in books and on-line" - then this answer doesn't help!!!
You still haven't answered the question in 'newbie-speak'- and yes, we newbies are informed enought to even understand the terms ... oh well ...
Thanks for the info I did get. Susanne sf7272@iinet.net.au

sud   

Posted at 7:05am on Sunday, April 26th, 2009

this worked a lot for me..
thanks...

vinod kumar   

Posted at 4:31am on Wednesday, May 6th, 2009

Really it's good and clear to understand.

CNN   

Posted at 4:34am on Wednesday, May 6th, 2009

Hi,
It is very interesting and clear,such a nice explanation.

Thanks,
Naren

vinx   

Posted at 11:23pm on Sunday, May 10th, 2009

good work..thanks

Stuart Hendry   

Posted at 12:31pm on Friday, May 29th, 2009

Cool, very informative, thanks

Tony   

Posted at 8:53am on Monday, June 1st, 2009

This was very helpful
Thanks

kamal   

Posted at 8:17pm on Wednesday, July 22nd, 2009

thank..
now I undestand....

Ravi   

Posted at 2:33am on Thursday, July 30th, 2009

-r-sr-x---

what does "s" means here

Ravi   

Posted at 2:34am on Thursday, July 30th, 2009

-r-sr-x---

what does "s" means here

Ravi   

Posted at 2:34am on Thursday, July 30th, 2009

-r-sr-x---

what does "s" means here

laxmikant   

Posted at 11:25pm on Wednesday, August 19th, 2009

s in above is for user id...suppose there are two files..File one is accesible to only one i.e owner & File two is accessible to everyone..if someone who is not owner of files wants to access file two then that is available..but problem here is that if file two want some data from file one which is not possible since file one has access to only owner. This problem can solved by setting user id for file two without changing permission of file one ..chmod u+s filetwo..and this has to be done by owner of files...By this option anyone accessing file two,is considered as owner..temporarily ..and pemission is granted to read file one ...u can not access file one directly ..u have to go through file two.

J.R.   

Posted at 5:13pm on Monday, August 24th, 2009

Nice, thanks.

Pradeep   

Posted at 3:09am on Tuesday, August 25th, 2009

Thanks .. Nicely explained

Devika   

Posted at 3:35am on Friday, September 4th, 2009

Thanks A Lot! very informative

Martin   

Posted at 8:03pm on Saturday, October 24th, 2009

Very helpful, thanks.

m.noman   

Posted at 12:33pm on Monday, October 26th, 2009

how im shutdown sco open server unix shutdown any use"r account without enter in root?

Rno   

Posted at 10:58am on Wednesday, November 4th, 2009

Excellent

priyanka   

Posted at 8:27pm on Tuesday, November 17th, 2009

intresting!!!!

Amarjit   

Posted at 11:50pm on Friday, November 27th, 2009

Very nice topic. Very useful. Require more for other commanfd.

Abhisek   

Posted at 9:11pm on Monday, December 14th, 2009

Excellent. Just what I was looking for...

Anirban dutta choudhury   

Posted at 8:52am on Tuesday, December 15th, 2009

Hey this is good stuff, I like the content and also the way its presented.

Kumar.R   

Posted at 2:39am on Tuesday, December 29th, 2009

Description is very useful and understandable..

Pavan   

Posted at 2:03am on Thursday, January 7th, 2010

it's good.very helpful.

ashutosh   

Posted at 1:39am on Tuesday, January 12th, 2010

nice one..

Balasaraswathi   

Posted at 10:15pm on Tuesday, January 19th, 2010

document is understandable

vera   

Posted at 1:15pm on Thursday, January 21st, 2010

Thank you. Now I understand.

Vish   

Posted at 5:36am on Sunday, January 24th, 2010

Gud One.. Very Helpful...

hi   

Posted at 12:30am on Friday, January 29th, 2010

this is good
i wnat some clarrification abt awk and sed...

hi   

Posted at 12:30am on Friday, January 29th, 2010

this is good
i wnat some clarrification abt awk and sed...

Santosh   

Posted at 5:44am on Friday, February 5th, 2010

Very good description, kept it simple and to the point. It was very helpful.
thank you

chitransh   

Posted at 2:46am on Monday, February 8th, 2010

Why a new file get 666 permisions???where goes 111 ?????

chitransh   

Posted at 2:50am on Monday, February 8th, 2010

Why a new file get 666 permisions???where goes 111 ?????

dim   

Posted at 3:28am on Wednesday, February 17th, 2010

Thanks, helped me out!

vijaya   

Posted at 12:54pm on Wednesday, February 17th, 2010

rwx for read, write, execute but above -rwxr-xr-x what that extra r is for

Lucina   

Posted at 9:50am on Thursday, February 18th, 2010

Super articulate - thank you so very much!

ashwini   

Posted at 5:16am on Monday, March 1st, 2010

good discription.

vel   

Posted at 1:15pm on Thursday, March 4th, 2010

Good Example..

Battu   

Posted at 10:55pm on Thursday, March 4th, 2010

Awesome buddy. Great job.. keep it up.. :-). Let me know where will i get this kind of information for all related to unix stuff..! wish to learn unix completely

Battu   

Posted at 10:57pm on Thursday, March 4th, 2010

Awesome buddy. Great job.. keep it up.. :-). Let me know where will i get this kind of information for all related to unix stuff..!

Rick   

Posted at 7:11am on Wednesday, March 10th, 2010

Excellent explanation. I've read many, but this one finally made sense. Thank you!

Anonymous   

Posted at 11:25pm on Monday, March 22nd, 2010

nice but stii i have a problem because i am a new user of unix

metabolic diet   

Posted at 8:19am on Friday, March 26th, 2010

Increased Child,secretary liability join change down solution pair body soft scale head painting satisfy damage look material religious hang after food winter totally name wife true weak flower blue whether whatever slowly house lose reject figure slowly difference type represent competition persuade whatever recover beneath hear clothes my result gold official mechanism although broad no surface literature temperature liberal mine educational poor charge access election fine better effective please beside different west just crowd including mine pull central holiday regional match my user science declare slip southern criminal over different

Prashanthini R   

Posted at 11:51pm on Monday, March 29th, 2010

Really informativa and easy to understand

ray   

Posted at 3:49pm on Thursday, April 22nd, 2010

thank you so much !

Pradeep   

Posted at 7:57am on Friday, April 23rd, 2010

Hi all , Please do reply for this issue >

Query 1 : I wanna give (rw access for Team Lead) and (ro access for the Team members) "who all belong to a same group" , and the condition is i shouldn't use chmod command or a GUI , how to set the permissions ??

Query 2: What is the port number for TCP ??

Please do reply these to my email id : pradeep.kayprady@gmail.com

BURCHMaricela35   

Posted at 8:48pm on Monday, April 26th, 2010

This is good that we are able to get the lowest-rate-loans.com and this opens up new opportunities.

orub   

Posted at 9:30pm on Wednesday, April 28th, 2010

thanks very much, very helpfull.

Vladimir   

Posted at 12:05pm on Thursday, May 6th, 2010

Nice, thank you for good explanation

rakesh   

Posted at 5:37am on Saturday, May 8th, 2010

Many many thanks and regards to the author of this article. This article is really very helpful,nice and excellent. I really appreciate this article for its simple explainatio of tough and confuzing concepts of unix.

regards
Rakesh

Pieter Verb   

Posted at 9:49am on Monday, May 10th, 2010

What if I want to change only the folder permissions to executable, and not the files?
chmod -R u+x *
This changes the files to executables too.

Arun S Kumar   

Posted at 2:07am on Thursday, May 13th, 2010

Thanks for the help

DRB   

Posted at 8:16am on Monday, May 17th, 2010

@Pieter Verb
Had the same question and I think I have figured it out -- someone please correct if this is not the best way -- it worked for me:

chmod 755 */

Lokesh   

Posted at 7:29am on Wednesday, June 2nd, 2010

quite helpful!

Dev   

Posted at 6:07am on Thursday, June 3rd, 2010

Very Easy to understand and useful as well

mugi   

Posted at 10:52pm on Wednesday, June 23rd, 2010

this is what i have been looking for

AbuiEyiJean   

Posted at 4:39am on Thursday, July 1st, 2010

Simple and helpful description.

Many Thanks!

vineet chaudhary   

Posted at 2:05am on Tuesday, July 6th, 2010

thanks for providing such a user friendly tutorial.....

manoj singh   

Posted at 10:25pm on Wednesday, July 28th, 2010

I have create a user but i am not allow anothe user login my server my server login only root user ,how can check security for my server.

scorpio   

Posted at 12:17am on Thursday, August 5th, 2010

Very good explanation! Thank you.

varun   

Posted at 4:46am on Monday, August 9th, 2010

gud 1.. really helpfull... thanks

Harsh   

Posted at 7:02am on Tuesday, August 10th, 2010

good work...........

nagaraju   

Posted at 3:24am on Friday, August 20th, 2010

excellent

umair   

Posted at 5:07am on Thursday, September 9th, 2010

By far the BEST tutorial on permissions on the internet.

-cheers.

g.sudhakar   

Posted at 6:19am on Friday, September 17th, 2010

it is not cleare information ,in this file system Permissions mainly three commands ls,chmod,other so chang information

vikram   

Posted at 6:36pm on Friday, September 17th, 2010

i liked it very much

Charles   

Posted at 4:33am on Wednesday, September 29th, 2010

@Pieter Verb and @DRB
You Need To Change The Permissions on a Folder and Not on The Files Inside it.
the R attribute "chmod -R" is recursive, so the command changes the permissions of all the files and folders inside the destination, omit this attribute and it will Work !
Pretty Good Tutorial, Thank You and Keep up The Good Work

doubt   

Posted at 5:07am on Wednesday, September 29th, 2010

its helpfull, tq

test   

Posted at 11:54am on Thursday, September 30th, 2010

Gives idea on permission..thanks dude.

surendra   

Posted at 9:54pm on Thursday, October 21st, 2010

It was really helpful .Thanks for uploading this content

Prashant   

Posted at 2:06am on Friday, October 22nd, 2010

Really nice to understand

mahir azad   

Posted at 1:41am on Thursday, October 28th, 2010

good details

mahir azad   

Posted at 1:43am on Thursday, October 28th, 2010

good details

shivapriya   

Posted at 11:18pm on Thursday, October 28th, 2010

very helpfull.

i have doubt in a shell script
. ${ADW_HOME}/env/izmst.env

why there is a dot(.) before $ sign?
what is the meaning of this statement?

shivapriya   

Posted at 11:20pm on Thursday, October 28th, 2010

very helpfull.

i have doubt in a shell script
. ${ADW_HOME}/env/izmst.env

why there is a dot(.) before $ sign?
what is the meaning of this statement?

Pavan   

Posted at 5:16am on Friday, October 29th, 2010

gud explaination

Rahul   

Posted at 1:17am on Tuesday, November 9th, 2010

thanks

Vikas saini   

Posted at 10:02pm on Monday, November 15th, 2010

Really great way of description thanks yaar

hs   

Posted at 10:25pm on Thursday, November 18th, 2010

its not working

Ma Diga   

Posted at 10:30pm on Saturday, November 27th, 2010

Good job. I like articles that are basic and easy to understand.

- More Linux Articles

Anonymous   

Posted at 8:09am on Monday, November 29th, 2010

I have a worldbook westerndigital powerbook wifi'd to three computers that use it for storage AND I work off the worldbook (not my computers). What setting to I put for permissions so everyone at every computer can access, read, write, execute (including save) from and to the worldbook? I see Everyone, System and Unix use root and unix group root thing. If I have a chimod I don't know what it is or where it is or what it has to do with my question. I JUST want to know what and how to set my permissions on this worldbook thing. THanks _ Not a techie like you people. YOu can send the answer to nancy4366@hotmail.com. YES I read this article. NO, I did not understand it because I'm not computer savy like you people. Sorry. THanks for reading this. I hope someone can just tell me what to do.

Hypnogal   

Posted at 8:09am on Monday, November 29th, 2010

I have a worldbook westerndigital powerbook wifi'd to three computers that use it for storage AND I work off the worldbook (not my computers). What setting to I put for permissions so everyone at every computer can access, read, write, execute (including save) from and to the worldbook? I see Everyone, System and Unix use root and unix group root thing. If I have a chimod I don't know what it is or where it is or what it has to do with my question. I JUST want to know what and how to set my permissions on this worldbook thing. THanks _ Not a techie like you people. YOu can send the answer to nancy4366@hotmail.com. YES I read this article. NO, I did not understand it because I'm not computer savy like you people. Sorry. THanks for reading this. I hope someone can just tell me what to do.

Anonymous   

Posted at 2:49pm on Monday, November 29th, 2010

so comprehensive style in explanation. Now, it has become clear a to z of the command.

Mahin

Anonymous   

Posted at 4:08pm on Monday, November 29th, 2010

Thank you very much. Felt like learned some stuff in UNIX.

siva   

Posted at 12:22am on Thursday, December 9th, 2010

simple and nice...

siva   

Posted at 12:23am on Thursday, December 9th, 2010

simple and nice...

Laxmikant   

Posted at 2:00am on Friday, December 17th, 2010

Few more examples can be added.
e.g. the file permissions change for particular user.

Laxmikant   

Posted at 2:00am on Friday, December 17th, 2010

Few more examples can be added.
e.g. the file permissions change for particular user.

Rajendra   

Posted at 11:32pm on Friday, December 24th, 2010

Simple to understand..

Thanks!!!

raju   

Posted at 12:02am on Monday, December 27th, 2010

drwx------ 3 nick users 1024 Jan 19 11:19 xyz

how to change the permession of directory

Bhaskar   

Posted at 2:21am on Tuesday, December 28th, 2010

Excellent peace of information, thanks.

Gaurav   

Posted at 3:20am on Tuesday, January 4th, 2011

Very usefull post

Anonymous   

Posted at 11:36pm on Thursday, January 13th, 2011

hi
if any one have hp-ux fundamentals PDF please send to my id gsbaikerikar@gmail.com

regards
Gourishankar Baikerikar

Karunakar   

Posted at 2:26am on Wednesday, January 19th, 2011

Nice description with examples, very much helpful
Thanks

cimi   

Posted at 4:03am on Wednesday, January 19th, 2011

Very Helpful.

Gunjan   

Posted at 4:16am on Friday, February 11th, 2011

I am looking at a folder which makes all the information to null. The permission is "crw-rw-rw- ".
Here what "c" means..?

raghu   

Posted at 2:51pm on Friday, February 11th, 2011

thanx a lot. very informative.

Ranjana   

Posted at 7:36am on Sunday, February 20th, 2011

Thanks... I learnt about chmod well...

prof   

Posted at 9:08am on Monday, February 21st, 2011

thanx guys this is more than useful 2 me

vikas   

Posted at 4:43pm on Tuesday, February 22nd, 2011

good article

Mullaiselvan. M   

Posted at 1:48am on Saturday, March 5th, 2011

Nice and Clear,
Thanks a lot.

Hemant   

Posted at 4:47am on Tuesday, March 8th, 2011

thanks for given a easy solution. it works successfully. Thanks........

noname   

Posted at 10:31pm on Friday, March 18th, 2011

stupid chicken. your info necessary no one.
i hate this is

Ros   

Posted at 8:50am on Tuesday, March 22nd, 2011

Hello everybody.
Wicht is the chmod to -rwsr-s---???.
Many thanks.
Ros

Mtresspasser   

Posted at 10:58pm on Tuesday, March 29th, 2011

I work in office n i 4got my pwd in unix.my admin has assigned me a task 2 hack d pwd from /etc/pwd. how to do it?

Santosh Yadav   

Posted at 12:16am on Thursday, April 14th, 2011

Incase “Irreversible encryption” applied….. Can be cracked by dictionary/bruit force utilities

blackhawk   

Posted at 10:33am on Friday, April 29th, 2011

Nice Article......i never forget permissions with this explanation.thanks

Anonymous   

Posted at 8:34am on Thursday, May 5th, 2011

nice description..

Satya   

Posted at 8:35am on Thursday, May 5th, 2011

nice description..Novice can understand clearly..

Anonymous   

Posted at 3:00pm on Monday, May 9th, 2011

very nice! well done!

Atul Ranjan Shahi   

Posted at 4:25pm on Wednesday, May 25th, 2011

Its realy great!!! Thanks to help me. Keep it up.

karthick sharma   

Posted at 4:50am on Wednesday, June 1st, 2011

It was really good. thankyou..!

Spence   

Posted at 6:34am on Thursday, June 2nd, 2011

Quite helpful, thanks for the well written article.

vikram poojary   

Posted at 9:39pm on Friday, June 24th, 2011

plz let us know how assign permission to particular user in aix

robert   

Posted at 2:20am on Sunday, June 26th, 2011

in safe mode my third row is set to admin, everytime i type in my drive it says permission denied, i log in as my name, my question is i need to get my start-up window, i set my harddrive to the admin according to safe mode i want to get it back running on my name..please help

Jeeva N   

Posted at 10:25pm on Sunday, June 26th, 2011

Its very use full.. I am really like it...

neil.....   

Posted at 6:22am on Friday, July 1st, 2011

very simple understanding me.

Anonymous   

Posted at 5:22am on Wednesday, July 6th, 2011

Very good for beginners

Alexander Nemsadze   

Posted at 1:32am on Thursday, July 7th, 2011

Perfect explanations, thanks

gino The IT practitioner   

Posted at 6:11pm on Thursday, July 7th, 2011

tnx for the info...

GlobalGoodGroup   

Posted at 5:25pm on Thursday, July 14th, 2011

Global Good Linux admins, thank you for getting better at your craft. At GlobalGoodGroup.com we are connecting the worlds people and information and that is not possible without people keeping the worlds computers online. -Thankyou from JBois

Mandar   

Posted at 7:25pm on Thursday, July 14th, 2011

great doc

Sag-e-Attar Junaid Atari   

Posted at 11:49pm on Sunday, July 31st, 2011

Nice article.

Anonymous   

Posted at 11:03am on Thursday, August 4th, 2011

ajay kumar   

Posted at 3:25am on Friday, August 5th, 2011

Any one plz send me PDF for the same command chmod file permissions .

Regards,

Ajay Kumar

Evgen   

Posted at 8:42am on Sunday, August 21st, 2011

Thank You for the article, it is very good and clear for beginners in Unix.

naresh   

Posted at 7:46pm on Tuesday, August 30th, 2011

how to add user,group,owner..........and how to remove those

Humphrey   

Posted at 5:00am on Wednesday, September 21st, 2011

Very clear! Thanks.
It gave me a good description of the unix filesystem.

Hemal   

Posted at 3:02am on Wednesday, September 28th, 2011

Check the file permission :There might be file permission 777 which hacker can used it to hack it again. So, you should check the file permission and then give the correct file permission as follows:
All folder permissions should be set to 755
All files permissions should be set to 644
Files that you want to edit in the WordPress Theme editors permissions should be set to 666
Never ever use 777 for WordPress permissions

Hemal   

Posted at 3:03am on Wednesday, September 28th, 2011

Check the file permission :There might be file permission 777 which hacker can used it to hack it again. So, you should check the file permission and then give the correct file permission as follows:
All folder permissions should be set to 755
All files permissions should be set to 644
Files that you want to edit in the WordPress Theme editors permissions should be set to 666
Never ever use 777 for WordPress permissions

Anonymous   

Posted at 2:33pm on Monday, October 31st, 2011

Very well described and useful.

khan   

Posted at 8:58am on Thursday, November 3rd, 2011

help me finish my lab work ^^

Bacon   

Posted at 9:28am on Thursday, November 24th, 2011

Top banane

AieYan   

Posted at 2:14pm on Saturday, December 10th, 2011

Nice... Really Helps.. in terms of "To Do It" and "To Get It"

harsha   

Posted at 1:31am on Saturday, December 17th, 2011

good information ..its easy now

Anonymous   

Posted at 1:13pm on Saturday, December 31st, 2011

simple to understand and easy to learn. thank you.

Shweta   

Posted at 11:35pm on Thursday, January 12th, 2012

This write up is very simple and hence very helpful !
I loved it...

Aditya   

Posted at 11:16am on Friday, January 13th, 2012

Thanks for taking writing so simply, I can't explain how easy and useful this is for a starter like me.

virat   

Posted at 9:23pm on Sunday, January 15th, 2012

Very Nicely Described...Easy to understand.

qbq   

Posted at 5:52am on Monday, January 16th, 2012

Can you tell me what the dot means at the end?
-rw-rw----.
..........^

FK   

Posted at 7:50pm on Wednesday, January 25th, 2012

any one know how to check What account have 777 permission? on any server...........plz help.

FK   

Posted at 7:50pm on Wednesday, January 25th, 2012

any one know how to check What account have 777 permission? on any server...........plz help.

Lakshmi   

Posted at 2:10am on Thursday, February 2nd, 2012

Its simple and easy to understand the file permissions.

Anonymous   

Posted at 8:33am on Thursday, February 9th, 2012

nice explanation

John   

Posted at 3:15pm on Thursday, February 9th, 2012

s is the set-UID or set-groupID flag. It is used to allow a user to execute a file with the file's owner or group permissions...if you ever check back

Kevi   

Posted at 11:42pm on Wednesday, February 15th, 2012

Really a valuable description......

Kevi   

Posted at 11:43pm on Wednesday, February 15th, 2012

Really a valuable description......

OM PRAKASH   

Posted at 7:24am on Thursday, February 23rd, 2012

IT IS REALLY VERY VERY GOOD AND HELP FULL TO KNOW THE MEANING OF CHMOD WHY AND WHEN IT WILL BE REQUIRED BY THE USER AND TAKE A GOOD RESPONCE. ABOUT IT..

alfredo   

Posted at 6:21am on Monday, March 12th, 2012

mucho good tutoriale! very good

Windows Tech Support   

Posted at 11:59am on Tuesday, March 13th, 2012

Great examples, really to the point!


windows tech support

loeschg   

Posted at 8:16pm on Saturday, March 17th, 2012

5 years running and still very relevant. Thanks for taking the time to put this together.

RANA   

Posted at 7:59pm on Sunday, March 18th, 2012

so good explanation.

Asraful Sk   

Posted at 8:40am on Wednesday, March 21st, 2012

Good Description for Chmod command

POTHIREDDY   

Posted at 3:59am on Tuesday, March 27th, 2012

simply superb..and thanks for info:-)

soladmn   

Posted at 12:21am on Tuesday, April 3rd, 2012

What does Rrw-rw---- "R" means here ?

Anonymous   

Posted at 6:14am on Sunday, April 29th, 2012

Very helpful!

Jagjit   

Posted at 2:41am on Sunday, May 27th, 2012

Very effective and very helpful too.

Great Job done

printed tissue packs   

Posted at 3:48am on Monday, May 28th, 2012

hello,this post is really wonderful....it's really very intersting and informative....keep sharing....
printed tissue packs

Anonymous   

Posted at 8:38am on Saturday, June 9th, 2012

Thanks so much. this was very useful

Prashant   

Posted at 5:08am on Monday, June 11th, 2012

Nice description

Preethi   

Posted at 6:46am on Monday, June 11th, 2012

Quick Reference

veni   

Posted at 8:14am on Monday, June 18th, 2012

Very nice
thanks

Good One   

Posted at 12:31am on Wednesday, July 4th, 2012

A detailed explanation on chmod! Thanks for that.

vinee   

Posted at 10:02pm on Thursday, July 12th, 2012

good one

mike   

Posted at 9:17am on Sunday, July 15th, 2012

Thanks for making this clear. Much appreciated!

Anuj   

Posted at 11:20pm on Wednesday, July 18th, 2012

Very good article...

Anonymous   

Posted at 2:18am on Thursday, July 19th, 2012

Thanks

Praveen   

Posted at 7:01pm on Tuesday, July 24th, 2012

what is u007 means ?

richard   

Posted at 2:49am on Monday, July 30th, 2012

75%, but what about the rest.

wolf   

Posted at 11:03pm on Thursday, August 2nd, 2012

I have a directory,Its permission is 700,I want permission to enter with root changed to 777.but,Prompt me "Permission denied". This is why.
drwx------ 2 root root 0 Jul 30 14:05 gconfd-root
[root@linux3 mnt]# chmod 777 gconfd-root
chmod: changing permissions of `gconfd-root': Permission denied

vijayendra   

Posted at 7:59am on Tuesday, August 7th, 2012

nice..
thkq..

Suman   

Posted at 3:22am on Monday, August 13th, 2012

Hey Thanks! Was of very Good Help!

cvm   

Posted at 12:09pm on Wednesday, August 15th, 2012

Very good explanation for chmod command. Thank you very much

Miguel   

Posted at 11:58am on Monday, August 20th, 2012

hello blogger, i was redanig your posts on Correct Permission Problem In Suphp | Web Hosting Tutorials and i actually liked them. one issue that i noticed whilst browsing through your blog that some of the links aren't working and giving error. this makes the redanig experience a little bit bad. you have a good blog and i would request you to revise the links so that fascinated folks can get all the info they want to have. Btw are you on twitter?? i would really like to follow you and also get updates in your blog.

Fallen3000   

Posted at 7:24pm on Monday, August 20th, 2012

ok how do you enter non directories? and what does @ or + mean at the end?

Fallen3000   

Posted at 9:14pm on Monday, August 20th, 2012

ok how do you enter non directories? and what does @ or + mean at the end?

zqbzwyfuelf   

Posted at 2:00am on Tuesday, August 21st, 2012

h9cODD ufhxffxqmbny

meredith1   

Posted at 4:39pm on Wednesday, August 22nd, 2012

pretty good! thx

badbrlmkjw   

Posted at 2:20pm on Thursday, August 23rd, 2012

Pla434 gcbazxgubges

sunset   

Posted at 7:51am on Friday, August 24th, 2012

Very good post but there is an aspect to the permissions that I recently discovered and probably should be added to your otherwise excellent description. If you own a file but remove read permission for yourself, you will not be able to read the file regardless of the group and other permissions. Likewise, if you don't own a file but you belong to a group which is the group for the file, then if the group doesn't have read permission, you won't be able to read the file. Obviously the same applies to write and execute permissions.

Giri   

Posted at 3:40am on Saturday, August 25th, 2012

Thnx useful one

Giri   

Posted at 3:40am on Saturday, August 25th, 2012

Thnx useful one

Pavan Naidu   

Posted at 10:26pm on Tuesday, August 28th, 2012

hai.. simply.. good frnds..this is useful for beginners..

Naeem Khan   

Posted at 10:33pm on Thursday, September 13th, 2012

Really helpful

Kirti gupta   

Posted at 9:43pm on Saturday, September 15th, 2012

nice decription

Anonymous   

Posted at 7:56pm on Monday, September 17th, 2012

-rw-r--r--@ filename

What is the @ for in the permission

Anonymous   

Posted at 2:20pm on Monday, October 8th, 2012

What, you don't want to give a primer on binary to decimal conversion?! Yeesh, what a junk idea this chmod thing is. No wonder nobody uses Unix and Linux.

test   

Posted at 9:13pm on Friday, October 26th, 2012

test

test   

Posted at 9:13pm on Friday, October 26th, 2012

test

Neha Relwani   

Posted at 11:35am on Sunday, October 28th, 2012

What if I put the permissions as 000..wat happens??

Anonymous   

Posted at 7:33am on Thursday, November 8th, 2012

Good explanation with instances.

Anonymous   

Posted at 7:34am on Thursday, November 8th, 2012

Good explanation with instances.

Anonymous   

Posted at 4:45am on Friday, November 9th, 2012

good details

Bala   

Posted at 4:47am on Friday, November 9th, 2012

Good and needfull information.

d   

Posted at 5:07am on Thursday, November 15th, 2012

thank you very much, very helpful. i can now sleep at night

connor   

Posted at 12:27pm on Wednesday, November 28th, 2012

Im trying to use a program to find out what the permission of the user is and if it doesn't include "x" change it to include "x". Any ideas on how to approach the problem would be greatly appreciated.

Impressive   

Posted at 1:52am on Friday, November 30th, 2012

wow gold
cheap gold for wow
cheap safe wow gold

Izzy   

Posted at 10:06pm on Sunday, December 16th, 2012

This was a big help. I totally got it, thanks
I will be looking out for more of your work.
Izzy, out

Georgiaxis   

Posted at 1:03am on Monday, December 17th, 2012

p334t nidecker bindings samsung d900 price technics stereo sonic game boy restrant pute

Christinempq   

Posted at 3:48am on Wednesday, December 19th, 2012

t41 ibm wheelwriter typewriter paino lessons radio flyer movie bose panion 3 reviews puter mouse pen salesman flea tic

Anonymous   

Posted at 5:40am on Friday, January 11th, 2013

Heel verstandig dit te hebben gelezen.
Thanks W

Anonymous   

Posted at 4:27am on Tuesday, January 15th, 2013

Gives good understanding on chmod

syed   

Posted at 6:01am on Friday, January 18th, 2013

good one

syed   

Posted at 6:01am on Friday, January 18th, 2013

good one

Jonathan   

Posted at 1:38pm on Thursday, January 31st, 2013

Thank You!

billCAP   

Posted at 11:24am on Tuesday, February 19th, 2013

how can I list what directories a group has access to?

QP   

Posted at 1:34pm on Thursday, March 7th, 2013

Very helpful.

Anonymous   

Posted at 11:02am on Sunday, March 10th, 2013

good work

sandeep   

Posted at 11:37pm on Wednesday, March 13th, 2013

superbb,,

Ram   

Posted at 11:13pm on Tuesday, April 2nd, 2013

THank man ..
May be little bit clear

Pooja   

Posted at 8:31am on Sunday, June 9th, 2013

very well descriptive article..really helpful.

Anonymous   

Posted at 3:18am on Thursday, July 18th, 2013

Good explanation for chmod

Cloe   

Posted at 4:10am on Thursday, August 29th, 2013

Nice post

Cloe   

Posted at 4:10am on Thursday, August 29th, 2013

Nice post

PRIYA   

Posted at 3:55am on Saturday, August 31st, 2013

GOOD DESCRIBE

PRIYA   

Posted at 3:55am on Saturday, August 31st, 2013

GOOD DESCRIBE

learner   

Posted at 5:08pm on Wednesday, October 23rd, 2013

Very good details. Great!

ur frnd   

Posted at 4:36am on Saturday, November 16th, 2013

posted 6 Years back
and still helping ppl to learn
nice !!!!

Mike   

Posted at 2:38am on Wednesday, December 11th, 2013

Thanks, that helped clear up several problems I've been having

Rakesh   

Posted at 7:25am on Tuesday, January 21st, 2014

This is very very useful for a beginner. Thank you "perlfect"

Shweta   

Posted at 8:30am on Saturday, June 14th, 2014

Nice.

Roman   

Posted at 11:56am on Tuesday, June 17th, 2014

Nice article! Helped me developing my OS (partly unix-like).

CT   

Posted at 1:25am on Thursday, July 24th, 2014

excellent, confused me for quit while and now all cleared up!

Comments   

Posted at 4:51am on Wednesday, August 27th, 2014

very one of the three digits on the mode number corresponds to one of the three permission triplets. (u, g and o) Every permission bit in a triplet corresponds to a value: 4 for r, 2 for w, 1 for x. If the permission bit you add this value to the number of the permission triplet. If it is cleared, then you add nothing. (Some of you might notice that in fact, the number for a triplet is the octal value corresponding to the three-bit pattern - if you don't know what an octal value is, it doesn't really matter, just follow the intstructions) So if a file has rwxr-xr-x permissions we do the following calculation:
Triplet for u: rwx => 4 + 2 + 1 = 7
Triplet for g: r-x => 4 + 0 + 1 = 5
Tripler for o: r-x => 4 + 0 + 1 = 5
Which makes : 755
So, 755 is a terse way to say 'I don't mind if other people read or run this file, but only I should be able to modify it' and 777 means 'everyone has full access to this file'
Further reading...
It is a good idea to take a look at the manual page for chmod (you can do this with man chmod) where you will find out more details and options on how to set permissions, plus some other kinds of permissions that we avoided to discuss here for the sake of simplicity and clarity.

Comments   

Posted at 4:51am on Wednesday, August 27th, 2014

very one of the three digits on the mode number corresponds to one of the three permission triplets. (u, g and o) Every permission bit in a triplet corresponds to a value: 4 for r, 2 for w, 1 for x. If the permission bit you add this value to the number of the permission triplet. If it is cleared, then you add nothing. (Some of you might notice that in fact, the number for a triplet is the octal value corresponding to the three-bit pattern - if you don't know what an octal value is, it doesn't really matter, just follow the intstructions) So if a file has rwxr-xr-x permissions we do the following calculation:
Triplet for u: rwx => 4 + 2 + 1 = 7
Triplet for g: r-x => 4 + 0 + 1 = 5
Tripler for o: r-x => 4 + 0 + 1 = 5
Which makes : 755
So, 755 is a terse way to say 'I don't mind if other people read or run this file, but only I should be able to modify it' and 777 means 'everyone has full access to this file'
Further reading...
It is a good idea to take a look at the manual page for chmod (you can do this with man chmod) where you will find out more details and options on how to set permissions, plus some other kinds of permissions that we avoided to discuss here for the sake of simplicity and clarity.

tryptofame   

Posted at 2:26am on Tuesday, September 9th, 2014

thank you!

param   

Posted at 4:49am on Monday, September 15th, 2014

Good Post

Comments to date: 332.

Like it? Share it!

Hosted Perlfect Search(beta)

New
Don't have the time or the expertise to install and maintain Perlfect Search? Then our freehosted Pelrfect Search service is for you!