Vmware Redhat 6.3 Static IP, DNS, gateway Configuration

Source: Internet
Author: User

Today came back to open the virtual machine, the results with Xshell connection is not, the feeling should be my local IP has changed, my virtual machine is located in a computer connection is another B computer sent wifi,a computer This IP is automatically obtained, originally a computer IP for 173.23.x.x, In order to set a good memory IP, I will b computer transmitting WiFi card IP as fixed 192.168.0.100 , subnet mask 255.255.0.0

So that my a computer's IP will become 192.168.x.x (if not the IP style, the above can be ignored)

Get the subnet mask under a PC host CMD, gateway

Executing vim/etc/sysconfig/network-scripts/ifcfg-eth0 on a computer virtual machine

Note Bootproto=static

The subnet mask, like host A, has the following IP format

The main subnet mask 255.255.255.0 gateway 192.168.0.100 IP is in 192.168.0.x form

Primary subnet mask 255.255.0.0 Gateway 192.168.0.100 IP must be in 192.168.x.x form

This is configured so that the host can connect to the virtual machine, but the virtual may not yet be able to connect to the extranet, plus DNS and gateways

The following is the temporary effect of the gateway setting

To modify the gateway Default gateways
Immediate effect:
# route add default GW 192.168.0.1 dev eth0
Activation takes effect:
Modify/etc/sysconfig/network
Modify DNS
Modify/etc/resolv.conf
Modified to take effect immediately, start the same effective

Vmware Redhat 6.3 Static IP, DNS, gateway Configuration

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.