Re: Enable Personal File Sharing programatically?
Re: Enable Personal File Sharing programatically?
- Subject: Re: Enable Personal File Sharing programatically?
- From: Andrei Tchijov <email@hidden>
- Date: Tue, 16 May 2006 19:13:31 -0400
My fault. Should not answer any e-mails before I got my coffee.
Actually it is even simpler with AFP. This is straight from "man
AppleFileServer"
...
The AppleFileServer can also be launched from the terminal (this must be
done as root user). This is done by typing:
AppleFileServer [-d]
The -d option will prevent daemonization.
...
On May 16, 2006, at 6:38 PM, Shawn Erickson wrote:
On 5/16/06, Andrei Tchijov <email@hidden> wrote:
When your user enables/disables Windows Sharing, the only things
which get changed are launchd's *.plist files responsible for SMB
sharing
/System/Library/LaunchDaemons/nmbd.plist and
/System/Library/LaunchDaemons/smbd.plist
When Windows sharing is disabled, both these files have 'Disabled =
true'. You should be able to enable/disable Windows sharing by
"unloading" these 2 things with launchctl, changing these 2 files and
then loading them back (with launchctl). You do need root privileges
to do it.
Those files are owned and only writable by root:wheel (you will need
admin authorization).
[0:518] > ll /System/Library/LaunchDaemons/nmbd.plist
/System/Library/LaunchDaemons/smbd.plist
-rw-r--r-- 1 root wheel 675B Nov 4 2005
/System/Library/LaunchDaemons/nmbd.plist
-rw-r--r-- 1 root wheel 778B Nov 4 2005
/System/Library/LaunchDaemons/smbd.plist
Also I believe he is asking about personal file sharing (AFP) not
windows file sharing.
-Shawn
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden