VIVEK PANDHARKAR Uncategorized Linux Console Commands For Web Developers – Tree, Find, Find & Execute

Linux Console Commands For Web Developers – Tree, Find, Find & Execute

Categories:

Linux Console Commands For Web Developers – Tree, Find, Find & Execute

Essential Commands for the web developers to know and used to set proper permissions to the file and avoid malicious attacks on the server. Also to find and remove the malicious directories and files from the server.

List all the Directories and Files to the File.
tree -a -o filestructure.txt

Find and Remove Files or Directory
find -name 'ALFA_DATA' -exec rm -r {} +

Find Directory
find -name 'ALFA_DATA' -type d

Find Files
find -name 'ALFA_DATA' -type f

Select all files and apply permission to 644
find -type f -exec chmod 644 {} +

Select all Directories and apply permission to 755
find -type d -exec chmod 755 {} +

Comments are closed.