LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Closed Thread
  Search this Thread
Old 12-01-2016, 05:11 AM   #1
harshld
LQ Newbie
 
Registered: Nov 2016
Posts: 3

Rep: Reputation: Disabled
Configuring Static IP Addresses in Centos 7


I am trying to assign static IP address to Centos 7 with the commands

vim /etc/sysconfig/network-scripts/ifcfg-ens33

I can edit and it is saving but when i try checking for configs through ifconfig it is the same ip as of earlier through dhcp. using centos in a virtual environment of VMware.

I am using CENTOS 7 in VMWare, earlier the IP address (dhcp) was 192.168.139.135, but now when I assigned 192.168.139.100, it can neither ping any website or connect in any manner.

ping google.com
ping: unknown host google.com


this is the output when I try to do ping.

is there anything I am missing in vim /etc/sysconfig/network-scripts/ifcfg-ens33

TYPE=Ethernet
BOOTPROTO=none
IPADDR=192.168.139.100
NETMASK=255.255.255.0
GATEWAY=192.168.139.2
DOMAIN=majan.com
DNS1=192.168.139.100
DEFROUTE=yes
IPV4_FAILURE_FATAL=yes
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=yes
NAME=ens33
UUID=5f06d8d9-273b-45a8-807b-35e2e27c840f
DEVICE=ens33
ONBOOT=yes
PEERDNS=yes
PEERROUTES=yes
IPV6_PEERDNS=yes
IPV6_PEERROUTES=yes


this is what I entered.

Please help.
 
Old 12-01-2016, 06:02 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 23,657

Rep: Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172Reputation: 5172
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.

http://www.linuxquestions.org/questi...-a-4175594419/
 
  


Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Configuring Static IP Addresses in Centos 7 harshld Linux - Newbie 5 12-01-2016 06:48 AM
[SOLVED] Configuring Static IP CentOS so router Motorola NVG510 can recognize device and port forward NAT. jmc1987 Linux - Newbie 12 10-08-2013 10:41 PM
Howto Assign Multiple Static Public IP Addresses under SBC's PPPoE Static Ip system o trekgraham Linux - Networking 8 04-17-2007 11:51 AM
Static IP addresses BCarey Linux - Networking 5 05-06-2006 05:30 PM
Configuring domain names on static IP addresses from SBC DSL redbasin Linux - Networking 4 02-10-2004 11:06 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration