Stay Tuned!

Subscribe to our newsletter to get our newest articles instantly!

Apps

Linux Commands – Quick Cheat Sheet

Having a quick cheat sheet is quite handy.

Manual

See the manual for command:

man

User

To find the current user:

whoami

To change the password:

passwd

To switch users:




su

To add a user:

adduser
/etc/passwd, /etc/shadow

To run as a sudo admin:

sudo [command]

Directory/File

To find the current working directory:

pwd

To change directory:




cd

cd ..

cd ~/Music
Use single tab 
Use double tab (to see the possible folder/file name)

To list the directory:

ls -la --Finding hidden folders

To create a directory:

mkdir 

To remove a directory (recursive):

rm dir-rf

Copy file:

cp

Remove file:




rm

To find the file/folder:

locate

Update the database for use in “locate” command:

updatedb 

Create a text file:

echo "Hi!" > test.txt 

To view, create, and edit file:

echo

cat

replacing vs appending (> vs >>)

touch

nano

gedit

Permission

drwxr-xr-x – first digit (d means directory, – means file), 2-4 digits – permission for owner, 5-7 digits – permission for group members, 8-10 digits – permission of other user




Change access:

chmod

chmod 777 -- Giving full access

Network

To find IP local machines:

ifconfig

To find a wireless networking interface:

iwconfig

To ping:




ping

To display and modifies the Internet-to-adapter address translation tables used by the Address in Networks and communication management:

arp 

arp -a

To monitor for connections over the network:

netstat

netstat -ano

To do route:

route

Services

To start and stop service:




services 

To spin up a web server for Python:

phyton -m SimpleHTTPServer 80 

phyton -m SimpleHTTPServer 8080

To enable or disable on boot:

systemctl 

Installing and Updating Tools

To update and upgrade:

apt-get update && apt-get upgrade

To install “git”:




apt-get install git

The End

Congratulation on reaching the end of this post. We hope we have shed some light on outlining the Linux commands – a quick cheat sheet.

We write this so that this is not a fixed article. Like in this journey, we learn as we go and re-write some parts, so please keep pinging with this article.

We also would love to hear about how you deal with the situation and what problems you might be facing. Please feel free to comment below this article or jump into our Dewachat and let us know if you have any questions we can answer!

To boost your product and service to the broader web community, you can visit our Dewalist classified website – home to 33,000+ active users and 40,000+ one year of active advertising so far. Check it out!

If you love this article or any tech posts and you would like to receive an update of this article or our latest post, please sign up for the form below:




Newsletter signup

This is a newsletter for tech, creative, gadgets, games and crypto.

Please wait...

Thank you for sign up!

Avatar

Valdy

About Author

Valdy founded Dewacorp.com, a helpdesk and IT Services provider that has taken care of nearly 40,000 customer service requests in the past 15 years - nearly 2,600 per year. He also created the growing Dewalist.com - a classified website that has close to 110,000 page views and 9,000+ user visits per month with 61,000+ yearly published ads and 47,000 active registered users. He blogs for the ever-growing Dewapost.com, a tech blog that gets around 20,000 impressions per month with 700 clicks and 10 average pages first impressions on Google Search. You can reach him on the Contact Us page, social media links below or Dewachat.com.

You may also like

Apps

Automate Repetitive Tasks on Your Computer

[This blog is migrated from our classifieds website on 18 July 2020. Previously, it has 3,759 views.] Pre-Solution There are
Apps

Why does Joomla! 1.5 use UTF-8 encoding?

Well… how about never needing to mess with encoding settings again? Ever needed to display several languages on one page