Wednesday, June 20, 2012

NX Client for MacOS/X was not able to find the Apple X11 Server

Although XQuartz is already installed, NoMachine NX Client (v3.5.0-7) on OS X 10.6 will complain about not being able to find Apple X11 in /Applications or /Applications/Utilities.

You can download and install X11 for OS X 10.6 from here (just not sure if it will install without first uninstalling XQuartz because XQuartz may be newer).

Or, simpler, create a symlink /Applications/Utilities/X11.app to point to /Applications/Utilities/XQuartz.app:
$ sudo ln -s /Applications/Utilities/XQuartz.app /Applications/Utilities/X11.app

Thursday, May 10, 2012

Use wget to recursively get contents of a directory

Sometimes, it's just necessary to explore the directory space on a remote dir to know what are the specific keys that can be queried individually.
This is particularly convenient in the case of cloud instance metadata where one would like to find out what are all the metadata keys that are available for a given instance on a given cloud.

So, to download the complete directory tree recursively, use the following command (this example uses the 'default' cloud instance metadata server):

$ wget -rk Is http://169.254.169.254/latest/meta-data/