[GeoNetwork-users] Gast error for setupdb?

Hey Folks,

The compile instructions worked out ncely, it at least gave me gast.jar

I figured since I was running headless and gast.sh was trying for X11
and I could not pass the setupdb option I defaulted back to my original
list I was following and called GAST directly

The following is the command I initiated and the output it generated.

It still wants to start X11 on the headless machine but seems to not
setup the db stuff due to an invalid port number...

samper@anonymised.com:~/domains/samper.crazykids.ca/public_html/geonetwork/gast$
java -jar gast.jar -setupdb
Loading
/home/samper/domains/samper.crazykids.ca/public_html/geonetwork/bin/jetty.xml
2009-07-07 13:18:21.703::INFO: Logging to STDERR via
org.mortbay.log.StdErrLog
Jetty on Host: localhost
Jetty on Port: 8090
java.sql.SQLException: Illegal connection port value '3306:geonetwork'

So I checked to see what port mysql expects

samper@anonymised.com:~/domains/samper.crazykids.ca/public_html/geonetwork/gast$
ps aux | grep mysql
root 20022 0.0 0.2 1772 528 pts/2 S 13:13 0:00 /bin/sh
/usr/bin/mysqld_safe
mysql 20061 0.3 9.5 127908 18164 pts/2 Sl 13:13 0:02
/usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql
--pid-file=/var/run/mysqld/mysqld.pid --skip-external-locking
--port=3306 --socket=/var/run/mysqld/mysqld.sock
root 20062 0.0 0.3 2920 692 pts/2 S 13:13 0:00 logger
-p daemon.err -t mysqld_safe -i -t mysqld

for some reason it looks like mysql is running in safe mode on one line,
but also running in normal mode bellow it and the port seems to match.

ideas?

Dave Sampson wrote:

java.sql.SQLException: Illegal connection port value '3306:geonetwork'

JDBC is trying to connect to
the port '3306:geonetwork',
instead of to the port '3306'.

Typo in the database configuration?

Have a look in
web/geonetwork/WEB-INF/config.xml

for the database config that
is enabled, i.e., which begins with:
<resource enabled="true">

(If you configured using GAST,
it will be the section headed
"mckoi standalone", even if
you changed the driver to MySQL.)

You should have a line something like: <url>jdbc:mysql://localhost:3306/geonetwork</url>

Maybe you have:
<url>jdbc:mysql://localhost:3306:geonetwork</url>

--
Richard Walker
Software Improvements Pty Ltd
Phone: +61 2 6273 2055
Fax: +61 2 6273 2082

I wrote:

You should have a line something like: <url>jdbc:mysql://localhost:3306/geonetwork</url>

Maybe you have:
<url>jdbc:mysql://localhost:3306:geonetwork</url>

Oh, I notice that step 4 of the instructions at
http://trac.osgeo.org/geonetwork/wiki/InstallAndConfig
said:
"set resource/config/url to jdbc:mysql:HOSTNAME:PORT:DATABASE_NAME"

That's not helpful!

It must be jdbc:mysql://HOSTNAME:PORT/DATABASE_NAME

You were only following instructions - and those
instructions were (it seems) not only incomplete,
but wrong. I've now changed the wiki page to
fix this setting - but I didn't add any extra
steps. Feel free to register yourself on the wiki
and make any additions you think would be helpful
based on what you've found out with your
installation . . . .

--
Richard Walker
Software Improvements Pty Ltd
Phone: +61 2 6273 2055
Fax: +61 2 6273 2082