CalKit

Chmod Calculator

Calculate Unix file permissions.

8진수 표기
755

chmod 755 filename

심볼릭 표기
rwxr-xr-x

권한 상세

소유자 (Owner)rwx - 읽기, 쓰기, 실행
그룹 (Group)r-x - 읽기, 실행
기타 (Others)r-x - 읽기, 실행

숫자 참고

4읽기 (r)
2쓰기 (w)
1실행 (x)
7 (4+2+1)읽기+쓰기+실행
6 (4+2)읽기+쓰기
5 (4+1)읽기+실행

Overview

A calculator that converts Unix/Linux file permissions between numeric (octal) and symbolic (rwx) notation. Accurately set file permissions for server management and deployment scripts.

Formula

chmod permission calculation: For each user category (Owner/Group/Others), sum read (r=4), write (w=2), and execute (x=1) permissions. Example: rwxr-xr-- → Owner (4+2+1=7), Group (4+0+1=5), Others (4+0+0=4) → 754. Special permissions: SUID (4000), SGID (2000), Sticky (1000). Example: chmod 4755 → SUID + rwxr-xr-x.

How to Use

  1. 1Enter a numeric mode (e.g., 755) or select permissions with checkboxes.
  2. 2Set permissions for Owner, Group, and Others individually.
  3. 3Add special permissions (SUID, SGID, Sticky bit) if needed.
  4. 4View the converted numeric/symbolic notation and chmod command.

Tips

  • Standard permissions for web server files are 644 (rw-r--r--) and 755 (rwxr-xr-x) for directories.
  • Avoid 777 (all permissions granted) for security reasons.
  • Use 755 or 750 for executables and scripts.
  • The .ssh directory requires 700 and private key files require 600 for SSH to work.
  • Understanding umask values helps predict default permissions for new files/directories.

FAQ

Q. What is the difference between chmod 755 and chmod 644?

755 (rwxr-xr-x) grants read/write/execute to the owner and read/execute to group and others. It is suitable for directories and executables. 644 (rw-r--r--) grants read/write to the owner and read-only to others, suitable for regular files.

Q. What are SUID, SGID, and Sticky bit?

SUID (Set User ID): Runs with the file owner's permissions (e.g., /usr/bin/passwd). SGID (Set Group ID): Runs with the file group's permissions, or in directories, new files inherit the parent's group. Sticky bit: In directories, only the file owner can delete files (e.g., /tmp).

Q. What is umask?

umask is a mask that specifies which permissions to remove from the default permissions of newly created files/directories. For example, with umask 022, new files are created with 644 (666−022) and new directories with 755 (777−022).

Related Calculators