Linux from getting started to mastering--enterprise network installation

Source: Internet
Author: User
Tags get ip

# # # #企业网络安装 # #

Purpose: Deploy servers in bulk

Share files over the network via TFTP

On the server side:
To install and configure a DHCP configuration file
Systemctl Stop Firewalld # #特别重要, turn it off.
Yum Install Dhcp-y
Cp/usr/share/doc/dhcp-4.2.5/dhcp.conf.example/etc/dhcp/dhcpd.conf

      

Vim dhcpd.conf
# #27和28以及35行以后删除
# #195 option Domain-name "student.com" domain name
# #196 option Domain-name-servers 114.114.114.114 DNS
# #default-lease-time 600 default lease period
# #max-lease-time 7200 Maximum lease period

# #subnet 172.25.254.0 netmask 255.255.255.0 {subnet settings
Range 172.25.254.160 172.25.254.200; IP address Pool
Option routers 172.25.254.250; Gateway
}

      

On the client:
Because you want to get Ip,gw,dns from the server and the files that require client access, the client is set to DHCP

      

On the server side:
To share (provide) your file pxelinux.0 file, you'll need to download syslinux-4.05-8.e17.x86_64
Yum Install Syslinux-4.05-8.e17.x86_64-y
Yum Install Tftp-server.x86_64-y # #用的网络服务是tftp
Netstat-antlupe | grep xinetd # #端口没有开启
Vim/etc/xinetd.d/tftp
Disable = no
Sysemctl Restart Xinetd.server
Netstat-antlupe | grep xinetd #端口开启了

      

      

The default distribution directory for TFTP is:/var/lib/tftpboot
cp/usr/share/syslinux/pxelinux.0/var/lib/tftpboot/
Mkdir/var/lib/tftpboot/pxelinux.cfg
Access to the installation interface, but the point option is not available because there is no default file

grep "Install Red Hat"-R # #显示installred had is which directory to read

On The real machine :
MOUNT/ISO/RHEL7.0/MNT # #将7.0 Mirroring Mount then read
Cd/mnt
Cd/isolinux
Scp-r *[email Protected]:/var/lib/tftpboot
On the server side:
Cd/var/lib/tftpboot
LS # #会出现当才拷贝的文件
      

Because the default is to access the Pxelinux.cfg/default file, create a
CP isolinux.cfg Pxelinux.cfg/default # #因为isolinux这个文件是最初的那个界面
Systemctl Restart Xinetd.service

Vim/etc/dhcp/dhcpd.conf
# #27和28以及35行以后删除

# #subnet 172.25.254.0 netmask 255.255.255.0 {subnet settings
Range 172.25.254.160 172.25.254.200; IP address Pool
Option routers 172.25.254.250; Gateway
Next-server 172.25.254.110; # #引导访问下面的文件
FileName "pxelinux.0"
}

Change the wait time and default title, background map, big title:
Change the contents of a Pxelinux.cfg/default file
Cd/var/lib/tftpboot
Vim Pxelinux.cfg/default
Timeout # #更改等待时间
      

# #在label Linux and label check, change the following to Linux
Menu Default # #更改光标默认位置
      

Menu title Westos Install OS # #更改大标题
Menu Background Xxx.png # #更改背景图

Attach point: Change the pixels of a picture
File Splash.png # #查看背景的像素
Splash.png:PNG image data, 640x480,1-bit colormap,non-interlaced
Convert liuyan.png-resize 640x480!liu.png # #更改照片的像素

Add a mirror and auto-install script that can install virtual machines
On the real machine:
mount/xxx/xxx.iso/var/www/html/rhel7.0 # #挂载到默认读取目录上
      

Cd/var/lib/tftpboot
Vim Pxelinux.cfg/default
Append initrd=initrd.imgrepo=http://172.25.254.10/rhel7.0 quit (does not show intermediate process)
      

Yum Install System-config-kickstart-y # #下载自动安装
System-config-kickstart # #编辑ks. cfg file
Ksvalidator ks.cfg # #查看检测ks. CFG If there is a syntax error
      

Cd/var/lib/tftpboot
Vim Pxelinux.cfg/default
Append initrd=initrd.imgrepo=http://172.25.254.10/rhel7.0 quit (does not show intermediate process) ks=http://172.25.254.110/ks.cfg

Note: Remember to open the HTTPD service, I did not open at the beginning, and then the installation will be error, no files

Linux from getting started to mastering--enterprise network installation

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.