본문 바로가기
Linux/command

[Linux] chmod 명령어

by onda.cloud 2022. 3. 30.
chmod 명령어 정의

디렉토리나 파일의 권한 변경

 

chmod 명령어 사용법
chmod [option] [name]

 

option

1. 파일의 타입

2. 소유주(user)의 권한

3. 그룹(group)의 권한

4. 나머지 (others)의 권한

 

1칸에 대한 권한

d/ rwx/ r-x/ r-x

- : file

d : directory

l : other file link

p : pipe

b : block device

c : character device

 

2~4칸에 대한 권한

r : read(읽기) - 4

w : write(쓰기) - 2

x : execute(실행) - 1

- : 권한 없음 - 0

 

ex) drwxr-xr--x​

d/ rwx/ r-x/ r--x​

'Linux > command' 카테고리의 다른 글

[Linux] su 명령어  (0) 2022.03.30
[Linux] sudo 명령어  (0) 2022.03.30
[Linux] rm 명령어  (0) 2022.03.30
[Linux] pwd 명령어  (0) 2022.03.30
[Linux] mv 명령어  (0) 2022.03.30

댓글