MAVEN BASIC USAGE - mvn openmrs-sdk:setup

Maven installation is okay and running in cmd but under basic usage, mvn openmrs-sdk:setup, displays build failure like below. Also, database password does not allow typing.

Where do you think is the problem?

from cmd;

The distribution requires MySQL database. Please specify database uri (-DdbUri) (default: ‘jdbc:mysql://localhost:3306/@DBNAME@’):

Please specify database username (-DdbUser) (default: ‘root’): Rootroot Please specify database password (-DdbPassword) (default: ’ '): [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 06:54 min [INFO] Finished at: 2019-07-25T21:24:25+03:00 [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.openmrs.maven.plugins:openmrs-sdk-maven-plugin:3.13.2:setup (default-cli) on project standalone-pom: Failed to setup server: Failed to connect to the specified database jdbc:mysql://localhost:3306/server1?autoReconnect=true&sessionVariables=default_storage_engine%3DInnoDB&useUnicode=true&characterEncoding=UTF-8 -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1]

C:\Users\hp>-e switch ‘-e’ is not recognized as an internal or external command, operable program or batch file.


@mmark database username is root by default so just press enter. The password won’t be reflected but just ensure what you are typing is right.

@mmark please set the database username to “root” and press enter. when it comes to the Database password, the entries don’t display as you type. its a password security measure. So don’t worry just continue entering the exact password you created while setting up your MySQL server then press enter

@mmark have you tried the above steps,are things working out if not kindly get here and we get everything started!

Hi @mmark

Make sure to create the db before u set up the openmrs server which it will be using. Then use mvn openmrs-sdk:setup ti set up the server.When it’s asking for the db uri make sure to point it to the db u created previously :v:

1 Like

Thank you very much.

It worked perfectly.

1 Like

Thank you very much for that helpful tip. It worked out perfectly.


Yes, things are okay. Thanks

That was already perfect. Thanks


Now am wondering what next after the complete setup (http://localhost:8080/openmrs/admin/index.htm) because the page with the installation progress is done. Now redirected to the login page.

I have used admin as username and Adnin123 as the password and logged in.

How do i conclude this session in command line?

elaborate more on what you need

You don’t need the command line now. Concentrate on the UI, play around with it and see how the app works.

@mmark meaning of conclude??

Thank you Juliet. Its perfect.

Hi @mmark

What do u mean by concluding?

Logout :- theres a logout button.It’s not possible that some one can miss it :slightly_smiling_face:.

Stop the server :- ctl + z Restart again :- mvn openmrs-sdk:run

Thank you very much