UPDATE: THIS INFORMATION IS INCORRECT AND CAN LEAD TO KERNEL PANICS
On linux servers where interfaces are multi homed on the same subnet there is a very common issue. You can not determine or set what IP address is used to source connections. This can make a security nightmare when trying to lock down services to a single IP that keeps changing. Do not fear, There is a way to force outgoing connections to use a specific ip address.
This little trick uses IPtables and is something known as source nat’ing. It does the exact opposite as regular nat or DNAT. So go grab some IPtables binaries if you dont already have them and we shall get started.
# iptables -t nat -A POSTROUTING -m state --state new -j SNAT --to-source 1.2.3.4
That is all that is required. All new connections ie connections originating from the box will be forced to use the IP address of 1.2.3.4
Mac OS does something weird with some font files. Basically it stores the data in two separate places which means that copying using scp or rsync tends to fail. This use of resource forks makes it incredibly difficult to copy these files without using the Finder.
RsyncX HFS is one option, its a version of rsync that supports resource forks.
Another option though is to use the command line utility ditto. This comes with OS X and essentially allows you to compress all of the files into a single copyable file. You can use it like this, but you could rtfm.
Create an archive:
ditto -c --rsrc SourceDirContainingFonts AnyOldFileName
You could then zip that (although ditto may support compression… rtfm), scp it to another location. To unarchive simply:
ditto -x --rsrc AnyOldFileName DestinationDir
You can do the archie-copy-unarchive in one go too:
ditto -c --rsrc SourceDirContainingFonts - | ssh user@host 'ditto -x --rsrc - DestinationDir'
Obviously, you can use this for anything, not just fonts. But its fonts that caused me the grief!
Have you ever been doing some administration and *poof* everything has frozen nothing works the only thing left to do is restart the system right?
wrong!
There is a lesser known panic button built in to the kernel that will gracefully restart everything by stopping daemons and dismounting drives.
To do this you must hold alt+SysReq (PrintScreen) and type “REISUB” (busier backwards) you may or may not get kernel messages printed to the screen if you dont after finishing typing the system will gracefully restart.
This is made possible by a feature of the linux kernel that some perople refer to as the “magical sysreq commands”. More information on this can be found Here.