edsel6502 Posted May 5, 2006 Share Posted May 5, 2006 Can anyone give the startup file to manually set MAC address? Write a script. #!/bin/bash echo "Setting MacAdress" # where en? is you adapter # your mac address in the format of xx:xx:xx:xx:xx ifconfig en0 ether 00:0C:00:00:0C:0C Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 5, 2006 Share Posted May 5, 2006 Write a script. #!/bin/bash echo "Setting MacAdress" # where en? is you adapter # your mac address in the format of xx:xx:xx:xx:xx ifconfig en0 ether 00:0C:00:00:0C:0C and save as ? what extension? and put in in startup directory? Link to comment Share on other sites More sharing options...
edsel6502 Posted May 5, 2006 Share Posted May 5, 2006 and save as ? what extension? and put in in startup directory? Good question. Since this is a *nix box. i would say /etc/init.d/ make sure it s owned by root and it can be executed. Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 5, 2006 Share Posted May 5, 2006 How do we set the MAC address in these files? I would like to use SETMAC, but dont know how to set macaddress?HELP or can anyone send me their script file..I'll edit in my mac addy? Link to comment Share on other sites More sharing options...
yzarc Posted May 5, 2006 Share Posted May 5, 2006 YEAH ^^ I've done all the process and now it detects the Ethernet card ^__^ but when i enter this on the terminal: "sudo ifconfig en0 enter 00:11:11:3D:29:AE" the computer freezes. then i manually reboot and in the Net Configuration (on System Preferences) it says that my MAC adress is 00:00:00:00:00:00 can i set it by another way? PLEASE I ONLY NEED THAT (i think) Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 5, 2006 Share Posted May 5, 2006 YEAH ^^ I've done all the process and now it detects the Ethernet card ^__^ but when i enter this on the terminal: "sudo ifconfig en0 enter 00:11:11:3D:29:AE" the computer freezes. then i manually reboot and in the Net Configuration (on System Preferences) it says that my MAC adress is 00:00:00:00:00:00 can i set it by another way? PLEASE I ONLY NEED THAT (i think) yep..mine freezes too =( Link to comment Share on other sites More sharing options...
yzarc Posted May 6, 2006 Share Posted May 6, 2006 woo! there's somebody with the same problem! please some smart guy could help us? i don't think it's very difficult to set a mac address... but i am a noob so... what do i know? xD plase help x___x i want to use iChat... Link to comment Share on other sites More sharing options...
Hater Posted May 6, 2006 Share Posted May 6, 2006 I your computer freezes it means that the driver is trying to use NVRAM to store your MAC Address into NVRAM instead of the driver memory as in case it works. The only solution for this is to avoid DHCP (getting IP from some router, use Manual set of IPs) and set it manually only with the command sudo ifconfig enX XXX.XXX.XXX.XXX netmask XXX.XXX.XXX.XXX or use network panel in System preferences from GUI to set it to permanent IP. If your router refuses packets (you see in GUI or by command ifconfig that the IP address/Mask/Gateway/DNS are set properly, but still have no network) originated from MAC Address 00:00:00:00:00:00 or there is another such MAC address in your network (for example another computer with this driver and MacOsX) there is no way to avoid the problem at all. Sorry to say that, but this is a nasty crack (as I told before) that can not be improved (at least by me). Sorry if the info is a bit admin style, but I don't know how to explain it easyer. Anyway good luck with your hackintoshes Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 6, 2006 Share Posted May 6, 2006 What I ment was if you need to changed it on a regular bases as I do on every restart... I'm not very familiar still with Os X for now and don't know the right place for changing the MAC address of the card so that on boot MAC to be changed before invoking DHCP from the system for this network card...so I wrote a script for my self and put it rc.local as on FreeBSD and now I have changed MAC address and DHCP on every reboot. Without these commands I don't have DHCP because the MAC is 00:00:00:00:00:00. One thing I noticed... If you unload the driver and load it again ifconfig shows that mac is the one you setup before, but it's not the case and you should change it again for proper DHCP work. And one more... I made a look through the tg3 broadcom linux driver and I can definately say that AppleBCM5501Ethernet doesn't know there are flash based NVRAM broadcom chips at all (our case). The original driver tries to read eeprom with an obfuscated value, but flash based NVRAM chip don't obfuscate the content of NVRAM and read it different way. In tg3 there are different functions for reading eeprom based NVRAM and flash based NVRAM and flash based NVRAM is written differently if the flash chip is buffered or not. So... the point of all this info is that there is no easy way to patch NVRam reading in driver because the functions don't exist at all for reading flash based NVRAM The solution... port linux(tg3)/freebsd(if_bge) driver to MacOSX Good luck to people trying to do this hard job. I tryed too but I only managed to load/unload driver, initialize card, read MAC from NVRAM from chip and initialize Phy(sical connection) whitch by the way can be used without modification for start. And don't have time to port the drivers themselves. Happy hacking with your hackintoshes can u send this script? and i'll dump it in rc/local? TIA Link to comment Share on other sites More sharing options...
yzarc Posted May 6, 2006 Share Posted May 6, 2006 I your computer freezes it means that the driver is trying to use NVRAM to store your MAC Address into NVRAM instead of the driver memory as in case it works. The only solution for this is to avoid DHCP (getting IP from some router, use Manual set of IPs) and set it manually only with the command sudo ifconfig enX XXX.XXX.XXX.XXX netmask XXX.XXX.XXX.XXX or use network panel in System preferences from GUI to set it to permanent IP. If your router refuses packets (you see in GUI or by command ifconfig that the IP address/Mask/Gateway/DNS are set properly, but still have no network) originated from MAC Address 00:00:00:00:00:00 or there is another such MAC address in your network (for example another computer with this driver and MacOsX) there is no way to avoid the problem at all. Sorry to say that, but this is a nasty crack (as I told before) that can not be improved (at least by me). Sorry if the info is a bit admin style, but I don't know how to explain it easyer. Anyway good luck with your hackintoshes IT WORKKKKKKSSSSS!!! IT WORKSS!! I REALLY LOVE YOU HATER!! YOU ARE THE BEST PERSON IN THE WORLD!!! WOOO FINALLY I CAN CONNECT MY MAC TO THE INTERNET I DON'T BELIEVE IT!!! THANKS ^^ I WANNA MARRY YOU!!! ^___^ i think this is the best day in my life!!! i'm talking to you from my own Safari!! thanks for all ^^ what i did is what you said, i went to System Preferences / Net and then i manually set my IP, NetMask and Gateway... and i began to cry when Google logo appeared on my Safari xD!! thanks 4 all!!!! Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 6, 2006 Share Posted May 6, 2006 IT WORKKKKKKSSSSS!!! IT WORKSS!! I REALLY LOVE YOU HATER!! YOU ARE THE BEST PERSON IN THE WORLD!!! WOOO FINALLY I CAN CONNECT MY MAC TO THE INTERNET I DON'T BELIEVE IT!!! THANKS ^^ I WANNA MARRY YOU!!! ^___^ i think this is the best day in my life!!! i'm talking to you from my own Safari!! thanks for all ^^ what i did is what you said, i went to System Preferences / Net and then i manually set my IP, NetMask and Gateway... and i began to cry when Google logo appeared on my Safari xD!! thanks 4 all!!!! I already had mine set manually, all 5 puters on home network have their IP'S manually set..I was able to sudo ifconfig 1 more time, but after that, it still freezes..very strange..finally got startup to manually set mac-addy..but that just freezes it quicker..I wonder why it works every once in a while.?? Link to comment Share on other sites More sharing options...
ual808 Posted May 6, 2006 Share Posted May 6, 2006 Hi BCM57xx owners, Since my DELL GX520 started working with BCM5751 (thanks again! Hater!), I added memory and HD to make this machine better. Sometimes, LAN didn't work. Then I tried the followings. 1) Open Terminal and type... sudo -s rm /System/Library/Extensions.mkext rm /System/Library/Caches/com.apple.kernelcaches/* kextcache -c reboot It works most case. But if NOT. 2) TURN OFF/ON your (swich) HUB. So, don't PANIC! I put 10.4.6 and set FIXed IP on GX520 and it works very stable. It wakes up by network access. For people who likes to know how to make BCM57xx work in this board. Start reading from PAGE-6 and newer. If you try the way Hater's and other peoples' POST, you can make yours work 90%, I believe. Link to comment Share on other sites More sharing options...
Emsi Posted May 8, 2006 Share Posted May 8, 2006 As I suspected setting MAC works through ifconfig command (at least for me)After that DHCP is working as supposed If someone needs the commands: # set MAC address sudo ifconfig en0 ether 12:34:56:78:90:AB # renew IP sudo ipconfig set en0 BOOTP sudo ipconfig set en0 DHCP very strange way (for me) to renew the ip from DHCP but it's easy to write standart *NIX command dhclient as I did I guess one of those >40 calls to nvram might be changed to something that returns a fake MAC number. It might be hard to find a proper one though Link to comment Share on other sites More sharing options...
OxiDe99 Posted May 10, 2006 Share Posted May 10, 2006 that did the trick...I unplugged router b4 booting and IP address is now set on every boot..tryed 10 in a row.. no problems..thx to everyone who helped =) special thx to ual808 =)..unplug router/switch/hub is the dillio. Link to comment Share on other sites More sharing options...
edav Posted May 10, 2006 Share Posted May 10, 2006 Hi all, [...] 1) Open Terminal and type... sudo -s rm /System/Library/Extensions.mkext rm /System/Library/Caches/com.apple.kernelcaches/* kextcache -c reboot [...] For people who likes to know how to make BCM57xx work in this board. Start reading from PAGE-6 and newer. If you try the way Hater's and other peoples' POST, you can make yours work 90%, I believe. For those like me who went through all steps explained in this thread (starting from Hater's post) but did not succeed in having OSX recognize their NIC (i mean 'sudo ifconfig' did not returned any 'en0' device), I'd like to say that I finally got my BCM57xx working by recreating the symbolic link, i.e. before removing the mkext and cache with the 'rm' command, I did a cd /System/Library/Extensions/ then a ln -s IONetworkingFamily.kext com.apple.iokit.IONetworkingFamily.kext and then flush the cache and reboot. Please note that: - I have a 00:00:00:00:00 MAC adress (I need to fix that) - my device ID is 167D so I hexedited and textedited accordingly - my little animal is a HP Compaq nc6220 with 10.4.5 - french locale and UI language did not come naturally: I had to do some garden mowing and digging in the system preferences, although the install process did talk to me like my mother uses to Next frontier will be the 2200BG Intel wireless... but this will be another story Again and again, many thanx to those of you that made the stuff possible edav. Link to comment Share on other sites More sharing options...
jst68 Posted May 11, 2006 Share Posted May 11, 2006 Did somebody manage to automize the following steps? # set MAC address sudo ifconfig en0 ether 12:34:56:78:90:AB # renew IP sudo ipconfig set en0 BOOTP sudo ipconfig set en0 DHCP I added them to /etc/rc, but it seems that the network card hasn't been initialized when this startup script is running. Is there another startup script? Or other method? Anyhow, this is a big step forward and thank you very much to the people who figured it out for us. Cheers, JST Link to comment Share on other sites More sharing options...
philgeek Posted May 15, 2006 Share Posted May 15, 2006 still experiencing crashes when manually setting the mac address ive tried to hex-edit and re-hex-edit the drivers using versions of bcom5701 kext from 10.4.3 to 10.4.6 and still no luck, always crashes, even if run from inside a startup script... any suggestions? Link to comment Share on other sites More sharing options...
Gellius31 Posted May 25, 2006 Share Posted May 25, 2006 Hi EveryBody... After several tries, no result... No en0, just lo0, gif0 and stf0... And still same errors in dmesg : AppleBCM5701Ethernet: 0 0 InitNVRam - found non-5701 with serial eeprom or unbuffered flash localhost kernel[0]: AppleBCM5701Ethernet: 0 0 getAdapterInfo - init/sanity check of nvram failed localhost kernel[0]: AppleBCM5701Ethernet: 0 0 start - getAdapterInfo failed, giving up I'm using in 10.4.6 MacOSX version a "Broadcom 570x Gigabit Integrated Controller", VenId: 14e4, DevId: 16a6 in a Dell Inspiron 600m. 1. I modified the AppleBCM5701Ethernet file like Hater recommandations (April 26, 9:26 AM posting), 2. I verified the Info.plist file... My card was already define : <string>pci14e4,16a6</string>... 3. I tried modified AppleBCM5701Ethernet files from tinhead (January 18, 4:04 PM posting), evenif with mofications from 66 81 FA 59 16 to 66 81 FA A6 16 and 75 71 to EB 71... 4. I also verify the following commands : cd /System/Library/Extensions/ ln -s IONetworkingFamily.kext com.apple.iokit.IONetworkingFamily.kext rm /System/Library/Extensions.kextcache rm /System/Library/Extensions.mkext chown -R root:wheel /System/Library/Extensions kextcache -k /System/Library/Extensions No result, no progression and no more idea... Could someone help me ? Is this Topics is related to my ehernet card ? Is it working with the 16a6 DevId and with the 10.4.6 MacOSX version ? Thanks in advance... Link to comment Share on other sites More sharing options...
Nisa-it Posted May 30, 2006 Share Posted May 30, 2006 hi folks, thx for all help me to get working drivers.... best regards, Homar @Gellius31: try the following instructions 1. unpack AppleBCM5751Ethernet.kext.zip 2. move AppleBCM5751Ethernet.kext to /System/Library/Extensions/ 3. open Terminal 4. sudo -s 5. chown -R root:wheel /System/Library/Extensions/ 6. cd /System/Library/Extensions/ 7. chmod -R 755 AppleBCM5751Ethernet.kext 8. reboot AppleBCM5751Ethernet.kext.zip Link to comment Share on other sites More sharing options...
macintoshy Posted May 31, 2006 Share Posted May 31, 2006 Write a script. #!/bin/bash echo "Setting MacAdress" # where en? is you adapter # your mac address in the format of xx:xx:xx:xx:xx ifconfig en0 ether 00:0C:00:00:0C:0C Well, simply attach these lines above to your /etc/ec file just at the end like I did: become a super user: sudo -s pico /etc/rc and edit the end like I did...... export LANGUAGE if [ -f /etc/rc.local ]; then sh /etc/rc.local fi touch /var/run/.systemStarterRunning if [ "${VerboseFlag}" != "-v" ] ; then /usr/libexec/WaitingForLoginWindow fi # set MAC address sudo ifconfig en1 ether 00:01:6C:WW:XX:YY # renew IP sudo ipconfig set en1 BOOTP sudo ipconfig set en1 DHCP exit 0 en1 is my 2nd device. Your one and only network adapter should be en0 (check this 'ifconfig -a') and your real mac adress should be entered. Take a look at windows cmd lines and enter 'ipconfig /all' get read out which mac you have. Replace this mac with my pseudo mac 00:01:6C:WW:XX:YY. You don' have to change the ownership of the rc file, just reboot and get connected Maybe you have to reset caches from OSX by doing this to make fully work: sudo -s rm /System/Library/Extensions.mkext rm /System/Library/Caches/com.apple.kernelcaches/* kextcache -c reboot Does anybody know a much better solution to fix the mac adress problem more OSX likely? My network ist listed as disconnected with the red button in network config, but I still have 100%l network access. Link to comment Share on other sites More sharing options...
Luccio Posted June 1, 2006 Share Posted June 1, 2006 Hi everybody, It's my first post... but I can say : It works I can post this one under MacOS 10.4.6 with Broadcom 5751M (Ven_ID 14E4 , Dev_ID 167D) (IBM Laptop) I try a new install with a new MacOS install and it's working... I sum up : First step (thanks to ual808 and Hater) You need to install HexEdit before. Run terminal 1/ sudo -s 2/ cd /System/Library/Extensions/IONetworkingFamily.kext/Contents/PlugIns/AppleBCM5701Ethernet.kext/Contents/MacOS 3/ cp AppleBCM5701Ethernet /Users/your_account_name/Desktop (back to Desktop) 4/ right click AppleBCM5701Ethernet, Get Info. 5/ change ownership & permissions as you can modify it. 6/ run HexEdit, then open AppleBCM5701Ethernet 7/ choose "Find & Replace" from menu. 8/ Find: "66 81 FA 59 16" /Replace with: "66 81 FA 7D 16" (my DEV_ID is 167D, you type yours at last two bytes) 9/ Matching: "Hex: (<-choose this) 10/ push "Replace", push "Find Next", push "Replace", push "Find Next", ..... DON'T PUSH "Replace All" : there is created mistakes. 11/ scroll down to 37550 12/ change address 37554, 37555 of "75 71" to "EB 71" 13/ then save file and quit HexEdit. 14/ change ownership & permissions as before (by Get Info) ownership="system" and group="wheel" (return to terminal) 15/ cp /Users/your_account_name/Desktop/AppleBCM5701Ethernet ./ Second step : 16/ cd .. 17/ sudo pico Info.plist You must include the following line under the section labeled "<array>": 18/ <string>pci14e4,167d</string> 19/ Save the file, of course 20/ reboot After reboot, it's working ??? Not. So : Third step (thankx to Comlete): It has to do with the Kernel Cache copy. You need to reconstruct it to make the configuration stick. Run terminal. 21/ sudo -s 22/ cd / 23/ cd /System/Library/Extensions/ 24/ ln -s IONetworkingFamily.kext com.apple.iokit.IONetworkingFamily.kext 25/ rm /System/Library/Extensions.kextcache 26/ rm /System/Library/Extensions.mkext 27/ chown -R root:wheel /System/Library/Extensions 28/ kextcache -k /System/Library/Extensions 29/ rm /System/Library/Caches/com.apple.kernelcaches/* 30/ kextcache -c 31/ reboot And now it must work... I hope so. Have a nice day, folks. And sorry for my poor english. Luccio Link to comment Share on other sites More sharing options...
philgeek Posted June 1, 2006 Share Posted June 1, 2006 Hey ual808, Hater, tinhead and various other OSX magicians.. Just wondering if your still poking/prodding this lovely driver in search of a possible fix for the MAC-Address issues, sleep issues etc. It would pretty much be the coolest thing on earth if we could somehow get DHCP working with this bad boy (my network for example filters unknown MAC-Addresses). Anyway thanks for all the work you've put in on this Link to comment Share on other sites More sharing options...
Phusho Posted June 2, 2006 Share Posted June 2, 2006 Luccio the last step is not neccessary it is only for 10.4.3 where there are no such driver Link to comment Share on other sites More sharing options...
Nisa-it Posted June 2, 2006 Share Posted June 2, 2006 Hi Folks, the second try for getting Broadcom 5751 (1677) works. Now MacOS can read the correct mac-adress and works several under DHCP and manually setting IP. i'd be pleasure, if getting some response how it works on other system then my. best regards... Homar ....sorry for my bad english How_to: 1. unpack AppleBCM5751Ethernet.kext.zip 2. copy AppleBCM5751Ethernet.kext to /System/Library/Extensions/ 3. open Terminal 4. sudo -s 5. chown -R root:wheel /System/Library/Extensions/ 6. chmod -R 755 /System/Library/Extensions/AppleBCM5751Ethernet.kext 7. reboot AppleBCM5751Ethernet.kext.zip Link to comment Share on other sites More sharing options...
Phusho Posted June 3, 2006 Share Posted June 3, 2006 What is the difference ? how you patch it ? Link to comment Share on other sites More sharing options...
Recommended Posts