1. Process special file namesSuppose there is a file name named "-ee" in Linux. If we want to operate on it, for example, to delete it, enter the rm-ee command in the command line according to the general deletion method, the interface will prompt
Linux if command
No matter what programming language, conditional judgment is indispensable. SHELL is no exception.If listThenDo somethingHereElif listThenDo another thingHere
ElseDo something else hereFi
#! /Bin/sh
SYSTEM = 'uname-S' # obtain the
Create directory mkdir file name mkdir/var/www/testThe cp command is used to copy files from one location to another. If the destination file exists, the file will be overwritten; If the destination directory exists, the file will be copied to this
Linux and Windows also have the IP configuration function. You can use DHCP to automatically obtain or manually specify an IP address. In Linux, how does one modify the nic ip address?1. configuration file path
cd
VPS is a type of virtualization, but it only has an independent system, and the root virtual machine is quite different. this blog uses VPS as an example. Because the VPS system is selected by you, but how to install it is not controlled by you, you
How to modify IP address, gateway, and DNS in Linux Command LineMethod 1:Ifconfig eth0 192.168.1.18 netmask 255.255.255.0Note: This method can make changes take effect immediately, and will be restored to the original IP address after restart.Method
Objective: To synchronize a master server program with multiple subservers
1. Configure the synchronization Source
Install rsync: yum-y install rsync xinetd
Enable rsync: vim/etc/xinetd. d/rsync to change disable = yes to disable = no
Some useful things have been merged in the East and West, which can be pasted in the nginx configuration file,
Complicated functions, anti-leech protection, anti-injection protection, etc.
location = /robots.txt { access_log off; log_not_found off; }
We all know that initrd is a memory file system started in linux. What is in it? Today, let's take a look at how to open this file system!Initrd = init ramdisk is a file system that exists in the memory at startup. Initrd was initially designed to
Premise: the/usr/local/data file is deleted by mistake. Now, you need to restore the data file,
While/dev/sda3 is mounted under/usr
Use df-hT to check that the file system is in ext3 format !!!
In an ext3 file system, if you delete the file
1. Automatic File Mounting Based on Linux,
Preparations:
1. First prepare a samba Server
2. Clients that need to be mounted with sanba servers
Implementation:
1. Install samba on the server to ensure normal access. Here, yum-y install samba.
2.
Sed
Introduction sed is a non-interactive editor. It does not modify the file unless you use shell redirection to save the results. By default, all output rows are printed to the screen. Sed editor processes files or inputs row by row and sends the
Echo
Function Description: The echo command is the most common command used to print information. It is often used in command lines to print the value of environment variables. it is determined whether the specified environment variables are set in
Iptables is an extremely flexible firewall tool designed for Linux operating systems. Iptables is useful for Linux geeks and system administrators. This article will show you how to configure the most common Linux firewall.About iptables
Iptables is
Explain the output of the free command on Linux.
The following is the free running result. There are 4 rows in total. For convenience, I added the column number. In this way, we can regard the free Output as a two-dimensional array FO (Free Output ).
I. Concepts and Principles
What is PXE?
Strictly speaking, PXE is not an installation method, but a boot method. A prerequisite for PXE installation is that the computer to be installed contains a network card (NIC) supported by PXE, that is, the
Sometimes we use a USB flash drive to install centos, and accidentally install grub to the USB flash drive. As a result, the boot needs to be inserted into the USB flash drive to start the server, or grub is damaged. In this case, we need to
CentOS has a pam_tally2.so PAM module to limit the number of Logon failures. If the number of Logon failures reaches the set threshold, the user is locked.
Compile the PAM Configuration File
# Vim/etc/pam. d/login
# % PAM-1.0
The following operations are completed through actual operations.
The following example shows how to allocate 5g of the home space to the root space.
[Root @ localhost ~] # Df-h
File System capacity in use available % mount
The CentOS community downloads all the source code on the Redhat website and recompiles it. Because AS/ES/WS is a commercial product, you must change all Redhat logos and logos to your own CentOS logos. For example, after compiling the original SRPM
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