The main parameters of large sites: 1.1

0x01

Static, caching, optimized for database, how to optimize for the Web site used redis it? Database optimization measures, etc.

0x02

Static: static website, how large site optimization, optimization measures, what kind of sites considered large sites? Parameters: PV value, UV value, independent IP, rely on several parameters to view the site size

PV value: views website, refers to all the pages of a website, the total number of times in a day 24H is accessed. There is no strict distinction, millions of levels you can call it large sites.

UV values: (unique vistor) a website in a day 24H, the number of users to access our site. More than one million level is a large site.

Independent IP: a website one day 24H, the number of independent IP to access our site, except that an independent IP and LAN.

0x03

Problems caused by large sites

1. concurrency problem: a site at the same time how many people visit a page of the site at the same time.

2. bandwidth issues (flow): Flow can become big

3. Data storage: Data Sheet capacity up to the GT class (Requirements: Quick Find resources needed)

0x04

How high concurrency solve?

Server architecture, using a layered architecture, load balancing process (diversion effect), clusters, separate read and write

Load Balancer: Hardware: F5-BIGIP Features: immediate, expensive, generally used for large companies

                     Software: need a common server, only need to install load-balancing software, lvs (linux viturl server), nginx (do a web server, but also can use load balancing)

Load balancing technology: Polling Technology: load balancing in turn sent the request to the web server

                         Least Connections: load balancing forwards the request to the least busy server

                         IP hash: same client address, and always request the same web server

Separate read and write: database (MySQL, MSSQL), the query operation to the secondary server, the primary server to modify operation. After completion of the modified master synchronization, data is to be synchronized to the secondary server, the master data server maintaining consistent

Cluster: database backup, to prevent the web server downtime caused by data loss, the use of cloud technology, load balancing also need to back up.

 

Guess you like

Origin www.cnblogs.com/sssbug/p/11355324.html