Chown command
Chmod
And
Chown
The use of commands
I.
Chown
Command
Purpose:
Change the owner or group of the file.
Commands are made up of words
Change owner
It's a combination.
Examples of use:
one
, change the owner of the file:
Chown jim program.c
File
Program.c
The owner of the
Jim
. As the owner
Jim
Can be used
Chmod
Command to allow or deny other users
Visit
Program.c
.
two
To change the owner of the directory:
Chown-R john:build / tmp/src
Change the directory
/ tmp/src
The owners and groups of all files in the change to users
John
And group
Build
-R
Recursively changes the owner of the specified directory and all subdirectories and files under it.
-v
Display
Chown
The work ordered to be done.
(
Eg.
Chown
-
R root:root rootfs
Set
Rootfs
The permissions and groups of the folder and its subrecords are changed to
Root
Chown
-
R liufan:liufan-desktop rootfs
Change the directory
Rootfs
The owners and groups of folders and subdirectories are changed to use the
Households
Liufan
And group
Liufan-desktop
)
Chmod
And
Chown
The use of commands
I.
Chown
Command
Purpose:
Change the owner or group of the file.
Commands are made up of words
Change owner
It's a combination.
Examples of use:
one
, change the owner of the file:
Chown jim program.c
File
Program.c
The owner of the
Jim
. As the owner
Jim
Can be used
Chmod
Command to allow or deny other users
Visit
Program.c
.
two
To change the owner of the directory:
Chown-R john:build / tmp/src
Change the directory
/ tmp/src
The owners and groups of all files in the change to users
John
And group
Build
-R
Recursively changes the owner of the specified directory and all subdirectories and files under it.
-v
Display
Chown
The work ordered to be done.
(
Eg.
Chown
-
R root:root rootfs
Set
Rootfs
The permissions and groups of the folder and its subrecords are changed to
Root
Chown
-
R liufan:liufan-desktop rootfs
Change the directory
Rootfs
The owners and groups of folders and subdirectories are changed to use the
Households
Liufan
And group
Liufan-desktop
)
Chmod
And
Chown
The use of commands
I.
Chown
Command
Purpose:
Change the owner or group of the file.
Commands are made up of words
Change owner
It's a combination.
Examples of use:
one
, change the owner of the file:
Chown jim program.c
File
Program.c
The owner of the
Jim
. As the owner
Jim
Can be used
Chmod
Command to allow or deny other users
Visit
Program.c
.
two
To change the owner of the directory:
Chown-R john:build / tmp/src
Change the directory
/ tmp/src
The owners and groups of all files in the change to users
John
And group
Build
-R
Recursively changes the owner of the specified directory and all subdirectories and files under it.
-v
Display
Chown
The work ordered to be done.
(
Eg.
Chown
-
R root:root rootfs
Set
Rootfs
The permissions and groups of the folder and its subrecords are changed to
Root
Chown
-
R liufan:liufan-desktop rootfs
Change the directory
Rootfs
The owners and groups of folders and subdirectories are changed to use the
Households
Liufan
And group
Liufan-desktop
)
Chown
Chown command
Purpose: change the owner or group of the file. The command is a combination of the word change owner.
A file is required to allow only its owner control, array and other users do not have any permissions, how should the permissions be changed?
Chmod upright RWX migmatics RWX guru RWX Mustang RWX Mustang RWX
Chmod axiomagery axiomageny, glimerglyr, glichenglywrewrewrewwwlemagomo LeiwLeix file.
What are the default permissions for root users when creating files and directories? File permissions 644 / directory permissions 755
If you set the current user's umask to 003, what are the default permissions for files and directories?
777-003
Rwx rwx rwx--- wx- rwx rwx rmuri-= 774
666-003
Rw- rw- rw---- wx-rw- rw- Rmuri-= 664