[X4U] Turn on file sharing from the Terminal?

Stroller MacMonster at myrealbox.com
Thu Apr 14 03:26:20 PDT 2005


On Apr 14, 2005, at 2:47 am, Peter Krug wrote:
> Sooo....  If I type the lines below in the terminal, it will turn on 
> file sharing?

Erm... no. Did you read the `defaults` manpage? Did you look at  
/Library/Preferences/com.apple.sharing.firewall.plist on a working 
system? Clearly I've left you with a little bit of homework of your own 
to do.

The command I would use to achieve this would be _something like_:
   defaults write /Library/Preferences/com.apple.sharing.firewall.plist 
"FTP Access" enable '1'

> Keep in mind that I cannot see what I am typing.  If I screw this up, 
> will it completely hose the OS?

Well, clearly you'll try this on another machine & get it perfect 
before performing it on the affected machine. If you can't see what 
you're typing now, I guess you'll ask your "suportees" to enable ssh 
access in future.

> What if I copy a com.apple.sharing.firewall.plist from a computer that 
> does have file sharing turned on into the other computer's 
> /Library/Preferences (via target mode).

I would have thought that would work. Preferably bring back the 
affected system's com.apple.sharing.firewall.plist & edit that. Using 
Property List Editor, which is amongst the development tools.

> It will be difficult to get the file into the proper place on the 
> damaged computer since I don't even know if it will recognize another 
> computer in target mode, not to mention the authentication issues 
> getting /Library access on the damaged computer.

You can't run the damaged machine in target mode?

> It's not fun running blind...

I guess you'll ask your "suportees" to enable ssh access in future.

Stroller.



More information about the X4U mailing list