Forum Problems Installing LAMS: installation on debian sarge fails


 
You may request notification for installation on debian sarge fails.
Search: 

1: installation on debian sarge fails
10/31/05 11:35 AM
[ Reply | Forward ]
Hello,

I'm trying to install lams 1.0.1 (from the zip-file) on a debian sarge system. The installation skript prints an error message about mysql login >>'lams'@'%'<< and proceeds. Tomcat gets started, but there is only an error message if I try to access the lams website
http://servername:8080/ or http://servername:8080/lams/

I have alreade modified the build.xml, and mysql files and substituted all occurences of % with localhost, but it doesn't change anything, i also tried to install the database manually  and didn't work.

Has anybody successfully installed lams on a debian system and could give me some hints?

Posted by David Prüm

2: Re: installation on debian sarge fails
In response to 1 10/31/05 05:59 PM
[ Reply | Forward ]
I haven't used Debian before, but I've installed on Ubuntu (based on Debian?)... I had trouble with the hostname for the lams user:

<!--
        # Tell Ant the hostname of the MySQL server that
        should be put in the MySQL grant able.
        MySQL seems unhappy with just 'localhost' or '%'
        in the grant table, in order to be able to connect
        from a client on the server itself.
        You can use either the hostname or the IP address,
        that is in the server's /etc/host file.
    -->
    <property name="mysql.hostaddress" value="localhost"/>

where 'localhost', '127.0.0.1' didn't work, but using the public IP address of the machine did.  It might also be worth checking the database manually, to see if the tables and the lams user were created.

Posted by Jun-Dir Liew

3: Re: Re: installation on debian sarge fails
In response to 2 11/02/05 12:29 PM
[ Reply | Forward ]
I tried several variations but it did not work.
I think the problem is a syntax error somewhere but can't find it. 'root'@'%' ist definitely no valid database user. Login for DB-user root ist allowed from localhost, hostname and %
I get the following error message:

Buildfile: build.xml

db-prep-only:

prep_db:
[echo] This creates the database and sets username/password
[sql] Executing commands
[sql] Failed to execute: GRANT ALL PRIVILEGES ON lams01.* TO lams@localhost IDENTIFIED BY 'my password'

BUILD FAILED
/home/pruem/lams/lams-server1.0.1/lams-package/ant/build.xml:258: The following error occurred while executing this line:
/home/pruem/lams/lams-server1.0.1/lams-package/ant/build.xml:459: java.sql.SQLException: Syntax error or access violation, message from server: "Access denied for user 'root'@'%' to database 'lams01'"

Total time: 0 seconds
Buildfile: build.xml

db-prep-only:

prep_db:
[echo] This creates the database and sets username/password
[sql] Executing commands
[sql] Failed to execute: GRANT ALL PRIVILEGES ON lams01.* TO lams@localhost IDENTIFIED BY 'Foh7nooj'

BUILD FAILED
/home/pruem/lams/lams-server1.0.1/lams-package/ant/build.xml:258: The following error occurred while executing this line:
/home/pruem/lams/lams-server1.0.1/lams-package/ant/build.xml:459: java.sql.SQLException: Syntax error or access violation, message from server: "Access denied for user 'root'@'%' to database 'lams01'"

Posted by David Prüm

5: Re: Re: Re: installation on debian sarge fails
In response to 3 11/14/05 01:19 AM
[ Reply | Forward ]
David,

You might want to try with the new version of LAMS. We have simplified the installation build.xml a bit. You can download it from the LAMS Foundation site (all other platform installer).

Thanks,

Ernie

Posted by Ernie Ghiglione

4: Re: installation on debian sarge fails
In response to 1 11/02/05 06:36 PM
[ Reply | Forward ]
Have you tried logging into mysql from the command line using user 'root'? It seems funny that the error says access denied for 'root'@'%' when as you say there are already entries for 'localhost' and '$hostname', which I presume should be looked at first by mysql.

Things I would look at are probably to make sure that the mysql.root.password is enclosed in quotation marks; that you can successfully login with the same credentials manually using the mysql client; that the mysql.user table does contain entries for user 'root' with 'localhost' and '$hostname'; and that the entries in /etc/hosts contains your hostname.

If you can login to mysql with root but for some reason can't get the ant target to work, you can always run the db-prep-only target manually - i.e., just run the script called 'grant.sql' which is in the lams-package/sql folder. You must modify the user details in the script first of course. After that you can simply run 'ant install', as this ant target has no need of the mysql root user.

Posted by Jun-Dir Liew

6: Re: installation on debian sarge fails
In response to 1 11/14/05 03:26 AM
[ Reply | Forward ]
Thanks for all your help,

finally I got it installed.
The Problem was indeed somwhere with the database hostname.

All other applications on this system accepted localhost, but lams did not.

I must say i find the error message not really helpful.

I'm still in the testing phase, so I will wait, perhaps for the next major release, before my next upgrade.

Posted by David Prüm

7: Re: Re: installation on debian sarge fails
In response to 6 11/14/05 05:44 AM
[ Reply | Forward ]
Hi David,

Glad to hear that you got it flying...

In case you want to upgrade, here you can find the instructions on how to upgrade manually.

Thanks,

Ernie

Posted by Ernie Ghiglione

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