Menu

#12 Trouble on HP-UX

open
nobody
None
5
2004-10-22
2004-09-01
No

Hello,

I compiled libdnet on HP-UX with the --with-pic option

When I run the code to get the mac address, I get a
null mac address.

The code is:

pEth=eth_open("lan0");
if (pEth != NULL)
{
lRet=eth_get(pEth, pEthAddress);
printf("%02X-%02X-%02X-%02X-%02X-%02X\n",
(*pEthAddress).data[0],
(*pEthAddress).data[1],
(*pEthAddress).data[2],
(*pEthAddress).data[3],
(*pEthAddress).data[4],
(*pEthAddress).data[5]) ;
DPSDumpVariable(lRet);
eth_close(pEth);
}

The result is:
00-00-00-00-00-00

Discussion

  • Dug Song

    Dug Song - 2004-09-01

    Logged In: YES
    user_id=18578

    just to be sure - you're running this code as root, yes?

     
  • Matthieu Pupat

    Matthieu Pupat - 2004-09-01

    Logged In: YES
    user_id=913642

    No I am not.

     
  • Dug Song

    Dug Song - 2004-09-01

    Logged In: YES
    user_id=18578

    this may only work as root on HP-UX.

    if it doesn't, please let me know.

     
  • Matthieu Pupat

    Matthieu Pupat - 2004-09-02

    Logged In: YES
    user_id=913642

    I tested this as root, it does not work either.

     
  • Dug Song

    Dug Song - 2004-09-02

    Logged In: YES
    user_id=18578

    can you show me the output of 'config/config.guess' ?

    it seems to work fine for me, on hppa2.0w-hp-hpux11.11.

    can you also show me the output of 'test/dnet/dnet intf get
    lan0' ?

     
  • Dug Song

    Dug Song - 2004-10-20
    • status: open --> pending
     
  • Matthieu Pupat

    Matthieu Pupat - 2004-10-22
    • status: pending --> open
     
  • Matthieu Pupat

    Matthieu Pupat - 2004-10-22

    Logged In: YES
    user_id=913642

    Here are the outputs:

    # config/config.guess
    hppa2.0w-hp-hpux11.00
    # test/dnet/dnet intf get lan0
    lan0: flags=0x31<UP,BROADCAST,MULTICAST> mtu 1500
    inet 192.9.200.42/24
    link 00:30:6e:1d:fd:74

     
  • Matthieu Pupat

    Matthieu Pupat - 2004-10-22

    Logged In: YES
    user_id=913642

    I get the same results as non-root user too.

     

Log in to post a comment.