By the way, it's not a good practice to run any process as root or login to a database or other application as root. Root is a security risk so it's best to setup another, less privileged user account. [ September 17, 2006: Message edited by: Scott Johnson ]
Joined: Jan 15, 2006
You probably have mistyped the password as root is root or are trying to connect right after the install using a password and by default it is blank.
Sometime in jdbc urls, depending on how localhost resolves, it is better to use the numeric IP equivalent 127.0.0.1 instead of localhost.
The security concerns mentioned here are very much valid so create a user and a database connect on the command line/prompt and then try it in jdbc that way you will narrow down the problem.