« Return to Thread: Sonar 1.9 oracle 10g not working

Re: Sonar 1.9 oracle 10g not working

by Magesh :: Rate this Message:

Reply to Author | View in Thread

Thanks Freddy. I was able to cross over that hurdle. i use sonar 1.9.2 and hudson latest (1.311 - i took this id from pom.properites inside the war.) . i have sonar running on box A (wiki.xxx.in[ip 10.xx.x.22]) and hudson on box B(dns: repository.xxxx.in[10.xx.x.58]).  below is the exception i get when hudson tries to connect to database. i even tried setting the values in maven's setting.xml and still same exception. i see that somehow "repository.xxxx.in" getting appended to the username. but in configuration i have only the username

INFO] Sonar host: http://10.xx.x.22:9000

[INFO] Sonar version: 1.9.2

[INFO] [sonar-core:internal]

[INFO] Sonar JDBC URL: jdbc:mysql://10.xx.x.22:3306/sonar?useUnicode=true&characterEncoding=utf8

[INFO] Sonar JDBC login: sonar

[INFO] Sonar JDBC driver: com.mysql.jdbc.Driver

[INFO] Sonar branch:

[INFO] ------------------------------------------------------------------------

[ERROR] BUILD ERROR

[INFO] ------------------------------------------------------------------------

[INFO] Can not execute Sonar



Embedded error: Cannot open connection to database: Access denied for user 'sonar'@'repository.xxxx.in' (using password: YES)

[INFO] ------------------------------------------------------------------------

[INFO] Trace

org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:584)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)

        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)

        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)

        at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)

        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)

        at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)

Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar

        at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:87)

        at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)

        at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)

        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)

        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)

        ... 16 more

Caused by: org.sonar.commons.database.DatabaseException: Cannot open connection to database: Access denied for user 'sonar'@'repository.xxxxx.in' (using password: YES)

        at org.sonar.commons.database.AbstractDatabaseConnector.testConnection(AbstractDatabaseConnector.java:165)

        at org.sonar.commons.database.AbstractDatabaseConnector.start(AbstractDatabaseConnector.java:91)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)

        at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)

        at org.picocontainer.adapters.InstanceAdapter.start(InstanceAdapter.java:113)

        at org.picocontainer.adapters.InstanceAdapter.start(InstanceAdapter.java:91)

        at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:882)

        at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:630)

        at org.sonar.mojo.InternalMojo.createMainContainer(InternalMojo.java:192)

        at org.sonar.mojo.InternalMojo.execute(InternalMojo.java:154)

        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)

        at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)

        ... 20 more

Caused by: java.sql.SQLException: Access denied for user 'sonar'@'repository.xxxx.in' (using password: YES)

        at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)

        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985)

        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:885)

        at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3421)

        at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1247)

        at com.mysql.jdbc.Connection.createNewIO(Connection.java:2775)

        at com.mysql.jdbc.Connection.<init>(Connection.java:1555)

        at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:285)

        at java.sql.DriverManager.getConnection(DriverManager.java:525)

        at java.sql.DriverManager.getConnection(DriverManager.java:171)

        at org.sonar.commons.database.DriverDatabaseConnector.getConnection(DriverDatabaseConnector.java:60)

        at org.sonar.commons.database.AbstractDatabaseConnector.testConnection(AbstractDatabaseConnector.java:163)

        ... 35 more



 
Freddy Mallet wrote:
Hello,
As specified in the Confluence page [1], the Hudson Sonar plugin is
compatible with Hudson 1.306+.

Freddy

[1] - http://wiki.hudson-ci.org/display/HUDSON/Sonar+plugin



On Mon, Jun 22, 2009 at 7:26 PM, Magesh <k_n_magesh@yahoo.com> wrote:

