[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Can not find interfaces file on centos 5.5

Posted on 2010-09-03
6
Medium Priority
?
862 Views
Last Modified: 2012-06-22
Hi,

I am following the tutorial at http://cloudservers.rackspacecloud.com/index.php/Basic_Cloud_Server_Security

and am trying to set up the iptables

#Now we need to ensure that the iptables rules are applied when we reboot the server. At the moment, the changes will be lost and it will go back to allowing everything from everywhere.

#Open the file /etc/network/interfaces:

nano /etc/network/interfaces

#Add a single line (shown below) just after 'iface lo inet loopback':

...
auto lo
iface lo inet loopback
pre-up iptables-restore < /etc/iptables.up.rules

# The primary network interface
...

Open in new window


However, I can't find the interfaces file?

I've done a locate and it doesn't seem to be there. Is there another file I can put this line of code?

Thanks,

Julian
0
Comment
Question by:DrZork101
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 11

Expert Comment

by:elbereth21
ID: 33595087
Under /etc/sysconfig/network-scripts/ you'll find a file for each interface ifcfg-*
This is the equivalent for CentOS, although I am not sure of the syntax you should use inside those files, to achieve what you are trying to.
0
 
LVL 88

Expert Comment

by:rindi
ID: 33595161
What distro are you using?
0
 
LVL 19

Expert Comment

by:jools
ID: 33595173
Hi

They look like generic notes, may be related to something else and it says at the top of the file you need to refer to your OS notes.

There are many tutorials on the net;
http://www.frozentux.net/iptables-tutorial/iptables-tutorial.html
http://www.linuxreport.org/content/view/26/23/

If you want you can use the RH default rules by running system-config-securitylevel from the GUI.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 31

Expert Comment

by:farzanj
ID: 33606441
You can use one of the following commands to find your interfaces files:

If you have locate on your system do the following

locate eth
locate ifcfg

if you don't get any output, do this
updatedb

and then run the above commands.

If however your system doesn't have this command try the following
find /etc -name *eth*

Hope it helps
0
 
LVL 31

Accepted Solution

by:
farzanj earned 2000 total points
ID: 33685346
On CentOS5.5 interface files are in the following directory:
/etc/sysconfig/network-scripts

The files are named ifcfg-eth0, ifcfg-eth1, etc.
0
 

Author Closing Comment

by:DrZork101
ID: 33877223
Solves qeustion
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses

650 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