Operating System - Tru64 Unix
cancel
Showing results for 
Search instead for 
Did you mean: 

how can I change the MAC address manually

 
michelle_12345
Occasional Advisor

how can I change the MAC address manually

Hi All,

As I know , It's easy to change the PC's MAC address after booting. How can I change the MAC address(network card physical address) in DS10/DS15 manually ?

Thanks!

Michelle
3 REPLIES 3
Ivan Ferreira
Honored Contributor

Re: how can I change the MAC address manually

Hello, you can use the ifconfig command, like this:

# ifconfig tu0 alias 145.92.16.2 physaddr aa:01:81:43:02:11

See man ifconfig for more details. You can add that command to the /etc/inet.local file.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Hein van den Heuvel
Honored Contributor

Re: how can I change the MAC address manually


You may also want to check out
hwmgr -get attribute -category network
(and then check for -set option)

There was an older forum not in this space:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=479507

From a program you can change them with:
ioctl(fildes, SIOCSPHYSADDR, arg)

Our friend / ex-Tru64 Network Engineer Brian Haley has published sample programs to get/get the physical address:

http://amac.paqtool.com/change.htm
http://www.dbforums.com/printthread.php?t=503450

I have attached a single txt file with both set and get sources in there.

hth,
Hein.
michelle_12345
Occasional Advisor

Re: how can I change the MAC address manually

Hi Ivan,

Thanks you for your reply!

Background:DS15 Ethernet port name:ee1
Ip address:192.168.1.2
Mac address:00-0F-20-D8-32-4F

I want to change the ee1's MAC address to :00-0F-20-D8-32-4F

I add following command to inet.local:
#ifconfig ee1 alias 192.168.1.2 physaddr 00-02-A5-C6-86-43

reboot the system, then check with "hwmgr get
attr -cat network", but the ee1's MAC keep same:00-0F-20-D8-32-4F

Would you pls give me other suggestion?

Thanks!

Michelle