In the automated installation script today, the firewall configuration file is required to enable Port 3306 sed-I to insert a new line sed-I in front of a row containing a specific string & #39; /specific string/I new line String & #39; example:
Tag: ROC res indicates process reject profile learning commit openFirewall for Linux1. SELinuxSELinux is a unique security mechanism for Redhat/centos systems. But because this thing is too restrictive, the configuration is so cumbersome that almost
Linux iptable firewall block and open ports
Source: http://hi.baidu.com/zplllm/item/f910cb26b621db57c38d5983
Evaluation:
1, close all the INPUT FORWARD OUTPUT only to some ports open.
Here is the command implementation:
Iptables-p INPUT
The Linux system here is selected CenterOS7 as an example:1, first download the JDK and Tomcat installation package under Linux.Installation and configuration of 2,JDK:(1) Unzip the fileRPM Package:# RPM-IVH jdk-7u55-linux-x64.rpm (jdk-7u55-linux-x64
How to compile and install Iptables instances:First uninstall the system already installed iptables, the need to back up three documents before uninstalling: iptables startup script, Iptables-config configuration document, and already established
Basic KnowledgeThe NetFilter firewall mechanism is built into the Linux system kernel. NetFilter (packet filtering mechanism), so-called packet filtering, is to analyze the network packets into the host, the data packet header data extracted for
Introduction to Linux and Ubuntu installationCommon directivesSystem administration CommandsPackaging compression-related commandsShut down/Restart the machineLinux PipelinesLinux Package ManagementVim useUser and User group managementFile Rights
Friends who often use CentOS may encounter the same problems as me. The firewall is turned on and the 80 port is inaccessible, and the friend who just started learning CentOS can refer to it.Friends who often use CentOS may encounter the same
Configure the Cento6.4 iptables firewall.
1. View firewall status
[Plain] View plain Copy # service iptables status or:
[Plain] View plain copy #/etc/init.d/iptables Status Description: This method can also be manipulated below.
2. Turn off/Turn
Python file system features: OS module
1.os Module Method Classification
(1) Catalogue:
ChDir () Change working directory chroot () sets the root directory of the current process Listdir () lists all filenames under
After a night of hard work, I finally succeeded in the installation. although there are many documents on the Internet, although pptp is the simplest one, it is basically copied, in some cases, errors will not be corrected, so I will sort out the
Iptables is a good firewall software in Linux, this article describes how to install iptables, add and clear rules, open specified ports, and shield basic applications of iptables in CentOS, such as specified ip addresses and ip segments. 1. install
The firewall in centos is a very powerful function, but it has been upgraded in the firewall in centos. Let's take a look at the usage of the firewall in centos in detail.
Basic firewall operationsCommand
Query the Firewall Status: [root @
We add port 80 as an example: [root @ centoshttpd] #/sbin/iptables-IINPUT-ptcp -- dport80-jACCEPT save [root @ centoshttpd] #/etc/rc. d/init. d/iptablessaveiptables: save the firewall rule to/etc/sysconfig. The following is an example of adding port
The Firewall works on the edge of the network or host, A combination of components that check incoming and outgoing data packets on the network or host according to the preset rules and can be processed by the preset actions after the packets match (
Iptables official website: Alibaba
IptablesHttp://netfilter.org/
Path of the data packet passing through the firewall
Port prohibited
Force access to a site
Publish an internal network server
Intelligent DNS
Port ing
Access through NAT
Save and
The instance disabling ssh port only allows remote ssh login on 192.168.62.1, and prohibit ssh # iptables-AINPUT-s192.168.62.1-ptcp from other computers? # Iptables-AINPUT-ptcp? Dport22-jDROP disable proxy port # iptables-AIN
Instance with
1. disable all INPUTFORWARDOUTPUT to open only some ports. The following is the command implementation: iptables-PINPUTDROPiptables-PFORWARDDROPiptables-POUTPUTDROP and then use the command iptables-L-n to check whether the settings are correct. you
The Iptables table has two filter tables and nat tables. There are four links without output ???? INPUT (in the filter table) FORWORD (in the filter table) PREROUTING (in the nat table) POSTROUTING (in the nat table) iptables [-t table] operation
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.