The IP usage of the Apache virtual host includes IIS

Source: Internet
Author: User

Today finally understand the Apache virtual host <virtualhost *:80> IP is what to do.

I did not know that the server can have multiple public IP, today only know that the server's public IP can be added.

For example, a server has more than one site, but want to implement each domain name corresponding IP is different, then you can add IP in the server, and then the Apache virtual host configuration IP is assigned to this IP;

For example, the server has 1.1.1.1,1.1.1.2,1.1.1.3 three public network IP, want to implement www.1.com use 1.1.1.1 this IP, then <virtualhost 1.1.1.1:80> here should fill in the corresponding IP, Of course, domain name resolution IP also fill in this IP, and so on. If the <virtualhost *:80> *, then the server is automatically assigned to the domain name resolution of the IP prevail. If the domain name resolution IP is inconsistent with the virtual host IP here, such as www.1.com resolution to 1.1.1.2IP, but the server Apache configuration is <virtualhost 1.1.1.1:80> then the site will not open, if < VirtualHost *:80> is *, automatically assigned (Domain name resolution IP) 1.1.1.2.

The same is true for IIS:

Summary: No special requirements of the site, are <virtualhost *:80>.

Specify IP unless you want to assign it to this IP, not the case. If you want to implement multiple sites on the same server IP is different, you need to add IP and the corresponding domain name resolution.

The IP usage of the Apache virtual host includes IIS

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.