Error running maintainDB, 'maintainDB.[cmd' not recognised as internal or external command'

I am following step 4. of TeamCity 5.x database migration steps below but get error  'maintainDB.[cmd' not recognised as internal or external command'

4. Run the maintainDB tool with the migrate command and specify the absolute path to the newly created target database properties file with -T option:


I am running this from commanad prompt and make sure I am in directory where migrateDB.cmd is as follows:

C:\TeamCity\bin>maintainDB.[cmd|sh] migrate -T c:\TeamCity\temp\database.mssql.properties

Any ideas?
4 comments
Comment actions Permalink

I have change this too

cmd migrate -T c:\TeamCity\temp\database.mssql.properties


which it recognises but now it is saying it does not recognise ' "JAVA", do I need to change anything in the migrateDB.cmd ???

0
Comment actions Permalink

It seems maintain DB tool can't find Java. Please make sure you have JAVA_HOME environment variable pointing to the Java installation directory. Alternatively you can set TeamCity installation directory path to TEAMCITY_HOME_DIR environment variable.

0
Comment actions Permalink

Where about's should I find these environment variables JAVA_HOME and TEAMCITY_HOME_DIR?

0
Comment actions Permalink

Search for "environment variables" in Windows Control Panel.

Thanks
Michael

0

Please sign in to leave a comment.