ubuntu 16.04 install phpmyadmin 404 - mysql

Operation system: ubuntu 16.04
Runs in a VWWare Player
I installed Lamp with apache2, php, mysql and it works just fine.
then I installed phpmyadmin
sudo apt-get install phpmyadmin
This installs a lot, but if I open the browser with localhost/phpmyadmin I get the 404 Error: Page not found.
I searched for other ways: I was told to just copy the phpmyadmin.***.tar file to the document_root folder. This works, but I don't have access to the Database. I get the User/PWD Dialog but I haven't set anything, so I don't know the password
I would like to get some help on the "sudo install phpmyadmin" way, which seems to me to be the right one.
Regards Martin

I read about some changes up from ubuntu 13
The following did the trick:
sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf-available/phpmyadmin.conf
sudo a2enconf phpmyadmin
sudo service apache2 restart
After that I could open localhost/phpmyadmin (But I forgot the password)
So I removed phpmyadmin
sudo apt-get remove --purge phpmyadmin
and simply reinstalled it:
sudo apt-get install phpmyadmin
User name is phpmyadmin and the password has to be set during the installation

I would highly suggest installing this manually so it's up to date and as secure as possible.
cd to webroot
IE: cd /var/www/html
wget https://files.phpmyadmin.net/phpMyAdmin/4.7.7/phpMyAdmin-4.7.7-all-languages.zip && unzip phpMyAdmin-4.7.7-all-languages.zip
Make sure unzip + wget are installed.
apt-get install wget unzip
I also suggest renaming the phpmyadmin dir.
mv phpMyAdmin-4.7.7-all-languages random-name-here

have you tried root with no password? Sorry I'm not allowed to add this as comment.

Related

How do I totally remove nd reinstall MySQL in my Ubuntu desktop PC

I had installed MySQL in my Ubuntu OS PC. But during the config setup, I had mistakenly set Disallow root login to Y. The MySQL Workbench was not able to connect. I accessed the config file from the terminal prompt:
sudo nano /etc/mysql/mysql.conf.d/mysql.cnf
I noticed that it did not have any config. It only had the following lines:
#The MySQL client configuration file
#Refer to https://dev.mysql.com/doc/refman/en/mysql-command-options.html
[mysql]
I entered the line
bind_address = 0.0.0.0
password = mypassword
But still unable to connect MySQL Workbench. From the terminal, I was now unable to login to MySQL
I tried to uninstall MySQL and reinstall it with the following commands:
sudo apt-get remove --purge mysql*
sudo apt-get purge mysql*
sudo apt-get autoremove
sudo apt-get autoclean
sudo apt-get remove dbconfig-mysql
sudo apt-get dist-upgrade
sudo apt-get install mysql-server
The last command did not proceed with the configuration. I had hoped that I will be able to set the Disallow root login to Y.
How do I uninstall/ reinstall MySQL and have MySQL Workbench connect to it.
Here's how I solved my problem First I uninstalled MySQL (again). Next, I decided to install XAMMP. I followed the how-to steps in one online resource. I launched the XAMPP and was able to connect to localhost/phpmyadmin. I was able to create a database and table, and add a record

MySQL Workbench not opening on ubuntu

While I am trying to open my installed MySQL workbench it is not opening, I try to open using terminal it shows the below error:
command:
mysql-workbench
Error:
> Workbench can't find libproj.so, some options may be unavailable.
> /usr/bin/mysql-workbench-bin: error while loading shared libraries: libzip.so.4: cannot open shared object file: No such file
> or directory
I've tried to install broken packages and creating symbolic link but also I am not able to fix.
Can someone help to solve this issue?
Thanks in advance.
if running mysql-workbench command gives following warning:
Workbench can't find libproj.so, some options may be unavailable.
run this command to check if you have the above mentioned file :
$ find / -name libproj.so 2> /dev/null
if not found, then run this command to install the lacking file dependency to remove the warning:
$ sudo apt install libproj-dev proj-bin
It will remove the warning. Worked for me. Please try in your system. Below is my command output:
$ find / -name libproj.so 2> /dev/null
/usr/lib/x86_64-linux-gnu/libproj.so
$ mysql-workbench
Found /lib/x86_64-linux-gnu/libproj.so.15
(Note: even if this warning was there, my Workbench was still running properly. I followed the above mentioned steps just to get rid of that warning.)
Reinstalling workbench and doing --fix-broken install worked for me.
Details:
Uninstall workbench
sudo apt remove mysql-workbench
Clean
sudo apt clean
sudo apt autoremove
Update repos
sudo apt update && apt upgrade
Install workbench again
sudo apt install mysql-workbench
The fix
sudo apt --fix-broken install
Run workbench
mysql-workbench