>
> Hudson version version 1.295.
>
>
> Cedric Munger wrote:
> >
> > Hi,
> >
> > Looks like the hudson version you're using is not compatible with our
> > plugin, what version of hudson are you running ?
> >
> > Regards
> >
> > On Mon, Jun 22, 2009 at 2:28 PM, Magesh <k_n_magesh@yahoo.com> wrote:
> >
> >>
> >> I stopped the installation with Oracle due to time constraint so as
> >> recommended i tried the sonar with mysql and was able to bring it up.
> but
> >> again landed up in another problem. while configuring with hudson and
> >> making
> >> a build i come across the exception below and it doest work.
> >>
> >> FATAL:
> >>
> >>
> hudson.tasks.Maven$MavenInstallation.forNode(Lhudson/model/Node;Lhudson/model/TaskListener;)Lhudson/tasks/Maven$MavenInstallation;
> >> java.lang.NoSuchMethodError:
> >>
> >>
> hudson.tasks.Maven$MavenInstallation.forNode(Lhudson/model/Node;Lhudson/model/TaskListener;)Lhudson/tasks/Maven$MavenInstallation;
> >>        at
> >>
> >>
> hudson.plugins.sonar.SonarPublisher.getMavenInstallationForSonar(SonarPublisher.java:204)
> >>        at
> >>
> hudson.plugins.sonar.SonarPublisher.executeSonar(SonarPublisher.java:213)
> >>        at
> >> hudson.plugins.sonar.SonarPublisher.perform(SonarPublisher.java:177)
> >>        at
> >>
> >>
> hudson.model.AbstractBuild$AbstractRunner.performAllBuildStep(AbstractBuild.java:372)
> >>        at
> >>
> >>
> hudson.maven.MavenModuleSetBuild$RunnerImpl.post2(MavenModuleSetBuild.java:487)
> >>        at
> >> hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:345)
> >>        at hudson.model.Run.run(Run.java:919)
> >>        at
> >> hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:234)
> >>        at
> >> hudson.model.ResourceController.execute(ResourceController.java:93)
> >>        at hudson.model.Executor.run(Executor.java:119)
> >>
> >> Sonar runs on windows machine and hudson runs on sun solaris. Could you
> >> help
> >> me out pls
> >>
> >> Freddy Mallet wrote:
> >> >
> >> > Hello Magesh,
> >> > Thanks for this log file !
> >> > Could you connect to your oracle sonar db and give the structure of
> the
> >> > "events" table : id and type of each columns ?
> >> >
> >> > Could you also provide the version or your jdbc driver ?
> >> >
> >> > Freddy
> >> >
> >> > On Wed, Jun 17, 2009 at 2:57 AM, Magesh <k_n_magesh@yahoo.com> wrote:
> >> >
> >> >>
> >> >> Hi Freddy,
> >> >> i have attached the wrapper.log with this.
> >> >>
> >> >> i have tried more than once doing this install for oracle.
> >> >>
> >> >>
> >> >> http://www.nabble.com/file/p24065343/wrapper.log wrapper.log
> >> >>
> >> >>
> >> >>
> >> >> Freddy Mallet wrote:
> >> >> >
> >> >> > Hello Magesh,
> >> >> > Could you provide the content of your ${sonar_home}/log/wrapper.log
> >> >> file
> >> >> ?
> >> >> > Indeed, the given error stack trace is a consequence but not the
> >> root
> >> >> > cause.
> >> >> >
> >> >> > Thanks
> >> >> > Freddy
> >> >> >
> >> >> > On Tue, Jun 16, 2009 at 7:43 PM, Magesh <k_n_magesh@yahoo.com>
> >> wrote:
> >> >> >
> >> >> >>
> >> >> >> When i tried to configure sonar with oracle 10g it not even
> >> installing
> >> >> >> properly. when i tried to access the application it says "sorry
> try
> >> >> >> again"
> >> >> >> below is the exception . can anyone help me in this pls
> >> >> >>
> >> >> >> Caused by: javax.persistence.PersistenceException:
> >> >> >> org.hibernate.HibernateException: Missing column: id in
> >> CIDEV.EVENTS
> >> >> >>        ... 117 common frames omitted
> >> >> >> Caused by: org.hibernate.HibernateException: Missing column: id in
> >> >> >> CIDEV.EVENTS
> >> >> >>        at
> >> org.hibernate.mapping.Table.validateColumns(Table.java:254)
> >> >> >> [hibernate-3.2.6.ga.jar:3.2.6.ga]
> >> >> >>        at
> >> >> >>
> >> >>
> >> org.hibernate.cfg.Configuration.validateSchema(Configuration.java:1089)
> >> >> >> [hibernate-3.2.6.ga.jar:3.2.6.ga]
> >> >> >>        at
> >> >> >>
> >> >> >>
> >> >>
> >>
> org.hibernate.tool.hbm2ddl.SchemaValidator.validate(SchemaValidator.java:116)
> >> >> >> [hibernate-3.2.6.ga.jar:3.2.6.ga]
> >> >> >>        at
> >> >> >>
> >> >>
> >>
> org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:317)
> >> >> >> [hibernate-3.2.6.ga.jar:3.2.6.ga]
> >> >> >>        at
> >> >> >>
> >> >> >>
> >> >>
> >>
> org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1300)
> >> >> >> [hibernate-3.2.6.ga.jar:3.2.6.ga]
> >> >> >>        at
> >> >> >>
> >> >> >>
> >> >>
> >>
> org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:859)
> >> >> >> [hibernate-
> >> >> >> --
> >> >> >> View this message in context:
> >> >> >>
> >> >>
> >>
> http://www.nabble.com/Sonar-1.9-oracle-10g-not-working-tp24059373p24059373.html
> >> >> >> Sent from the Sonar user mailing list archive at Nabble.com.
> >> >> >>
> >> >> >>
> >> >> >>
> >> ---------------------------------------------------------------------
> >> >> >> To unsubscribe from this list, please visit:
> >> >> >>
> >> >> >>    http://xircles.codehaus.org/manage_email
> >> >> >>
> >> >> >>
> >> >> >>
> >> >> >
> >> >> >
> >> >>
> >> >> --
> >> >> View this message in context:
> >> >>
> >>
> http://www.nabble.com/Sonar-1.9-oracle-10g-not-working-tp24059373p24065343.html
> >> >> Sent from the Sonar user mailing list archive at Nabble.com.
> >> >>
> >> >>
> >> >> ---------------------------------------------------------------------
> >> >> To unsubscribe from this list, please visit:
> >> >>
> >> >>    http://xircles.codehaus.org/manage_email
> >> >>
> >> >>
> >> >>
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/Sonar-1.9-oracle-10g-not-working-tp24059373p24146368.html
> >> Sent from the Sonar user mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe from this list, please visit:
> >>
> >>    http://xircles.codehaus.org/manage_email
> >>
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Sonar-1.9-oracle-10g-not-working-tp24059373p24151829.html
> Sent from the Sonar user mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>

 « Return to Thread: Sonar 1.9 oracle 10g not working