Problem with login to webGUI

9 replies
ace
ace's picture
Joined: 12/07/2009
User offline. Last seen 32 weeks 6 days ago.

First,

thanks guys for good job you're doing here.

OK, I downloaded a .deb package to my distro (Debian lenny) install it using dpkg -i , configure it and everything went fine. Next step was to find greensql-console and run it. Ok, I found, did what I have to do, then go to http://192.168.66.161/grennsql - ok, that gave me a login page, and here is the problem :

1. what is the login and pass to login, except demo version where is admin:pwd, do I have to add another user into database ?

2. why I get an error like that " Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /var/www/greensql/lib.php on line 146 " -

Thx

elishemer
elishemer's picture
Joined: 12/03/2009
User offline. Last seen 31 weeks 2 days ago.

hey there Ace,

i cant put my finger on it specifically,
but check the following:

1. make sure that you can login with the mysql user and password written in config.php.
mysql -u -p

also check that the table "admin" exists and looks something like this:

mysql> select * from admin;
+---------+-------+------------------------------------------+-------+
| adminid | name | pwd | email |
+---------+-------+------------------------------------------+-------+
| 1 | admin | 37fa265330ad83eaa879efb1e2db6380896cf639 | |
+---------+-------+------------------------------------------+-------+
1 row in set (0.00 sec)

the default user and password is indeed "admin" and "pwd", which are used from the table.
the pwd column is simply encrypted.

2. make that that the php5-mysql package is installed although it seems like it is

ace
ace's picture
Joined: 12/07/2009
User offline. Last seen 32 weeks 6 days ago.

Hi elishemer, thanks for replay

Unfortunately, I have to say that you're right but wrong turn :) because:

1. I can login with data provided in config.php, for example: greens:greens

2. table "admin" exist and contains proper data, admin:pwd

3. package php5-mysql is installed and is already in the newest version

4. I even installed Smarty :) :)

any other idea ??

thx

elishemer
elishemer's picture
Joined: 12/03/2009
User offline. Last seen 31 weeks 2 days ago.

hey Ace

I just noticed something in the error message you provided earlier

the greensql-console is supposed to be installed to /usr/share/greensql-fw/
not to /var/www/ in the new version

try to see if you have the apache DocumentRoot directing to the old directory

ace
ace's picture
Joined: 12/07/2009
User offline. Last seen 32 weeks 6 days ago.

hey elishemer

ok, i will put greensql-console in /usr/share/greensql-fw/ as you suggest, then we will see

but I think I should make an alias to this directory in apache, right

elishemer
elishemer's picture
Joined: 12/03/2009
User offline. Last seen 31 weeks 2 days ago.

actually the files should be in there flat, not a directory within that directory

you can have a look at this howto: http://www.greensql.net/howto
Yuli there run the following:
cd /var/www && ln -s /usr/share/greensql-fw/ greensql

so you can have /var/www/greensql/ configured in apache.conf
even though the files are really in /usr/share/greensql-fw/*.php

you can also take a look at /etc/greensql/greensql-apache.conf if it's of any help for some examples

cheers

ace
ace's picture
Joined: 12/07/2009
User offline. Last seen 32 weeks 6 days ago.

Hi elishemer

I did as yuli described in howto point 5 , thats OK
even uncomment needed lines in greensql-apache.conf and then try to login again

and of course got the same error
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /var/www/greensql/lib.php on line 146

got even a pop-up with Smarty Debug Console

and still have no idea how to fix it

yuli
yuli's picture
Joined: 01/30/2008
User offline. Last seen 2 days 2 hours ago.

Hello

It is possible that SElinux is installed on your server. Please check the readme.txt file.

http://greensql.svn.sourceforge.net/viewvc/greensql/trunk/greensql-conso...

Yuli

ace
ace's picture
Joined: 12/07/2009
User offline. Last seen 32 weeks 6 days ago.

Hi guys,

OK, i asked for help my friend and he said that everything works fine.

So, it was my fault because
- I read yuli howto, did as he wrote and then I don't know why I was trying to run greensql-console,
- there's no need to install smarty
- I was trying to fix mess I did, after all I had to reinstall complete system

sorry guys for wasting ur time and my blindless

thx guys once again

NicolasB
NicolasB's picture
Joined: 01/19/2010
User offline. Last seen 25 weeks 6 days ago.

I have a Problem,

I installed greensql on a ubuntu server (9.10) database & user got created, and everything went fine

when i access the webinterface, it shows up, but login fails.

This means, i put in the username and password (admin:pwd) click on login and get redirected straight to the loginpage.

There are no error messages, nothing in the greensql log etc

Back to top