In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
LVS Cluster Creation and Management
Using the ipvsadm tool
Network File System
Depends on RPC (Remote Procedure Call) Requires installation of nfs-utils, rpcbind packages System services: nfs, rpcbind Shared configuration files: /etc/exports
Case Environment LVS scheduler acts as the gateway of web server pool, LVS two network cards are connected to internal and external networks respectively, using polling (rr) scheduling algorithm
Experimental case diagram
experimental process
1. Configure NFS storage servers to provide storage space
1. Start by adding two hard disks to the nfs server
2. Restart server after adding hard disk
3. Modify the hostname for each server for easy identification
4. View newly added hard drives
Format two hard disks (the two methods are the same, take sdb as an example)
After formatting, mount. First, create two mount points.
Modify the/etc/fstab file
Mount successful
5. shared storage space
turn off the firewall
All required packages exist for sharing
modify the configuration file
Modify NIC to host-only mode
At this point nfs is in a disconnected state, so configure it at the VM terminal
Turn on the service and see if the shared space path is available
Modify the NIC configuration because we switched connection mode
Restart the NIC and verify
NFS server configuration complete
2. Configure two Web servers
First install Apache services (two web server configuration process is the same, take Web1 as an example)
turn off the firewall
Switch NIC to host-only mode
Modify web1 network card address
Modify web2 network card
providing site
vim /etc/fstab
Mount the site and view
Go to default home page Write content
opening service
At this point, the work on both Web servers is complete.
III. Configure the LVS server
1. Download the ipvsadm installation tool
2. Add NIC to LVS server and set to host-only mode
Copy a copy of the contents of the network card and modify both network cards
Restart the NIC and check
Using two web servers ping the gateway to test connectivity
Enable routing forwarding
Configure firewall settings using iptables
Clear forwarding table
Clear NAT address translation tables
Change IP address of win10 client
Client pingLVS Server Test
Load the LVS kernel module
Define startup scripts
startup script
Next, test it on the client.
The experiment of NAT working mode in LVS scheduler is completed!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.