ubuntu 14.04 no /etc/mysql folder after installing

I am trying to install mysql and later phpmyadmin on a ubuntu 14.04 server after initial install.
So far I have configured Apache.
there is no mysql folder inside /etc/
I used the command
sudo apt-get install mysql-server to install mysql
When I do this I have no prompt for a password and the mysql folder is still not created inside /etc/ but it says it installed anyway.
First of all, I'd advice you to follow this link:
https://www.digitalocean.com/community/tutorials/how-to-install-linux-apache-mysql-php-lamp-stack-on-ubuntu
Second, as mentioned in the link, sometimes (though in my case it took care of itself), you may need to activate MySQL installation using sudo mysql_install_db
I found this
https://askubuntu.com/questions/392438/mysql-job-failed-to-start
After following the un-install commands and insatllign mysql-server I was prompted for the password.

Cannot start SSH tunnel manager mysql workbench Ubuntu

I am trying to connect to my Localhost using mysql workbench, but run into the " Cannot start SSH tunnel manager" every time. I have tried reinstalling workbench with apt-get. I also reinstalled python2.7 and imported paramiko.
Still doesn't work. I am running Ubuntu 14.10 64-bit.
Here is a screenshot of the error message when testing the connection.
http://i.imgur.com/wZIDVHo.png
I am happy to send over error logs, but I have no clue where to find them! ;)
I am using Apache2, phpmyadmin and mysql.
EDIT; I have also tried to run it with sudo-permissions. No change.
~ Thank you.
delete all your mysql installation previously and start new.
sudo apt-get remove --purge mysql*
sudo apt-get autoremove
sudo apt-get autoclean
sudo apt-get update
sudo apt-get dist upgrade
if you install mysql workbench directly from Ubuntu software center, delete it, and install it using the .deb package at mysql website :http://dev.mysql.com/downloads/workbench/

How do I update phpMyAdmin in Ubuntu?

