Understanding OS X StartupItems: Oreilly

OS X is really darn cool, it looks great AND its rock solid, but it does have a few really confusing aspects for those that are already familiar with Unix (for me at least).

One of the confusing items is the mechanism for startup and shutdown of processes. In SysV you put the shell scripts for what you want to control on startup and shutdown in a specified runlevel control directory and the scripts take known parameters ("start", "stop"). This is easy enough and its what Linux users will be familiar with. With BSD you normally have one big control script and you put what you want in that script directly. With OS X you have its own thing, the "StartupItem".

StartupItems accomplish the same task. They control what starts and stops and when. They also offer more direct flexibility with "dependencies" than just their ordering. (Note that OS X also has "LoginItems" which as the name implies dont run at startup but at user login.) StartupItems have their own syntax and their own specific locations (System/Library/StartupItems and /Library/StartupItems).

The syntax and the nuances of StartupItems can be a bit tricky. For info on the details check out the the linked Oreilly article. Its good stuff for those a bit bewildered in the mac world, such as myself.
  Writing and Understanding OS X StartupItems

Comments

Re: Understanding OS X StartupItems: Oreilly

Yeah, the startup items and using the registry system in place of /etc/hosts (though now you can use /etc/hosts too) was one of the most confusing things for me about OSX. Its really the same system that NeXTStep used, but I never had to admin one of those myself. Fortunately when OSX was new you sould still find enough docs on the net about NeXT boxes to figure it out :P

Re: Understanding OS X StartupItems: Oreilly

LOL, the original article had an entire section about NetInfo manager being confusing also. The /etc/hosts and other files thing. I cut it out because it didnt really pertain to the linked article. But the netinfo ldap thing and startupitems are my 2 "confusing" os x items as well.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.