Hi there




,
I'm setting up a Mac Xserve as a gateway for a small LAN. I am pretty formilliar with FreeBSD which is the core distribution of the new Xserve (they did however change the directory structure a lot, so i still have to search for everything).
Anyway, here is my problem. Im trying to set up a NAT internet sharing system (very odd that this isnt a standard service btw). I use this script which i got from the Mac support site:
#!/bin/sh
/usr/sbin/natd -dynamic -interface en0
/sbin/ipfw -f flush
/sbin/ipfw add divert natd all from any to any via en0
/sbin/ipfw add pass all from any to any
And yes i did enable IPFORWARDING=-YES- in the /etc/hostconfig file. Plus i also disabled the Firewall function cause those ipfw rules could disrupt the ipfw rules in the script. All this according to the support site.
Now all this works. At least when i manually run the script above. BUT when i put this script in the /Library/StartupItems directory (along with a StartupParameters.plist) it does run on startup (i verified this), however nobody on the LAN can connect to the net. Then when i run the script manually again everybody is online.
I do not want to start this script manually everytime the server reboots. Please help me, what am i doing wrong?
Thanks for helping in advance,
Fili
ps. i do need a solution soon
