Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I change an ethernet address of a quad ethernet NIC ???

Status
Not open for further replies.

emcquaid

MIS
Apr 3, 2002
6
0
0
GB
I need to change then ethernet address of a NIC on a Solaris 2.8 machine, so that it will automatically change to a set ethernet address of my choice on reboot as the port is 'flapping' every time the server is rebooted.

I know ifconfig is useful eg.

ifconfig qfe0 ether 0:3:ba:4:bf:29

This is only when the machine has started, I need it to change, like how it sets the hostname files, on start up.

But which files do I need to edit to ensure that it will change the address?

Eamonn :)
 
Network dynamic setup:

# ifconfig qfe0 ether 0:3:ba:4:bf:29

# ifconfig qfe0 plump

# ifconfig qfe0 up

# ifconfig -a
if everythings ok make entries in

/etc/hostname.qfe0
/etc/netmasks
/etc/hosts
/etc/ethers

regards ph
 
PH had it right with one small problem...
You need to change # ifconfig qfe0 plump to

# ifconfig qfe0 plumb <must have mis-typed>


Network dynamic setup:

# ifconfig qfe0 ether 0:3:ba:4:bf:29

# ifconfig qfe0 plump

# ifconfig qfe0 up

# ifconfig -a
if everythings ok make entries in

/etc/hostname.qfe0
/etc/netmasks
/etc/hosts
/etc/ethers

regards ph
 
What is the syntex for adding the example I gave into the /etc/ethers file ?, is this correct:

0:3:ba:4:bf:29 (hostname.qfe1) where this is the hostname
file for the interface port.

Cheers

Eamonn
 
There is another way to change MAC in Solaris.

The hardware Ethernet MAC address is unique to a particular station not to a particular interface. Therefore all Ethernet interfaces on thesame system will share the same Ethernet hardware address. The system gets this hardware address from the EEPROM not from the Ethernet hardware.

Each of the network interfaces of the Sun hme FastEthernet has been assigned a unique Media Access Control (MAC) address, which represents the 48-bit Ethernet address for that network interface. The OpenBoot(tm) firmware reports this MAC address via the local-mac-address property in the device nodes corresponding to the network interfaces.


Each interface has a unique MAC address by issuing the command:
setenv local-mac-address? true
at the &quot;ok&quot; prompt, or the command:
eeprom &quot;local-mac-address?=true&quot;
as root.
A reboot is needed for this change to take effect, but make the other configuration changes first to avoid repeated reboots.
Next, modify /etc/hosts to contain the additional network addresses. It is a good practice to create an address for each interface (the normal and dummy addresses).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top