I have an old phpMyAdmin installation (contains my training and jobs data). I want to update it to the latest version and I want to keep my data safe while updating it. Is there any way to do it by running some commands on the terminal? Is my data erased if I uninstall phpMyAdmin?
Here is how to upgrade/downgrade on Ubuntu.
Note: The following instruction only works if you previously (and correctly) installed phpMyAdmin with the command line and use APACHE as a web server.
I suppose that you already have a working phpMyAdmin, but the version isn't the one you want. For instance, Ubuntu is shipping the 4.6.x version which doesn't work properly with PHP 7.2.
Check the version you want on:
https://www.phpmyadmin.net/files/
On your server
cd /usr/share/
rm -rf phpmyadmin
then adapt this line with the correct version number
wget https://files.phpmyadmin.net/phpMyAdmin/4.8.0/phpMyAdmin-4.8.0-all-languages.zip
unzip phpMyAdmin-4.8.0-all-languages.zip
rm phpMyAdmin-4.8.0-all-languages.zip
mv phpMyAdmin-4.8.0-all-languages phpmyadmin
Note: If unzip don't work, install it with: sudo apt-get install unzip
Check permissions
Now you should be good.
The owner of /usr/share/phpmyadmin should be root:root on a default installation. This should be fine but if you face some permissions issues, you can try to let Apache be the owner:
# only if you have permissions issues
chown -R www-data:www-data /usr/share/phpmyadmin
chmod -R 755 /usr/share/phpmyadmin
You can also restart Apache
sudo service apache2 reload
Troubleshooting
Note: Depending on your PHP version, you may need to install additional libraries.
For example, to resolve the error about missing mysqli and mysql extensions (update the command to reflect your PHP version):
sudo apt-get install php5.6-mysql
phpmyadmin is mysql client, so it will not affect your database if you uninstall phpmyadmin.
I update phpmyadmin by using terminal commands:
First you have to add repository to get phpmyadmin :
sudo add-apt-repository ppa:nijel/phpmyadmin;
and then update it to get the latest version of software in repositories :
sudo apt-get update;
after that, you can get it (install, you need to uninstall the older version first if you have) :
sudo apt-get install phpmyadmin;
Oh, make sure you are connected to the internet
Using ubuntu? i think it will be better if you ask it in ubuntu forum.
may it helps
------ UPDATE -------
If you find the phpmyadmin version you get from ppa is not the latest one, you can find the latest version here and install it manually (not from repo).
Downloaded phpmyadmin can be installed in /var/www/html/ or in your working directory (public_html or something you've defined). Just extract the zip and move extracted folder to /var/www/html/. And don't forget to change the permission of the phpmyadmin folder to 777(it may not safe, but works fine).
Here is the how:
extract downloaded file
unzip phpMyAdmin-4.6.6-all-languages.zip
move to /var/www/html/, you might need sudo.
if you're not sudoer, move it into your working directory (e.g. public_html), and rename the folder to 'phpmyadmin'
sudo mv phpMyAdmin-4.6.6-all-languages /var/www/html/phpmyadmin
change the permission
sudo chmod 777 -R /var/www/html/phpmyadmin
and then you can access phpmyadmin via http://localhost/phpmyadmin.
If you put the phpmyadmin in public_html, you might want to create a symlink into it from /var/www/html, so you can access phpmyadmin as usual.
phpMyAdmin is only client for MySQL database, it doesn't contain your data. It's all saved in database, so nothing will be deleted even if you delete phpMyAdmin.
To update phpMyAdmin from repository you can follow steps from this thread.
1- check your phpmyadmin version from GUI.
2- Download Latest version of phpMyAdmin HERE
Use the below command to download the latest version of phpMyAdmin into /opt or /usr/src directory
# wget https://files.phpmyadmin.net/phpMyAdmin/4.8.3/phpMyAdmin-4.8.3-all-languages.zip
Notes to install unzip package: apt-get install unzip
# unzip phpMyAdmin-4.8.3-all-languages.zip
3- Find phpMyAdmin Installation Directory
Use the below command to search the phpMyAdmin Installation Directory on your system
# /usr/share/phpMyAdmin
4- Remove/Delete phpMyAdmin content
/usr/share/phpmyadmin is correct phpMyAdmin installation directory, Just Delete/Remove everything from that directory
# cd /usr/share/phpMyAdmin/
# rm -Rf *
5- Move/Copy New phpMyAdmin content
Use the below command to copy all the new phpMyAdmin content to /usr/share/phpmyadmin.
# cd /opt/phpMyAdmin-4.8.3-all-languages
# mv * /usr/share/phpMyAdmin/
6- Restart Apache, MySQL or MariaDB service.
Start/Restart the service in SysVinit Systeme
# service restart httpd
# service restart mysql
Start/Restart the service in Systemd Systeme
# systemctl restart httpd.service
# systemctl restart mariadb.service
7- Now Check New version of phpMyAdmin
Navigate your browser to http://localhost/phpmyadmin, Now you are using latest version 4.8.3 of phpMyAdmin.
Reference
sudo su
cd /usr/share/
rm -rf phpmyadmin
wget https://files.phpmyadmin.net/phpMyAdmin/4.8.4/phpMyAdmin-4.8.4-all-languages.zip
unzip phpMyAdmin-4.8.4-all-languages.zip
mv phpMyAdmin-4.8.4-all-languages phpmyadmin
chown -R www-data:www-data /usr/share/phpmyadmin
chmod -R 755 /usr/share/phpmyadmin
sudo service apache2 reload