When performing a 5.x upgrade from 4.x, the 5.x installer fails with a "Non-standard database install detected" error followed by either a "Database datafiles are in a non-standard location" message or a "Database binaries are in a non-standard location" message.
You may get this message if an install was interrupted before it completed which left the installation in an unknown, partially installed state. This could also happen if a previous install failed due to having a locale on the machine that was not UTF8-compliant. If the solution is not apparent, your first course of action would be to remove the following "DB_*" entries from the acserver.cnf and reinstall:
DB_DRIVER = Postgres
DB_CONNECT = localhost:5075@accurev
DB_USER = acserver
DB_PASS = e8c5ed8f07bfaf44d25129ec4e868626
DB_HOME = /opt/accurev/postgresql
If that fails to resolve the problem, your best course of action may be to uninstall (be sure there's a backup of the storage directory first) and go through the full install procedure again.