LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 01-05-2005, 03:58 PM   #1
triley
Member
 
Registered: Oct 2003
Posts: 74

Rep: Reputation: 15
Multiple NICS in Solaris 8


I'm trying to configure a Sun Ultra 80 running Solaris 8 with multiple NICS. hme0 has an ip address of 192.168.1.2/24. I installed a second nic and ran the following:

ifconfig hme1 plumb
ifconfig hme1 192.168.2.2 netmask 255.255.255.0 up

This worked great, however upon reboot, system did not retain configuration. Found out that I need to edit the following files:

/etc/hostname.hme1
/etc/hosts
/etc/netmasks

/etc/hostname.hme0 looks like this:

<hostname>

/etc/hostname.hme1 looks like this:

<hostname>

/etc/hosts looks like this:

127.0.0.1 localhost
192.168.1.2 <hostname> loghost
192.168.2.2 <hostname> loghost

/etc/netmasks looks like this:

192.168.1.0 255.255.255.0
192.168.2.0 255.255.255.0

Now both interfaces show up with ip address 192.168.2.2

What am I doing wrong? Thanks.
 
Old 01-05-2005, 04:28 PM   #2
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
Quote:
What am I doing wrong?
You are hiding in your posting the piece of information that would help understanding the issue ...
<hostname> is an invalid hostname !
 
Old 01-05-2005, 08:47 PM   #3
triley
Member
 
Registered: Oct 2003
Posts: 74

Original Poster
Rep: Reputation: 15
hostname is akira.
 
Old 01-06-2005, 01:23 AM   #4
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
There should be more than one hostname if you want more than one IP address !
Otherwise, only the first line matching a given hostname is used to pick the IP address.

If you enter the same name in hostname.hme0 and hostname.hme1, how could they have different IP addresses ...
You can either give different hostnames or directly enter different IP address instead of a name in these files, and it should work.
 
Old 01-06-2005, 09:01 AM   #5
triley
Member
 
Registered: Oct 2003
Posts: 74

Original Poster
Rep: Reputation: 15
Thanks. That worked really well. Appreciate the help.
 
Old 01-06-2005, 09:42 AM   #6
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
Thanks, just one more comment:

You should only have one loghost entry and best is to associate it to localhost:

127.0.0.1 localhost loghost
 
Old 01-06-2005, 10:11 AM   #7
triley
Member
 
Registered: Oct 2003
Posts: 74

Original Poster
Rep: Reputation: 15
So /etc/hosts should look like this?


127.0.0.1 localhost loghost
192.168.1.2 <hostname1>
192.168.2.2 <hostname2>
 
Old 01-06-2005, 10:26 AM   #8
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
Precisely !
 
Old 01-06-2005, 11:12 AM   #9
triley
Member
 
Registered: Oct 2003
Posts: 74

Original Poster
Rep: Reputation: 15
Thanks for the help!
 
  


Reply



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
Intel D845GLLY + Multiple Intel Pro 100 NICs + kernel 2.6.x = NICs don't work egable Linux - Hardware 0 02-04-2005 02:30 PM
Multiple NICs + Applications spartan263 Linux - Networking 1 09-03-2004 02:41 PM
Optical NICs on Solaris 9 Jovian Solaris / OpenSolaris 2 03-24-2004 07:15 PM
Multiple IPs on two NIcs dexteroo Linux - Networking 2 09-09-2003 06:55 AM
multiple NICs paulonline2501 Linux - Hardware 2 07-23-2002 05:58 PM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 07:26 PM.

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