chmod file permission codes

CHMOD File Permission codes and their usage

With the help of CHMOD file permission codes, you can manage access for yourself and other users as well. These codes follow a specific pattern or set of codes that allow you to change and update your file permission.

What are CHMOD file permission codes and how can you set them up to setup permissions for all the users and the user groups. Read more...

If you are using a Linux based web server, then it will be easy for you to apply these codes there.

As per windows, It is a different platform which does not follow any Unix based commands or rules, so changing the permission for a windows based System is a bit different.

What are CHMOD File Permission codes

In this article, we will talk about Linux based file permission codes which are usually written as the CHMOD file permission code.

Also read: 25 Must know basic Linux commands

CHMOD is simply an abbreviation of Change mode, and it is a command used for UNIX like Operating systems.

CHMOD follows this pattern to allow/disable access for different users and user groups.

How do they work

It is a combination of 3 numbers and they control these 3 aspects for users and groups.

  1. Owner or root (you)
  2. Group (user group that you set up (generally other moderators and admins))
  3. World (Anyone else who is browsing and trying to access this file)

The permissions are represented by this number system

User PermissionPermission Code
No Permission Whatsoever0
Execute1
Write2
Read4

These Permission codes now can be added to represent other types of Permissions. The following table represents the combination of these permissions.

Permission Code CombinationPermission Code
No Permission Whatsoever0
Execute Only1
Write Only2
Execute and Write Only3
Read Only4
Execute and Read Only5
Read and Write only6
Read, Write and Execute7

Whenever you add any of these 3 digits, whether you add 2 or all 3 digits, they produce a unique number. 0 disables all permission for the user and it is represented by a -.

Also Read: What is error 403 and how to fix it?

Here are some examples with related pictures:

[root@b00gi3m4n home]# chmod 143 demofile 
[root@b00gi3m4n home]# ls -la demofile 
---xr---wx. 1 boogieman root 206 Aug 16 15:35 demofile
[root@b00gi3m4n home]# 
$chmod 777 demofile #allows access to all users (read, write and execute)
$chmod 000 demofile #disable all access for all users (read write and execute)
$chmod 700 demofile #disables all access for all users except root
$chmod 644 demofile #Standard file access system for website owners

In the End

CHMOD allows you to change the file permissions for all the users including user groups. Sometimes some programs or tools start misbehaving and throwing errors here and there because of incorrect file setup. CHMOD allows you to change the file permissions according to your needs.

If you have any questions regarding this article, let me know in the comments. My team would love to help you out wih anything related to this.

Help us Grow | Share on your social Media

One Comment

  1. It’s perfect time to make some plans for the long run and it is
    time to be happy. I have read this submit and if I may just I desire to recommend you few interesting things or advice.
    Maybe you can write next articles relating to this article.

    I wish to learn even more things approximately it! Hey there!
    Someone in my Myspace group shared this website with us so I came to take a look.
    I’m definitely enjoying the information. I’m bookmarking and will be tweeting
    this to my followers! Exceptional blog and great design and style.
    I am sure this article has touched all the internet people, its really really good article
    on building up new blog. http://foxnews.net/

    Also visit my site – Jimmy

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *