Phpmyadmin - Can't get it to install
1 Attachment(s)
Hi,
Using Ubuntu 18.04. I have tried to install phpmyadmin a dozen times now and can't get past the point where the actual install takes place. I get " Error 1045 Access denied for 'root'@'localhost' (using password: NO)" This 'using password NO' is a mysql message; there is no place to put mysql -u user -p password!!! I accepted the database for phpmyadmin and want my Mariadb user 'rick' to be the man-in-charge. I don't know what to put in for phpmyadmin password. I used to be that you put in whatever MySql user password you would use to access your databases and away you go. Thanks in advance in help with this. Totally frustrated after many hours!! R |
As no one else has stepped up I'll see if I can point you in the right direction...
Disclaimer: I am not an Ubuntu user and unfamiliar with its package manager, and would never install a PHP application from a package manager anyway, so I'll point you elsewhere for that... A quick web search turned up this DigitalOcean page which appears to have the details you need to figure this out. I assume you are running this on your local machine not accessible from the interwebs, but if not then heed security advice given there also. Once past the point that phpmyadmin code is installed to your web server root, you need two things to happen for it to access MySQL: 1. MySQL/Mariadb must have a GRANT for the user you want to access the database. If unsure then open a MySQL client for your admin or root user (ex: mysql -p -u root) and ask it whether rick has permission: Code:
> show grants for rick@localhost; Code:
GRANT ALL ON db-name-here.* TO rick@localhost IDENTIFIED BY 'password-here'; |
To add to what astrogeek said, it's important to understand that phpmyadmin has no security of its own. It uses the already defined security of the the mysql installation. Out of the box, the root user to mysql has no password.
Where did you install phpmyadmin from? I use my distro's repositories (epel) to install it. Have you reviewed the installation instructions for phpmyamin? |
Thanks for replies,
I have checked out site(s) refered to and can find no answer. Here is the Mariadb(mysql) status info that maybe can help you help me. I have a root user with password and a rick user with password. They are both accessible in mysql with no problem. Both show authentication_string and mysql_native_password entries in mysql.user. Quote:
|
Quote:
If you are trying to upgrade phpmyadmin, the instructions are here. |
Thanks scasey
scasey: Quote:
astrogeek: Quote:
pizzipie: Quote:
|
Your error says that the upgrade is not using the password
Code:
Access denied for user 'root'@'localhost' (using password: NO) Have you reviewed the documentation and wiki? One Idea: remove the password from the MySQL root user temporarily Another: Run the installation as the Rick user |
Let's back up a little...
It appears to me that you have descended into the dependency nether regions so that while attempting to install a PHP script your system is trying to install or update MySQL first, so we haven't even gotten to phpmyadmin yet. Please tell us, is your web server already installed, configured and running on this machine, or is this a bare new setup? You appear able to login to the MySQL client as the root MySQL user, are you actually using MySQL at this time or is that being setup for the first time as well? Have you ever configured a "rick" user or "root" user on MySQL? (These are NOT system user accounts but belong entirely to MySQL. Many systems attempt to create a "root" user in MySQL by default, but it will NOT have a password set unless you explicitly do that... have you? If you have not created a "rick" user in MySQL there will not be one simply because there is a rick login to the system - they are not the same). And one we haven't gotten to yet - if the web server is configured and running, is it already serving any PHP content? In other words, do we have any confidence that PHP will be processed correctly? One reason I said that I would never install a PHP script from the package manager is that it tends to trigger an avalance of problems due to the packager's choices of dependencies and configurations and it really is not a thing that the package manager should even be aware of, IMO, much less in control of. It is better thought of as web server "content", not a system application. But, that is just me... Regardless, let's make sure your MySQL and your web server and PHP are already working before we think about whether and why phpmyadmin may not be working. |
Quote:
Quote:
Quote:
Quote:
|
Quote:
On the previous post you wrote: "I created user 'rick' from 'root' using a 'root' password and GRANTED 'rick' All privileges.". That should give you the capability to assign "root" password in phpmyadmin, assuming you can login as "rick". |
Quote:
If you Code:
$ mysql -uroot You will get that same Access denied message! That message is reporting that the attempt to login did not supply a password, not that the password was incorrect. As an aside, when using the -p option to mysql supplying the password on the command line may allow it to be seen in ps output, and will certainly preserve it in history. If you Code:
$ mysql -uroot -p |
OK, thanks for the reply pizipie! Your web server is running and configured for PHP, and MySQL is working with the necessary user access - that gives us confidence to move ahead.
Which brings us full circle to how the package was configured and why the installer is balking at MySQL. Unfortunately, I can not offer much help with that because of unfamiliarity with the Ubuntu package repo. As an alternative, I would suggest not installing it from your package manager for reasons I have already given. Instead I would suggest simply downloading the current version from the phpmyadmin website, then installing it according to the documentation given there, especially the Quick Install page. Basically, after veirfying the package checksum, simply untar or unzip the archive in your web server root and adding the necessary credentials to the config.inc.php file - done... If you decide you prefer to use the distro package instead, simply delete the directories and files created when the archive was opened - done. Then install from the package manager (it will probably recognize and use the same DB after you again edit the new config.inc.php, or the equivalent file used by your package manager). |
I fixed it !!!!!. Got rid of Ubuntu 18.04 and installed Ubuntu 20.04. Thank you all for all your Time and Effort on my behalf.
Quote:
|
All times are GMT -5. The time now is 10:02 AM. |