Update preflight.sh to support Ubuntu 12