Solved

how can I set a static ip address on centos

Posted on 2011-09-16
2
414 Views
Last Modified: 2012-05-12
i know i would have to edit a conf file or something , if i wanted to put a static ip . mask and gateway what file would i edit and what is the format ?
0
Comment
Question by:NAMEWITHELD12
2 Comments
 
LVL 21

Accepted Solution

by:
Papertrip earned 500 total points
ID: 36553048
[user@box ~]$ cd /etc/sysconfig/network-scripts/
[user@box network-scripts]$ cat ifcfg-eth0
DEVICE=eth0
BOOTPROTO=static
IPADDR=10.190.3.105
NETMASK=255.255.255.192
GATEWAY=10.190.3.111

Open in new window


You can put the gateway in there for a device specific gateway, or you can add that same line to /etc/sysconfig/network to make it the default gateway.

0
 
LVL 1

Author Closing Comment

by:NAMEWITHELD12
ID: 36553088
thAnks
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How VPC help preventing STP Loops 4 127
Reccomended programming language for client-server applications 12 123
Cisco 3650 switch 7 45
Powerline adapter slow Mbps? 38 165
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
In this article, I am going to show you how to simulate a multi-site Lab environment on a single Hyper-V host. I use this method successfully in my own lab to simulate three fully routed global AD Sites on a Windows 10 Hyper-V host.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question