Basic knowledge of Linux and basic commands

Features of Linux

The most distinctive part of a Linux program is the license format. Linux programs use the GPL (GNU General Public License) license format. GPL is a free software license with the following features.

--Freedom to run the program --Freedom to modify the source --Freedom of use and redistribution --Freedom to release improved programs

Kernel and userland

kernel

The kernel is the core part of the OS and is responsible for the most core functions such as direct communication with the hardware.

Userland

The part other than the kernel required for the OS to operate. Refers to basic software groups such as file systems, file operation commands, and shells.

shell

Linux provides an interactive command input environment called a shell. ** The shell has two main functions: accepting command (instruction) input ** and ** executing shell script **. A shell script is for "automating command input". Create a command line by line in one file. By executing the created shell script, command execution can be automated.

Basic commands

ls --Used to browse files and directories

Format

ls [option] [File]

option

-a .Outputs all hidden files starting with
-l Output in long format
-t Sort and output according to the last update time
-r Sort in reverse order and output

cat --One of the commands to check the contents of the file

Format

cat [option]file name

option

-Display with n line numbers added

more --One of the commands to check the contents of the file --When displaying the contents of a file using the cat command, the display will flow if there are many lines. ――The function that controls the screen and stops scrolling in the middle even if there are many lines is called paging, and the command that realizes it is called pager. --There are more and less commands as typical pagers.

Format

more file name

After opening the file, you can operate it by entering the command as follows

item Contents
space Proceed to the next page
b Return to the previous screen
f Proceed to the next screen
/word Search for a word. Jump search results with n key
q Exit the pager command

less --One of the commands to check the contents of the file --Typical pager commands

Format

less file name

After opening the file, you can operate it by entering the command as follows

item Contents
space Proceed to the next page
b Return to the previous screen
f Proceed to the next screen
↑ Go to the previous line
↓ Go to the next line
/word Search for a word. Jump search results with n key
q Exit the pager command

touch --Change file timestamp --The file always has a time stamp (last modified date). You can check the time stamp with the -l option of the ls command. --The touch command changes the last update time.

Format

touch [option] [file name]

--When you execute the touch command, the time stamp of the file is changed to the current date and time. --If the file does not exist, create an empty file.

Recommended Posts

Basic knowledge of Linux and basic commands
Basic LINUX commands
[Linux] Review of frequently used basic commands 2
[Linux] Review of frequently used basic commands
Basic knowledge about Linux
Basic knowledge of Python
Studying Linux commands and frustration
CLI and Linux basic terms
Beginners! Basic Linux commands and how to use them!
Explanation of package tools and commands for Linux OS
Linux commands
Linux commands
Summary of basic knowledge of PyPy Part 1
linux commands
Basic commands
[Linux] File and directory operation commands
List of frequently used Linux commands
Linux commands
Linux commands
About Linux commands Super basic edition
Commands and files to check the version of CentOS Linux
Note: Linux concepts and minimum commands
Linux (for users and su / sudo commands)
[Linux] Summary of middleware version confirmation commands
[Linux] List of Linux commands used in practice
Basic usage of Btrfs on Arch Linux
Summary of petit techniques for Linux commands
[Linux] Learn the basics of shell commands
Network Linux commands
Linux command <Basic 2>
Verbalize Linux commands
Linux user commands
[Basic] linux command
New Linux commands! !!
[Linux] Command / Knowledge
Linux command <Basic 1>
Various Linux commands
Typical Linux commands (7)
[Linux] Zip file compression and decompression commands [Vim]
[Linux] Basic settings after OS installation of CentOS 7.3
[Linux command] A memorandum of frequently used commands
Basic operation of Python Pandas Series and Dataframe (1)
[Linux] A list of Linux commands that beginners should know
OS and Linux distribution
Summary of Linux (UNIX) commands that appeared in Progate
Frequently used Linux commands
Basic operation of pandas
Frequently used Linux commands
Basic usage of flask-classy
Basic usage of Jinja2
[Copy and paste OK] Basic Linux command collection [18 selections]
Linux basic command memorandum
Frequently used linux commands
Meaning of Linux permissions
[Linux] Group related commands
Linux commands to remember
[Linux] Installation of nvm
Basic operation of Pandas
Basic usage of SQLAlchemy
New Linux commands! !! Part 2
[Django series] Basic commands