?

I am experiencing a strange issue since update to 3.8 with my database user.
The website is generally working fine (so username and password for the database user are set correctly).
In the backend, when I unpublish a menu item (from the "menu items list" of the menu) by clicking on the "status" icon, the menu item gets unpublished as expected.

when I open the menu item details page and select the "unpublish" option from the "status" select list, I am receiving an mysql error "1044 Access denied for user ..."
(this also happens with other elements as articles and probably others as well).

Steps to reproduce the issue

Create a joomla instance with a database where "database name" and "user_name" both start with the same prefix as the "database table prefix" (whether this is relevant is just my guess)
Open a menu item detail view and try to change the status, then "save" or "save and close"

Expected result

Change is stored to the database

Actual result

1044 Access denied for user '#__mydatabase'@'%' to database '#__mydatabase'
...\httpdocs\libraries\joomla\database\driver\mysqli.php:650

System information (as much as possible)

PHP 7.1.9, Apache 2.4.25, Joomla 3.8.0
Database 5.5.5-10.2.6-MariaDB
database name is "jms_mydatabase"
database username is "jms_mydatabase"
database table prefix is "jms_"

Additional comments

Indeed there is no user #_mydatabase and no database #mydatabase on the server, so the MySQL error message is "understandable", however it looks to me as if the "table prefix" is not rendered from # to jms in these circumstances.

Any ideas?

avatar schultz-it-solutions schultz-it-solutions - open - 3 Oct 2017
avatar joomla-cms-bot joomla-cms-bot - change - 3 Oct 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 3 Oct 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Oct 2017
Category com_content SQL
avatar alikon
alikon - comment - 3 Oct 2017

are you able to change state/save others items (e.g articles , contacts , categories etc)
are you experiencing this only with menus?

avatar schultz-it-solutions
schultz-it-solutions - comment - 3 Oct 2017

On "articles" I get the same error, but as a "Joomla Error" message (in "menu component" I get the "An error has occurred. return to control panel." error

avatar schultz-it-solutions
schultz-it-solutions - comment - 3 Oct 2017

On "article categories" I get the same "system error" message as with menu items.

but on both, I can successfully change the status in the "list of elements view"

avatar tonypartridge
tonypartridge - comment - 3 Oct 2017

I cannot recreate this. Can you try reinstalling core files? Joomla updater and click reinstall core files.

avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Oct 2017
Status New Information Required
avatar brianteeman
brianteeman - comment - 4 Oct 2017

also check the database permissions of your database user

avatar schultz-it-solutions
schultz-it-solutions - comment - 4 Oct 2017

Thanks brian, I was expecting this comment from someone. But please note that I actually can do all this stuff from the "list view" of the menu items or the articles or the categories. So as I stated at the very top, the database user configuration actually IS correct.

It is only in the named circumstances where the connection "seems" to fail - however, what I now found out is, that DESPITE the MySQL error message, at least for content changes in articles, the change actually IS STORED in the database

avatar mbabker
mbabker - comment - 4 Oct 2017

Unfortunately your best first troubleshooting step is going to be checking the permissions. Especially as 1044 Access denied for user isn't a core Joomla message. So it could well be that your user has permissions for some query types that allows things to save correctly but not other types which are used in other ways and causes you to see the error message.

Try setting the site to debug mode and enabling all logging (debug and log plugins). If you get the error message again, you should be able to find the query that it is failing on and that would also help debug this issue.

avatar schultz-it-solutions
schultz-it-solutions - comment - 4 Oct 2017

will do some investigation indeed...

avatar brianteeman
brianteeman - comment - 4 Oct 2017

I am going to close this for now as everything points to it being a local database issue and not a joomla issue. If you find that it is in fact Joomla it can always be reopened

avatar brianteeman brianteeman - change - 4 Oct 2017
Status Information Required Closed
Closed_Date 0000-00-00 00:00:00 2017-10-04 21:38:00
Closed_By brianteeman
avatar brianteeman brianteeman - close - 4 Oct 2017
avatar schultz-it-solutions
schultz-it-solutions - comment - 6 Oct 2017

Found the issue, not connected to Joomla (sorry to bother you).
in the aftermath of updating to Joomla 3.8.0, we had an incident where all database users were crashed in the mysql users table. In restoring them, we missed to also grant the "LOCK TABLES" and "REFERENCES" database permissions. These seem to be relevant only in the named circumstances, and not "whenever changes are made"...

avatar brianteeman
brianteeman - comment - 6 Oct 2017

Glad you discovered the issue and it was as suspected

avatar fjcantais
fjcantais - comment - 6 Nov 2017

I am having this issue running Joomla! 3.8.1 using MySQL 5.5.41-0+wheezy1 and PHP 5.4.45-0+deb7u11
When trying to empty menu items trash I am getting the following message:
Access denied for user 'myuser'@'XXX.XXX.XXX.188' to database 'mydatabase'
But in fact this is not the right IP, this is the IP of the web server running Joomla!, while MySQL is running on XXX.XXX.XXX.179, which is the value correctly configured in configuration.php
Got the same error performing other operations like uninstalling an extension or saving a new article (although, in this case, the article is saved anyway)

Add a Comment

Login with GitHub to post a comment