Gossamer Forum
Home : Products : Gossamer Links : Pre Sales :

Access denied error

Quote Reply
Access denied error
Hello all,

I installed Links SQL 1.11 successfully once, and then I removed it. I forgot what I did afterwards. But now I tried to start again and I got the following message running setup.cgi:

Welcome to Links SQL Setup!
---------------------------
Loading SQL definitions and DBD::mysql.
SQL.mysql file loaded.
DBD::mysql ... ok!

Creating Links::DBSQL Database object.
Loading ... ok!

Connecting to the database.
Unable to connect! Error message:
DBSQL (6787): Fatal Error: Unable to connect to the SQL server. Reason: Access denied for user: 'libej@viator.ucs.indiana.edu' (Using password: YES) at setup.cgi line 240

Aborting.. please confirm your database connection information.

Any idea why? How should I fix it?

Thanks

Jian

Quote Reply
Re: Access denied error In reply to
Did you use the setup.cgi to create the files with the correct ID/Password in the defs area?



Quote Reply
Re: Access denied error In reply to
I tried to install it from the scratch and the defs directory was empty.

Jian

Quote Reply
Re: Access denied error In reply to
Your defs directory _can't_ be empty, since that is where Links stores the information it needs to connect to the database.

You need to run the setup.cgi and create the def files.



Quote Reply
Re: Access denied error In reply to
Yeah, I know. But I got the error message when I tried to run setup.cgi.

Here's what I have done: I created the mysql database, with mysqladmin. I then changed Links.pm, and ran setup.cgi. That's when the error message showed up. So the defs directory is empty.

I suspect it has something to do with mysql. I didn't do much to it, but I played with creating and dropping databases, and the machine was rebooted twice due to power outage. Could it be corrupted somehow? But the strange thing is, I am still running Links SQL 1.02 using this installation of mysql, and it has been working fine. I don't want to do an upgrade, until I am sure the upgrade is safe. So I started with a fresh installation of Links SQL 1.11. As I said, I made it work the first time, without much trouble.

Jian Liu
Indiana University Libraries
Quote Reply
Re: Access denied error In reply to
Are you using the correct user/password combination when running setup.cgi ?

Quote Reply
Re: Access denied error In reply to
Please say more on this. When I create the database in mysql, do I need to assign an username and password, which I then use with setup.cgi? If so, that must be the problem, for I didn't do it. But then I don't remember doing it when I first tried, since I don't even know how to do it in mysql. :-)

How should I do it?

Jian Liu
Indiana University Libraries
Quote Reply
Re: Access denied error In reply to
Try this:

shell> mysql --user=root mysql
mysql> GRANT ALL PRIVILEGES ON *.* TO links@localhost
IDENTIFIED BY 'any_password' WITH GRANT OPTION;

Then in setup.cgi, choose "links" as username and "any_password" as the password.

Quote Reply
Re: Access denied error In reply to
If you re-installed MySQL as well, you need to follow the MySQL docs on setting up the program, and creating the first user account.

ALways start at the beginning, don't try to take short cuts.


BTW... don't forget to create the Links database.... The program can only create tables, not the database.
Quote Reply
Re: Access denied error In reply to
Thanks a lot. This solved my problem. But I still don't know how I managed to make it work the first time. I am sure I didn't know these mysql commands then.

Jian Liu
Indiana University Libraries