Implementation of shell forward parsing script


Forward parsing script

Yum install bind - Y // install parsing Toolkit
//Modify master profile

sed -i '13s/' /etc/ named.conf  //Change the IP address on line 13 of the main configuration file to
sed -i '21s/localhost/any/' /etc/ named.conf   //Change the 21 line localhost to any in the main configuration file
//Add content to zone profile

sed -i '24azone "" IN {\n type master;\n file "";\n allow-update { none; };\n };' /etc/named.rfc1912.zones
//Add domain name after line 24 of regional configuration file
cd /var/named  
cp -p  named.localhost   //Copy the template to our own data area profile
//Configure data area profile

sed -i '2s/@/' 
sed -i '2s/rname.invalid./'
sed -i '8s/@/'
sed -i '9s/'
sed -i '10aIN MX 10\nwww IN A\nftp IN A'
systemctl stop  firewalld.service  //Turn off the firewall
Setenforce 0 // turn off enhancements
Systemctl start named // start the resolution service
echo "nameserver" >/etc/ resolv.conf  //Add your IP address to the resolution profile

Finally, just enter hosts You can resolve the address

The above is the whole content of this article, I hope to help you in your study, and I hope you can support developeppaer more.

Recommended Today

mediaaccess.exe What process is used to query mediaaccess process

Process file: mediaaccess or mediaaccess.exeProcess name: windupdate media access adwareProcess category: processes with security risks English Description:mediaaccess.exe is an advertising program by Windupdate. This process monitors your browsing habits and distributes the data back to the authors servers for analysis. This also prompts advertising popups. This program is a registered security risk and s Chinese […]