Mac Unix Help
Set Software Update Server
Works best when run as root using Sudo.
defaults write /Library/Preferences/com.apple.SoftwareUpdate CatalogURL "<url/ip address>:<tcp port>"
Turn Off NFS Automounting
This fixes some login issues when binding to Active Directory in 10.4 and 10.5.
Source: http://www.afp548.com/forum/viewtopic.php?showtopic=17096#17440
`perl -p -i.bak -e 's/AUTOMOUNT=-YES-/AUTOMOUNT=-NO-/' /etc/hostconfig`;
Disable IPv6 on all network 802. based interfaces.
#!/usr/bin/perl
$ntwksetup = "/System/Library/CoreServices/RemoteManagement/ARDAgent.app/Content
s/Support/networksetup";
@services=split(/\n/,`$ntwksetup -listallnetworkservices | grep -e Air -e 'Built
-in Ether'`);
foreach $service (@services) {
print LOGFILE "Turning off IPv6 for $service...";
$result=`/System/Library/CoreServices/RemoteManagement/ARDAgent.app/Cont
ents/Support/networksetup -setv6off '$service'`;
if ($result == 0){
print LOGFILE "Done\n";
} else {
print LOGFILE "\n*******Error********\n...$result\n\n";
}
}
Enabling ssh known_hosts as auto complete entries
complete -W "$(echo `cat ~/.ssh/known_hosts | cut -f 1 -d ' ' | sed -e s/,.*//g | uniq | grep -v "\["`;)" ssh
source: Mac OS X Hints
Fix Tab-completion in >10.5
echo "set mark-symlinked-directories on" >> ~/.inputrc
the version of Bash included in Leopard and beyond doesn’t automatically add the / after symlinked directories, which i find stupid as hell. I complained about it to Apple and that’s what i got back from engineering as the fix.