Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: C++ Linux
Needed C/C++ code which returns MAC address on on solaris platform without root user..
Posted 10-Jan-13 20:27pm
Richard MacCutchan at 11-Jan-13 4:30am
This sort of information is for root user only; and with good reason.
Jochen Arndt at 11-Jan-13 8:57am
I don't know Solaris. But with Linux, this information can be grepped from the boot.msg log file which is readable for all users. If there is a similar file with Solaris, you might parse it.
Albert Holguin at 13-Jan-13 8:54am
that's a good suggestion... I haven't used Solaris since way back in the day... so I can't remember much about this type of stuff

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Its been a very long time since I've played with Solaris but if I recall you can get it by running system("arp hostname") and parsing the results.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 358
1 Sergey Alexandrovich Kryukov 239
2 MT_ 175
3 Yogesh Kumar Tyagi 165
4 ChauhanAjay 156
0 Sergey Alexandrovich Kryukov 6,205
1 OriginalGriff 5,333
2 CPallini 2,473
3 Richard MacCutchan 1,617
4 Abhinav S 1,530

Advertise | Privacy | Mobile
Web03 | 2.8.140814.1 | Last Updated 19 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100