Linux basic commands and linux basic notes
Today, we are building a Linux production environment. This is a complex task that has to be done. Although I have done it many times, there are still many steps and commands that I don't remember. Every time I find information everywhere, it is very troublesome. So I wrote do
the fifth column-C take character \ (text letter \)[[emailprotected] oldboy]# cut -d " " -f3,5 oldboy.txt |sed ‘s#,myqq #,#g‘24. How many lines does the WC statistic file have?How many rows are in the-l statistics file[[emailprotected] oldboy]# wc -l /etc/services10774 /etc/services25, DUMPE2FS display the file system (partition) informationinode sizeblock sizedumpe2fs /dev/sda3|egrep -i "block size|inode count"[[emailprotected] ~]# dumpe2fs /dev/sda3 |grep -i "inode size"dumpe2fs 1.41.12
the table is complete: Query the id=1 table: Enter id=1 table data by alias: query If there is a teacher with job null: for female teachers on a specified date: Multi-Criteria query: Query the ID at the end of the name for E: query begins with the specified character: query with Z in the name: ID Flashback Arrangement: multi-valued sorting: Male and female groups: total number of records queried: Limit Paging query: more Learning Resources and references: MySQL lear
Vim basic operations and vim basic commands
Copy y
Paste p
Cut d
When the row processes yy (copy row), dd (cut row)
Multi-row processing nyy (copying multiple rows) and ndd (cutting multiple rows)
Line paste when row copy is used
Partial row pasting when using region Replication
Intra-row processing y ^ (copying from the cursor
Basic features of Bash(1) Command historyHistoryCall the last parameter of the previous command! $Esc.atl+.Control how the command history is recordedEnvironment variable: HistcontrolIgnoreedups: Ignore duplicate commands, continuous and same as "repeat"Ignorespace: Ignores all commands that start with whitespaceIgnoreboth:ignoreedups,ignorespaceHow to modify Env
Basic LINUX operation commands and basic linux operations
Ls to list files and directories-A: displays all files and directories, including hidden files and directories.-L: displays full attribute information of files and directories.
Cd changes current path(Relative path and data pair path)
Pwd displays the current working file directory
Create a directory u
that developers can submit locally under distributed Each developer machine has a server database backup file record history back to the past multi-share003. Git workflowWorkspaces: code written at work staging area: Staging, helping us save the code as a transition layer to avoid misoperation protect workspace and version area Branch processing version area: Manage version, code action in repository generates version004. Some basic Linux
Basic Linux usage-Basic commands-general Linux technology-Linux technology and application information. For details, refer to the following section. 1. display the content in the current working directory
To know what files or directories are in the current working directory, you must use the "dir" command in the "command prompt" of Windows, and then use the "ls
4. Basic Redis commands-list, basic redis-list1. The list type is implemented using a double linked list. Therefore, if you want to add elements to both ends, the time complexity is O (1 ), the faster the element gets closer to the two ends. However, the cost is that accessing elements through indexes is slow.2. the maximum number of fields that each key can hold
Linux basic commands and linux basic exercises
To enable the Linux operating system, you must log on to the gnome gui as the root user. Select Chinese as the language support.
Use the shortcut key to switch to virtual terminal 2, log on as a common user, and view the system prompt
Use the command to log out of the user logged on to virtual Terminal 2.
Use the
192.168.1.x to connect to the database salesTYPE DATABASE USER ip-address ip-mask METHODHost sales all 192.168.1.0 255.255.255.0 ident Sameuser (indicates that any operating system user can connect with a database user of the same name)8. See so much, come up with a complete example of creating a PostgreSQL database user(1) Access to PostgreSQL advanced users(2) Enable the client program and enter the TEMPLATE1 databasePsql template1(3) Create a usertemplate1=# CREATE USER Hellen with encryped
+
Add permissions
G
The group where the owner resides
W
Write right
-
Delete permissions
O
The others
X
Executive power
=
is what it calls unique permissions
A
All (U,g and O)
To delete all permissions for a file, enter a command:chmod a-rwx Test.txtTo add permissions to the file owner, enter the command:chmod u+rwx TestYou can also use numbers to indicate
use bzip2 to compress tar files
To create a tar file, enter the command:TAR–CVF Filename.tar Directory/file/home/mineThe above command puts Directory/file,/home/mine into the archive.To list the contents of a tar file, enter the command:TAR–TVF Filename.tarTo extract the tar file command, enter the command:TAR–XVF Filename.tarThis command does not delete the tar file, but it copies the contents of the archive to the current working directory and preserves any directory struct
option, because you are worried that if you typo, the directory name will become messy.16. Delete "Empty" directory: RmDir17. Display of files and directories: LS18. Copying Files or directories: CP19. Removal of files or directories: RM20. Moving files and directories, or renaming: MV21, get the path of the file name and directory name: Basename,dirname22, starting from the first line to display the contents of the archive: Cat23. Starting from the last line: TAC (can see that the TAC is backw
Section II Basic commands
Uname–r Query the Linux core version.
The file name of the device and device within Linux
IDE HDD/dev/hd[a-d]SCSI/SATA/USB HDD/dev/sd[a-p]USB Flash Disc/dev/sd[a-p]Floppy disk drive/dev/fd[0-1]Printer 25-pin:/dev/lp[0-2]USB:/DEV/USB/LP[0-15]Mouse Usb:/dev/usb/mouse[0-15]Ps2:/dev/psauxCurrent Cdrom/dvdrom/dev/cdromThe current mouse/dev/mouseTape drive Ide
"style=" Float:none; "title=" 20.png "alt=" Wkiom1eu1dobqkgxaabdd7otcqa206.png-wh_50 "/>12. Select the system form you want to install. In order: Desktop system, minimized desktop system, minimal installation, basic service installation, database server, Web server, virtual host ... Choose a desktop installation here. After clicking Finish, the system will start to install, after the installation is completed, click on the reboot reboot to use.650) t
emp where job= ' job ';2.editDescription: The command can edit the specified SQL scriptCase: Sql>edit D:\a.sql3.spoolNote: This command can output the contents of the Sql*plus screen to the specified file.Spool D:\b.sql and enter spool offDisplaying and setting environment variablesOverview: Can be used to control the output of various formats, set show if you want to permanently save the relevant settings, you can go to modify the Glogin.sql script1.linesizeDescription: Sets the width of the d
new project.4. Defining what to see when you visitOpen the views.py below the project to modify the source code, for example#coding: Utf-8From django.http import HttpResponsedef index (Request):return HttpResponse (U "Welcome to Self-Improvement Academy!")#引入HttpResponse, it is used to return content to the page, just like print in Python, except that HttpResponse is displayed on the page.#我们定义一个index函数, the first parameter must be request, which is
name set column 1= value 1, column 2= value 2 ... where condition;1. All modificationsUpdate t_students set height=188.88;2. Modification by conditionUpdate t_students set gender= ' female ' where id=1;3. Modify multiple values on a per-condition basisUpdate students Set gender = "", name = "XXX";Update t_students set height=165.60,gender=1 where id=3;3) Query1. Querying all ColumnsSELECT * from table name;SELECT * from T_students;2. Specify criteria QuerySELECT * from t_students where name= '
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.