Hello All,
Does anyone know how to run a shell script during the system startup? I want to make adjustment to my network settings and I need to make them before the User logs in. Any ideas where I can put my shell or code into an existing shell?
Thank You
G
Don’t put your StartupItem in /System/Library/StartupItems or it will be removed at the next software update. Rather, put it in /Library/StartupItems.
The easiest way to do it is to copy an existing StartupItem from /System/Library/StartupItems to /Library/StartupItems. Find an item closest to what you want it to do, for example the SNMP startupItem may be most similar to your MTU settings you want to script. Then just modify the shell script and test it with Terminal:
SystemStarter [yourtItemname]