Basic SSH Commands for Dedicated Web Host Server

ls: Show directory contents (list the names of files).
cd: Change Directory.
mkdir: Create a new folder (directory).
touch: Create a new file.
rm: Remove a file.
rm -rf * : Remove all files and directories
cat: Show contents of a file.
pwd: Show current directory (full path to where you are right now).

df -h: to check memory

cp: Copy file/folder.

mv public_html ~/ : To copy public_html, go first on this directory/home/dh_ejyi/ then run above command . Because public_html is exist in /home/dh_ejyi/

mv public_html* ~/ : To copy all files under public_html, go first on this directory/home/dh_ejyi/ then run above command . Because files of public_html is exist in /home/dh_ejyi/

To move files:
mv /home/dh_9uevtg/* /home/dh_9uevtg/

To copy files
cp -r /home/dh_9uevtg/* /home/dh_9uevtg/

To Downlad

mysqldump –opt –user=username -p –host=yourMySQLHostname –no-tablespaces dbname > nameofyourbackup.sql

Just replace the variable
username – database username
yourMySQLHostname – database hostname
dbname – database name
nameofyourbackup.sql – SQL file name you want it to be named as

mv: Move file/folder.

grep: Search for a specific phrase in file/lines.
find: Search files and directories.
vi/nano: Text editors.
history: Show last 50 used commands.
clear: Clear the terminal screen.
tar: Create & Unpack compressed archives.
wget: Download files from the internet.
du: Get file size.

cp -rp Halalbajar090421/halal/* Halalbajar090421/ : Copy all files of Halalbajar090421/halal/ into Halalbajar090421/ same like cp -rp* shop.cybers

zip -r This command will make zip folder in same directory.
unzip Unzip zip file
tar -xvf file_name.tar: Unzip tar file
tar -C /myfolder -xvf file_name.tar: Xtract to another directory

[vps52657]$ mysql -h -u ithelpdeskbabylo -p ithelpdesk_babylonit_com < babyloni_ithelpdeskp.sql

mysql -h -u ithelpdeskbabylo -p dbname < babyloni_ithelpdeskp.sql

Db Import: mysqldump –opt –user=username -p –host=yourMySQLHostname –no-tablespaces dbname > nameofyourbackup.sql

UNIX commands — Working with
UNIX commands — Working with