MySQL errors

Problems with the Windows version of XAMPP, questions, comments, and anything related.

MySQL errors

Postby Jashank » 15. November 2010 08:12

Hi,

I've just been placed in charge of an ageing SugarCRM installation, so I'm going to bite the bullet and upgrade it. One of the first things I want to do is create a duplicate of the database and installation to perform an offline upgrade of the system, before placing it live. Of course, I turned to XAMPP, because the system I'm working on runs Windows (sadly).

The issue I'm having is this:

Code: Select all
C:\Documents and Settings\Jashank\My Documents\Sugar\xampp\mysql>bin\mysql -u sugaruser -p
Enter password: ********
ERROR 1045 (28000): Access denied for user 'sugaruser'@'localhost' (using password: YES)


This happens no matter whether a database is selected. It's also happening from the SugarCRM web interface:

Code: Select all
Warning: mysqli_connect() [function.mysqli-connect]: (28000/1045): Access denied for user 'sugaruser'@'localhost' (using password: YES) in C:\Documents and Settings\Jashank\My Documents\Sugar\xampp\htdocs\sugarcrm\include\database\MysqliManager.php on line 284
Could not connect to server localhost as sugaruser.Access denied for user 'sugaruser'@'localhost' (using password: YES)


I know that the password I am entering is definately correct; I've reset it multiple times in phpMyAdmin.

I'm now at my wit's end. What's going on here?

Jashank
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby Altrea » 15. November 2010 08:34

Are you sure that the MySQL-User "superuser" is created in your local test environment?
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: MySQL errors

Postby Jashank » 16. November 2010 00:54

I'm certain sugaruser exists. It has all global and database privileges too.
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby JonB » 16. November 2010 03:50

If you restored from a different host - check the locale aka Host of the 'sugaruser' in privileges. You may also have to explicitly GRANT if the user was imported.

Good Luck
:)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: MySQL errors

Postby Jashank » 17. November 2010 08:43

I created sugaruser locally. I also created a second user to see if that would help; it didn't. As a stopgap measure, I'm using the root account, which seems to work, so I have no idea what's going on there.
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby Altrea » 17. November 2010 09:28

is the user sugaruser permitted to login from localhost?
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: MySQL errors

Postby JonB » 17. November 2010 10:39

I'm not familar with teh Sugar setup/configuration -

I'm guessing there are parameter's for database name, user/credentials (and perhaps a few other MySQL related things) either in the app itself or in a configuration file. From your comments, I'm guessing you now have supplied 'root' as the database user for Sugar???

What is the MySQL database name for the Sugar application?

and - what is the current Host field value for the user 'root', please???

does 'root' have a PW in MySQL right now????

I'm about 99.5% sure this is a privileges issue (nothing like stating the obvious, eh?) :lol:
(oops, just changed my mind - might also be an Operating System related issue.) Oh well, I'm not perfect...

:)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: MySQL errors

Postby Jashank » 18. November 2010 07:45

Altrea wrote:is the user sugaruser permitted to login from localhost?


Permitted to log on from %, anyway; my understanding is that % allows localhost.

JonB wrote:I'm not familar with teh Sugar setup/configuration -

I'm guessing there are parameter's for database name, user/credentials (and perhaps a few other MySQL related things) either in the app itself or in a configuration file. From your comments, I'm guessing you now have supplied 'root' as the database user for Sugar???


Yes. Parameters are all stored in a config.php file.

JonB wrote:What is the MySQL database name for the Sugar application?


pubnrg_sugar, apparently.

JonB wrote:and - what is the current Host field value for the user 'root', please???

does 'root' have a PW in MySQL right now????


Well, according to a little hack I wrote (and including sugaruser for comparison):

Code: Select all
root@127.0.0.1 (Using password: YES) -- Privileges = ALL PRIVILEGES
root@localhost (Using password: YES) -- Privileges = ALL PRIVILEGES
sugaruser@% (Using password: YES) -- Privileges = SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, FILE, INDEX, ALTER, CREATE TEMPORARY TABLES, CREATE VIEW, EVENT, TRIGGER, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, EXECUTE


I'm about 99.5% sure this is a privileges issue (nothing like stating the obvious, eh?) :lol: [/quote]

I'm agreed, but the privileges are all set sanely.

JonB wrote:(oops, just changed my mind - might also be an Operating System related issue.) Oh well, I'm not perfect...


It could well be. Windows isn't perfect either... :lol:

Jashank
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby Altrea » 18. November 2010 11:59

does the password contains any special chars?
sorry, i don't have many more ideas :D
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: MySQL errors

Postby Jashank » 19. November 2010 07:19

Altrea wrote:does the password contains any special chars?


If '.' and ',' count as special characters, yes.

Altrea wrote:sorry, i don't have many more ideas :D


Neither do I. I may have to contact someone at Monty Program, to see if I can find anything.
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby JonB » 19. November 2010 08:03

Jeez - you took them at their word and just plugged it in :shock: Am I right???? is that what your last comment means????

I may have to contact someone at Monty Program,


- I cannot conceive of the right comment.

maybe by tomorrow. Nah - I'll give it a go - "I guess that is how we find out if it works, right???"
:mrgreen:

I think if you made that switch you should have told us...

Windows lacks the base64 encode function - and passwords appear to be the problem in a careful reading, so that was the source of my comment about OS related issues.

You did say that root works - give sugaruser all rights and then start taking away????

I'm with Altrea - not too many really brilliant ideas right now, except maybe ditch special characters and see it if springs to life...

:)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: MySQL errors

Postby Jashank » 19. November 2010 08:37

JonB wrote:Jeez - you took them at their word and just plugged it in :shock: Am I right???? is that what your last comment means????


No no no no no no no no no no! Of course not! :lol:

I'm using the stock-standard MySQL (which I believe is MySQL 5.1.49-community) from XAMPP 1.7.4b2.
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05

Re: MySQL errors

Postby JonB » 19. November 2010 11:55

Well, at least you had a few good laughs there @ ole JonB :mrgreen:

- unfortunately, though I have no great new ideas - :(

BUT equally BAD - its the beta - you are supposed to use the Form on the Beta page to report the errors to Kai - they don't check here for Beta errrors

OR are we now having some morning fun????
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: MySQL errors

Postby Jashank » 23. December 2010 00:06

Aaha!

After some time off that project, came back to it to discover that, in the version of MySQL shipped, apparently % does not include localhost (which contradicts my understanding of %). Creating a sugaruser@localhost fixed it.

How bizarre.
Jashank
 
Posts: 8
Joined: 15. November 2010 08:05


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 130 guests