How to Find All Files Owned by a Specific User in Unix/Linux?

You might receive an issue where you require to find all the files that are owned by a specific user.  Run the below command to find all files on the server owned by the specific users.

find / -user $USERNAME 

You need to replace $USERNAME with the exact username for which you want to search the files. However, the above command may take some time to find out the files in the entire file system. You can run the below command that will store the output in a file called users_file.txt. Files owned by the entered username will be stored in a users_files.txt file.

find / -user $USERNAME > users_files.txt

Related Articles

How to Install Tomcat 7 on Centos?

Tomcat is an open-source web server that is built in Java Servlet and JavaServer Pages...

How to Install Joomla from Softaculous in cPanel?

Joomla is an open-source and a popular CMS. It is a very easy process to build a joomla template....

How To Add A New IP Address In Virtualmin?

You can add an IP Address via Networking Module directly with virtualmean. To do this, you need...

How to install FFmpeg on CentOS7 VPS?

FFmpeg is a multimedia codex that can convert audio and video files into different formats....

How to Run Multiple PHP versions with Nginx on Ubuntu?

You can run multiple php versions on Ubuntu without any issue. You require Multiple php versions...

  • 0 Users Found This Useful

Was this answer helpful?