Solved

add 2nd network card

Posted on 2004-04-23
6
315 Views
Last Modified: 2013-12-16
I need to put one of my Linux machines on 2 networks.  It will need to have two different ips: 10.0.x.x and 192.168.X.X.  I am running Redhat 8.0.  I installed a second ethernet card (it is compatible w/ Linux accordinf to HOWTO).  Now, I've booted the computer, and don't know what to do next.  The original card is already configured properly.  Both ethernet cards are differnt, therefore I am sure I need to do something with drivers, but don't know what.  Then I would like to configure the 2nd ethernet card as eth1 but don't know how.  The original card is eth0.  Lastly, I am sure I need to edit etc/hosts, but don't know how?

Thanks in advance!

Brian
0
Comment
Question by:wxman1
[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
  • 3
  • 2
6 Comments
 
LVL 3

Expert Comment

by:tolgadalkilic
ID: 10903086
0
 
LVL 12

Accepted Solution

by:
paullamhkg earned 250 total points
ID: 10916025
what u need to do is ensure the driver already installed, normally the system will tell you a new hardware found and request the driver/list out network card for you to select during your RH8.0 startup (plug and play function of RH). since you said the NIC is compatible with linux, so I think the NIC should list out after the new hardware detected.

After that you have to change the /etc/sysconfig/network-scripts/ifcfg-eth1 as below

DEVICE=eth1
BOOTPROTO=static
BROADCAST=192.168.255.255
IPADDR=192.168.x.x
NETMASK=255.255.255.0
NETWORK=192.168.0.0
ONBOOT=yes

after the file saved, run ifup eth1 should bring up the new NIC.

or you can use the 'netconfig' in the command prompt/console mode to config your second NIC (eth1).
0
 

Author Comment

by:wxman1
ID: 10917688
paullamhkg

I changed ifcfg-eth1 as you said, with the correct settings.  Now I probably need to edit the etc/hosts but I'm not sure how.

any suggestions?
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 12

Expert Comment

by:paullamhkg
ID: 10925100
NAME
       hosts - The static table lookup for host names

SYNOPSIS
       /etc/hosts

DESCRIPTION
       This manual page describes the format of the /etc/hosts file. This file
       is a simple text file that associates IP addresses with hostnames,  one
       line per IP address. For each host a single line should be present with
       the following information:

              IP_address canonical_hostname aliases

       Fields of the entry are separated by any number of  blanks  and/or  tab
       characters.  Text  from  a "#" character until the end of the line is a
       comment, and is ignored.  Host  names  may  contain  only  alphanumeric
       characters, minus signs ("-"), and periods (".").  They must begin with
       an  alphabetic  character  and  end  with  an  alphanumeric  character.
       Aliases  provide  for  name changes, alternate spellings, shorter host-
       names, or generic hostnames (for example, localhost).   The  format  of
       the host table is described in RFC 952.

       The Berkeley Internet Name Domain (BIND) Server implements the Internet
       name server for UNIX systems. It augments or  replaces  the  /etc/hosts
       file  or  host name lookup, and frees a host from relying on /etc/hosts
       being up to date and complete.

       In modern systems, even though the host table has  been  superseded  by
       DNS, it is still widely used for:

       bootstrapping
              Most  systems  have  a  small host table containing the name and
              address information for important hosts on  the  local  network.
              This  is useful when DNS is not running, for example during sys-
              tem bootup.

       NIS    Sites that use NIS use the host table as input to the  NIS  host
              database.  Even  though NIS can be used with DNS, most NIS sites
              still use the host table with an entry for all local hosts as  a
              backup.

       isolated nodes
              Very small sites that are isolated from the network use the host
              table instead of DNS. If the local information  rarely  changes,
              and  the  network  is  not connected to the Internet, DNS offers
              little advantage.

EXAMPLE
        127.0.0.1       localhost
        192.168.1.10    foo.mydomain.org  foo
        192.168.1.13    bar.mydomain.org  bar
        216.234.231.5   master.debian.org      master
        205.230.163.103 www.opensource.org

The above is the man page of /etc/hosts so you can have some idea.

can you tell us what you are planning to do with your 2 NIC linux, so that we can more specify.
0
 

Author Comment

by:wxman1
ID: 10927607
This is what I am trying to do:

The original card will continue to be used as it has been.  It connects the Linux PC to our LAN.  It needs to be connected to our LAN, and it uses Samba to communicate with the Windows Computers that are on the LAN.

I put the 2nd card in the Linux PC because we have data that is transmitted to us via satellite.  This data comes into a satellite modem, which in turn changes the data format to TCP/IP then broadcasts the data to a proprietary ip address inherant to the satellite modem.  Because the satellite modem is looking for a particular ip address that does not conform to our LAN, I thought this would be the best way to go.
0
 

Author Comment

by:wxman1
ID: 10929133
thanks for your help.  everything is working now!
0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

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

Network Interface Card (NIC) bonding, also known as link aggregation, NIC teaming and trunking, is an important concept to understand and implement in any environment where high availability is of concern. Using this feature, a server administrator …
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
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.
Suggested Courses

752 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