Forum Problems Installing LAMS: Problem when ant prepare-db


 
You may request notification for Problem when ant prepare-db.
Search: 

1: Problem when ant prepare-db
01/19/06 05:17 PM
[ Reply | Forward ]
Sorry if this is a simple question, but I can't figure out what this means failed at all. If somone could explain how to fix this it would be most helpful. Thanks:

Buildfile: build.xml
[taskdef] Could not load definitions from resource net/sf/antcontrib/antcontri b.properties. It could not be found.

BUILD FAILED
file:/home/jeremy/lams-server1.0.2/lams-package/ant/build.xml:30: taskdef class net.sf.antcontrib.logic.IfTask cannot be found

Posted by Jeremy Shankle

2: Re: Problem when ant prepare-db
In response to 1 01/19/06 06:57 PM
[ Reply | Forward ]
antcontrib.properties is a file contained in the ant-contrib-0.6.jar library located in /home/jeremy/lams-server1.0.2/apache-ant/lib (or some other folder, if you have ant elsewhere on your system).

Try using the ant included in the lams-server package, or alternatively try replacing that file with a more recent version from http://ant-contrib.sourceforge.net/

Posted by Jun-Dir Liew

3: Re: Problem when ant prepare-db
In response to 1 01/25/06 11:33 AM
[ Reply | Forward ]
Thanks.  That problem ended up being due to the way Fedora Core 2 doesn't allow you to change where ant is located.  I had to put ant-contrib-0.6.jar in the directory where Fedora thought it should be.
However, i have a new problem :-).
Now I am doing it in Red Hat 4
When I run ant prepare-db I get this:
BUILD FAILED
/home/jeremy/lams-server1.0.2/lams-package/ant/build.xml:132: The following error occurred while executing this line:
/home/jeremy/lams-server1.0.2/lams-package/ant/build.xml:309: com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception:

** BEGIN NESTED EXCEPTION **

java.net.UnknownHostException
MESSAGE: jeremy: jeremy

STACKTRACE:

java.net.UnknownHostException: aretao: aretao
        at java.net.InetAddress.getAllByName0(InetAddress.java:1128)
        at java.net.InetAddress.getAllByName0(InetAddress.java:1098)
        at java.net.InetAddress.getAllByName(InetAddress.java:1061)
        at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:137)
        at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:284)
        at com.mysql.jdbc.Connection.createNewIO(Connection.java:2541)
        at com.mysql.jdbc.Connection.<init>(Connection.java:1474)
        at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
        at org.apache.tools.ant.taskdefs.JDBCTask.getConnection(JDBCTask.java:304)
        at org.apache.tools.ant.taskdefs.SQLExec.execute(SQLExec.java:347)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
        at org.apache.tools.ant.Task.perform(Task.java:364)
        at org.apache.tools.ant.Target.execute(Target.java:341)
        at org.apache.tools.ant.Target.performTasks(Target.java:369)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1214)
        at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:386)
        at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:106)        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
        at org.apache.tools.ant.Task.perform(Task.java:364)
        at org.apache.tools.ant.Target.execute(Target.java:341)
        at org.apache.tools.ant.Target.performTasks(Target.java:369)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1214)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1062)
        at org.apache.tools.ant.Main.runBuild(Main.java:673)
        at org.apache.tools.ant.Main.startAnt(Main.java:188)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:196)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:55)


I really have no idea what I am doing wrong, thanks for the help, I'm really trying to work through how to install lams.  I managed to install it on a server a few months ago, but it had nothing on it.  This one has tomcat and java 1.5 jdk installed.  Do I need to go to 1.4.2 sdk?
Thanks

Posted by Jeremy Shankle

4: Re: Problem when ant prepare-db
In response to 1 01/26/06 12:52 PM
[ Reply | Forward ]
Actually, here is the 'correct' error message I think. I am not allowed to access mysql from the command line for some reason. Does anyone know the easiest way to allow this?
BUILD FAILED
/home/aretao/lams-server1.0.2/lams-package/ant/build.xml:132: The following error occurred while executing this line:
/home/aretao/lams-server1.0.2/lams-package/ant/build.xml:309: java.sql.SQLException: Access denied for user 'root'@'aretao.secureserver.net' (using password: YES)

Posted by Jeremy Shankle

5: Re: Problem when ant prepare-db
In response to 1 01/26/06 02:32 PM
[ Reply | Forward ]
Nevermind, my bad.

Posted by Jeremy Shankle

6: Re: Problem when ant prepare-db
In response to 1 01/30/06 01:44 AM
[ Reply | Forward ]
What was the problem, how'd you get around it?

Yes, you'll need to have JDK 1.4.2 on your system - set JAVA_HOME to it in lams.conf and you'll be right. If you have another Tomcat server running on your machine though, you'll have to do a bit more fiddling to get LAMS and your Tomcat server to run *at the same time*. But that's a topic for another thread...

The error messages mean you got one of these details wrong for logging into mysql: username, password, and/or hostname. You may have to use 'localhost', or 'localhost.localdomain' to get it just right for your system (some linux systems use 'localhost.localdomain' over 'localhost' which confuses sometimes). Check www.mysql.com for support pages about accessing mysql on your particular linux system.

Posted by Jun-Dir Liew

Reply to first post on this page
Back to Problems Installing LAMS