replaced realpath cmd w/ readlink for el6 compatibility