Permission and ownership change command [Linux]

Change file and directory permissions

chmod permission change command

Change the permissions of test.php. Example: Change permissions to 775

$ chmod 775 test.php

It will be changed to the following permissions.

- rwx rwx r-x
-(File)、d(directory) Ownership Group privileges Other user rights
r w x
Readable Writable Feasible
4 2 1

Change of ownership of files and directories

chown change of ownership command

Change ownership of test.php. Example: Change ownership to nginx

$ chown nginx:nginx test.php

Recommended Posts

Permission and ownership change command [Linux]
Linux command # 4
Linux command # 3
Linux command # 5
Linux command list
linux at command
Linux command <Basic 2>
Linux [directory command]
Linux server command
Linux # Command Memo 1
Linux command [read]
Linux Command Summary
[Basic] linux command
Linux [shell command]
[Linux] Command / Knowledge
My linux command
Linux command <Basic 1>
Linux command collection
Linux mkdir command
Linux command basics
[Linux] Git command
Linux (command memory)
Linux (Bash) and Windows (PowerShell) command correspondence table
OS and Linux distribution
[Linux] Volume configuration command
Linux command cheat sheet
Linux command (sequential update)
[Copy and paste OK] Basic Linux command collection [18 selections]
Linux basic command memorandum
Linux command [File operation]
[Linux] Basic command summary
Linux command for self-collection
linux command error collection 1
Linux: files and directories
Linux command line shortcut
[Linux] Change user password
linux sar command CPU usage
Studying Linux commands and frustration
CLI and Linux basic terms
Linux (about files and directories)
[Linux] tar.gz compression / decompression command
Device and Linux file system
About LINUX files and processes
Recording and playback on Linux
Easy df command on Linux
Linux file and directory permissions
Linux tar xz command memo
Grant Redash dashboard change permission
Linux Command Dictionary (for myself)
linux: create original Terminal command
[Note] Useful linux command collection
Linux command memorandum [for beginners]
Linux PC spec check command
[Linux] User / group command summary