Common Linux commands for Raspberry Pi Deian

Source: Internet
Author: User
Tags create directory

The Linux system, this powerful system, is now being used by the Raspberry Pi. For everyone to popularize a bit.

Those common Linux commands

The file structure of Linux

/directory under the root directory

/bin

/home

/dev

/usr

/opt

/etc

...

No way. To use Linux, you have to remember common Linux commands

CD < catalogue >

Enter the directory, basically the same as Dos

Ls

List files, equivalent to Dos for dir

Ls-l

Display details of files and directories

Ls-a

Show hidden files

CP < source file name > < destination file name >

Copy files, equivalent to DOS copy

MV < source file name > < destination file name >

Moving files

RM < file name >

Delete file, equivalent to Dos del

Date

Show system date

Cat < file name >

Print out the contents of the file on the screen, equivalent to the DOS type

mkdir < directory name >

Create directory, equivalent to DOS for MD

Shutdown-h now

Turn off the machine now

Pwd

Show current Path

chmod

Change file permissions

For example:

chmod +x < file name >//Make file run, run file

Sudo...

Execute command as Root

such as: sudo shutdown-h now (shutdown must be root)

sudo passwd < user name >

Modify User Password

Reboot

Reboot (must be root)

Remember to use sudo reboot

Apt-get

The command to download, install, and remove packages (typically root), which is used by the Debian Linux system, is very powerful.

For example:

sudo apt-get update//upgrade List of packages

sudo apt-get upgrade//upgrade all installed software

sudo apt-get install vsftpd//download and install VSFTPD (an FTP server)

sudo apt-get remove vsftpd//delete vsftpd

Apt-cache Search gcc Find a package named gcc in apt cache

Dpkg-i 1.deb Installing a package named 1.deb

wget <URL>

Download a file directly from the Web

VI < file name >

File editing commands

VI is not very useful, to remember a series of commands, not recommended

Nano < file name >

File Editing command Nano, this is very useful, learn a minute will

Ctrl+o disk

Ctrl+x exit

StartX

Startup Window System

Zip file1.zip file1 Create a zip-format compression Package

Unzip File1.zip unzip a zip-format tarball

TAR-XVFZ archive.tar.gz Unzip a compressed package in gzip format

TAR-CVFZ archive.tar.gz Dir1 Create a zipped package in gzip format

Df-h Viewing disk space

LSUSB Viewing USB devices

LSMOD displays the modules that are loaded into the system , Lsmod is actually the abbreviation for list modules

sudo insserv/etc/init.d/mysript settings start service/etc/init.d/mysript

sudo insserv-r/etc/init.d/mysript Delete startup service/etc/init.d/mysript

sudo hostname newname Modify host Name

sudo adduser username Add user

sudo deluser username Delete user

sudo halt shutdown

Common Linux commands for Raspberry Pi Deian

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.