File permissions (flags, CHMOD) explained

Basic command to change file permissions at UNIX based OS is 'chmod' command. The command is well executed with the set of parameters. With many FTP clients, you may just choose filename you would like to change permissions of, just right click & select chmod command. There are 3 main groups of the permissions while dealing with chmod command. Three groups are owner or yourself, the UNIX group, and else. The typical chmod command will look like - 'chmod 755' It allows you to add, remove and rename the files and edit or read the file. It as well specifies your UNIX group & everybody else can just read or edit a file in question. They cannot delete, add, or else rename a file.

How numbers in chmod command work

You will see there are three kinds of permissions that are given to the file. They’re write,read, as well as execute. Read permission is been assigned the value of four, write permission is been assigned value of two and execute permission value of one. Thus, when the chmod command specified a digit seven as first number that means all three kinds of permissions are assigned to that. If the party is assigned the value of '0' it means it has got no rights to file. 'Six' tells a server that user will read or write to a file but cannot execute that. I think that you have got an idea.

Common permissions

Most of the html files can do fine with the permission of 644. Many script files may need the permission of 755. So, any configuration files in the script package can often need the file permission of 777. Stay careful about assigning the file permission of the '777' for everybody. With the permission, it means anybody who gets access to the server can remove, add, rename, edit or read a file. It is the good idea with the security in mind for assigning least amount of the permissions essential to get a job done.

FTP client will keep things very simple

Most of the people on the shared servers may not have an access to the command line to use chmod command. For many people, changing the file permissions can be done through the FTP client. In order, to do that, right click on a file you wish to alter, and select chmod command. You may usually get the popup that can show 9 checkboxes. This can be arranged in 3 rows. On left you may generally see Read, Execute and Write for row headings. You may accomplish same thing as to type in numbers over by clicking on 1, 2 or 3 boxes for every party. When you are done, you can click on apply or the OK button and file permissions are changed. Suppose you remember that you have to always go with restrictive file permissions that allows the files to execute, and there are 3 parties for defining the permissions for, you can do fine.