How To Chown Recursively In Linux?

RSS
EMAIL
FACEBOOK
FACEBOOK
GOOGLE
GOOGLE
https://www.poftut.com/chown-recursively-linux-chown-recursive/
PINTEREST
PINTEREST
INSTAGRAM

Linux files and folders have owners. Owners are required to control permissions. Which user user can access which files. User root created file will be owned by user root. But what will happen we want to change owner.

Simply Recursively Change Files and Directories Owner User and Group

We will issue the user, group information and directory to start with recursively.

We can check new owner user and group with

We will change owner and group which is specified with ismail:ismail  in /home/ismail directory recursively. Keep in mind that to change owner user and group of files we need root privileges.

Specify File Types

While changing owner user and groups we can specify file types to recursively change.

We use find command to  find specified file type for specified path recursively and send these files as input to chown

In this example find command is searching in /home/ismail for pdf extensions and run chown command for all files it founds.

RSS
EMAIL
FACEBOOK
FACEBOOK
GOOGLE
GOOGLE
https://www.poftut.com/chown-recursively-linux-chown-recursive/
PINTEREST
PINTEREST
INSTAGRAM

LEARN MORE  Linux wc Command Word and Line Count Tutorial With Examples

Leave a Reply

Your email address will not be published.