Passing backend server host name as a custom header with Nginx

When using load balanced web servers it’s often useful to know which server processed the request. There is a simple unobtrusive method to achieve this with the Nginx web server. Nginx conveniently populates the server’s real host name to the $hostname variable, meaning that you can simply output this to a custom header in the global config file:

http {
    # Show server host name as header
    add_header X-Backend-Server $hostname;

Another problem with VMware Tools solved

The issues with 3.8+ kernel that I posted about previously have been resolved in newer versions of VMware Tools, but unfortunately the latest version 9.6.1 (bundled with Fusion 6.0.2) brings along more problems with the file sync driver. The issue causes deletions within files to be reflected in the guess OS as truncation at the end of the file.

There is a very simple solution to this, it’s reasonably well documented on the VMware forums and the developer has also responded informing us that a fix is in progress, however I thought it would be useful to collate all the information into a single post.

The fix is simply to downgrade the tools back to 9.6.0, however I’ve noticed that a lot of people have had issue with this as the default behaviour is to auto upgrade, putting your right back to version 9.6.1.

Firstly you need to edit the vmx file of your VM (In some versions of VMware I think you can change this in the GUI, but I couldn’t find this option in Fusion), I would suggest shutting it down completely before doing this. In the terminal you can navigate into the VM folder and use a text editor to do this. Look for the setting “tools.upgrade.policy” which seems to default to “upgradeAtPowerCycle” and ensure this is set to “manual”, the save any change if necessary.

Finally, download the relevant tools package from, untar/unzip it several times and perform the standard tools installation process (below example is for Linux guests):

tar -xf
sudo mkdir /mnt/iso
sudo mount -o loop payload/linux.iso /mnt/iso
cp /mnt/iso/VMwareTools-9.6.0-1294478.tar.gz .
tar xzf VMwareTools-9.6.0-1294478.tar.gz
cd vmware-tools-distrib/
sudo ./