Today, I found that one of my Joomla sites was not working for registered users. They received the error message "You cannot access the private section of this site" even when they used a valid password trying to log on to the site.

Thankfully, I quickly found a detailed explanation of the cause.

To make a long story short, the problem can be fixed in short order by running the SQL command

UPDATE {prefix}_assets SET parent_id=1 WHERE parent_id=0 AND id>1;

where {prefix} is the database name prefix for the Joomla site.

Just to be on the safe side, it might be a good idea to back up the database first.