Fixed database path errors. Fixed commandline problems related to optimizer files not being found.