sudo -u postgres /opt/vmware/vpostgres/1.0/bin/vacuumdb -a -e -v -f -U postgres > /tmp/vacuumdb.log
above is the actual command with '>', are you using that or did you really miss that '>' (output redirection) to particular log file.
since the error is telling that what you are using is not working syntax. So I thought of pointing it to you.
Narendra Padmani
VCIX6-DCV | VCIX7-CMA | VCI | TOGAF 9 Certified