Get Raspberry Pi Commands Cheat Sheet: Finally Prepared

Raspberry Pi Commands Cheat Sheet

Get Raspberry Pi Commands Cheat Sheet: Finally Prepared

I have finally prepared some of the most useful Raspberry Pi commands cheat sheet and want to share with you today.

From its first launch in 2012 to the current date, the Raspberry Pi is the most promising single board computer in the market. It can not only work as a full-blown desktop PC but also helps you to make your own application software & manage other electronic appliances by connecting it with them remotely.

There are tons of top Raspberry Pi projects you can make with this tiny, powerful and affordable circuit board. But, many times you cannot remember all the Pi commands or have no time to search for them on the web. So having commands cheat sheet on hand is a useful thing in such conditions. Let’s see for the Raspberry Pi codes below:

Raspberry Pi Commands Cheat Sheet

I will list down some of the most common and useful Raspberry Pi commands here:

Raspberry Pi General Commands

There are certain Pi commands which can be used whenever you boot up your Raspberry Pi or between some of the codings. That does not mean you have to write them in the Raspberry Pi terminal every single time though.

apt-get update

apt-get upgrade

date (shows the current date of your system)

find / -name mandip.txt (finds the file named as mandip.txt in your system)

raspi-config (open the configuration window on your Raspberry Pi where you can change the settings of your computer including the SSH settings)

apt-get update

Raspberry Pi Shutdown Command

To power off your Pi device, enter the below command in the Raspberry Pi terminal:

poweroff

Or

shutdown –h

shutdown –h 10:05 ( to schedule the shutdown for a specific time, here at 10:05 AM)

Raspberry Pi Reboot Command

Below is the ‘Raspberry Pi Restart Command’ which will automatically shut down and then turn on the Pi setup.

reboot

Raspberry Pi Reboot Command

Raspberry Pi Terminal Command

Now, I will show some of the most fundamental Raspberry Pi terminal commands for the file system, networking, search, and other usages.

If you want to see a list of the contents of the current directory on your Raspberry Pi, then write the below command:

ls

You can use –l flag along with the above command to see additional info on the contents and –a flag to see files starting with . (Dot).

To change the directory to a particular path, write the command as stated in the example below:

cd /home/pi/directoryB

I will list down other Pi terminal commands with their examples and usages. Check it below:

  1. mkdir (mkdir mandip) – creates a new directory named as mandip.
  2. rmdir (rmdir mandip) – removes the directory ‘mandip.’
  3. rm (rm file1) – to remove a file named as ‘file1’ in the current directory
  4. mv (mv file1 file2) – cut-paste the content of file1 to file2. You can also use this command to copy-paste directory contents.
  5. cp (cp ~/file1 /home/seconduser/) – copy-paste the file to the other user from the current directory.
  6. ssh – to connect another computer with Raspberry Pi 2 through an encrypted connection. See the process to enable/disable SSH on Raspberry Pi.
  7. sudo (sudo –s) – to run the command terminal as another user.
  8. unzip – to extract a compressed zip file.

Raspberry Pi Networking Commands

Check below some of the most common networking commands for Raspberry Pi board.

  1. ping (ping raspberrypistarterkits.com) – to check the communication settings with other host. You can also use the IP address of the host rather than its name.
  2. whois abc.com – check the whois information for the domain abc.com.
  3. hostname – to check the current hostname.
  4. wget https://xyz.com/fileaddress – download the file from the web
  5. ifconfig – to show the configuration details of the network.

Raspberry Pi Desktop Commands

Once you set up your Raspberry Pi desktop, there are certain codes and shortcuts that can help you to do some tasks quite comfortably. Let’s have a look at some desktop commands and shortcuts for the Raspberry Pi device.

Raspberry Pi Desktop

In the terminal, write the command below to start the Graphical User Interface:

startx

After the GUI starts, you can use the below shortcut codes to access the features of your Raspberry Pi desktop quickly:

Raspberry Pi Desktop Shortcuts

  • ctrl + esc – to open the system menu.
  • alt + tab – to switch between different applications.
  • ctrl + q – to close the current window.
  • alt + space – to open the menu in the current program.
  • ctrl + alt + backspace – to back to Command Line Interface.
  • alt + f – to access the drop-down menu in the current application.

Download the RPi Command Cheat Sheet PDF

Download-Now-Button

Wrap Up

As I mentioned before, I have listed some of the most common and useful Raspberry Pi commands. There are numerous commands available to have secure and comfortable coding on your Raspberry Pi.

Which command do you want to know about? Do you any other useful commands than mentioned here for Pi? Hit the comment section below and share your thoughts with the world.

Leave a Reply

Your email address will not be published. Required fields are marked *