troubleshooting Question

Snow Leopard - Startup/shutdown rc.d script equivalent for NFSD

Avatar of dogbertius
dogbertius asked on
Apple OSUnix OSShell Scripting
5 Comments2 Solutions667 ViewsLast Modified:
Hi there,

I am mainly a Linux/BSD user. Typically, when running certain startup scripts for network shares, wifi services, etc, the startup commands are in /etc/rc.d/rc.service_name

These scripts only run automatically at system startup if the respective script has executable permissions on it (ie: chmod 0755). For some scripts, I prefer to only run them manually, so I remove executable permissions (chmod a-x /etc/rc.d/rc.service_name), and just manually launch them with sudo (ie: sudo sh /etc/rc.d/rc.service_name start).

How can I do the same thing with OSX (Snow Leopard)? I want to disable nfsd at startup (/sbin/nfsd) so that I am only sharing folders (I already have working NFS shares setup in /etc/exports), and only have the shares active when I manually run a command. I tried removing executable permissions from /sbin/nfsd, but that means that every time I start the system, I have to change the permissions, and then revert those changes before I shut down. I want to make sure nfsd is disabled by default every startup.

Thank you all in advance for your assistance!
ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 2 Answers and 5 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros