Cannot install MYSQL on Windows XP - mysql

Man, is my stack overflowing!
I've tried about four times to install MySQL in a developer configuration on Windows XP. It fails with Error 1045. Access denied for user 'root'#'localhost' (using password NO). I go through the whole install app, it actually starts the service, then fails at "Applying Security settings".
There is no firewall running and I can access port 3306.
I get the following "helpful" hint.
If you are re-installing after you just uninstalled the MySQL server
please note that the data directory was not removed automatically.
Therefore the old password from your last installation is still needed
to connect to the server. In this case please select skip now and
re-run the Configuration Window from the start menu.
What is the "data directory"? I tried uninstalling completely. As far as I can tell, this removes nothing from the disk, only the registry. There is still a C:\Program Files\MYSql directory. OK, I deleted that whole thing and reinstalled. I searched for all files and folders named mysql. Nothing turns up after that deletion. I reinstall, and it's the same thing. How do I clean this up so I can reinstall? What OTHER data files are there to get rid of? Or do I need to reboot, or what?
And to think, the only reason I got into this was because I lost the root password.
Aargh!

C:\Documents and Settings\All Users\Application Data\MySQL\MySQL Server 5.5\data
Get rid of that and you're golden. Of course you have to repair your installation afterward, or it won't work, but it does get rid of the previous password.
That's the data directory they're looking for. Nice of them to tell me.
I realize it's obnoxious to answer your own question, but on the other hand, I've spent a fair bit of time googling this without finding this answer.

Related

MySQL said: Documentation #2054 - The server requested authentication method unknown to the client

There are similar question in the thread but here I am obliged to mention this issue because being a newbie learner I couldn't figure out and resolve this problem. Sorry for my long English, I hope you care to help me.
By the way, I have the XAMPP Control Panel installed on my windows already and I had worked on to create few databases in the localhost/phpmyadmin (browser). Today, I had downloaded and installed MySQL-installer-community from this Link. I followed all the procedures to install it and configured it correctly.(The default port number was 33060 and I don't change that while installing the MySQL Installer).
But later by some reason I had to approach to my previous XAMPP Control Panel and tried to start APACHE and MySQL. APACHE was started but MySQL cannot be started and got terminated automatically. Later I found that MySQL in XAMPP Panel is running on same ports as I had not changed the port number while configuring the MySQL installer. So, I changed the default MySQL port number i.e. 3306 on XAMPP Control Panel to 3307 by making the changes in my.ini file as shown in the embedded image:
Changes on my.ini file
Later, while I restart the XAMPP Control Panel, MySQL starts without delivering any errors SEE HERE but still the Access is denied on the browser. For image, see this:
Access denied in the browser
However, through shell alongside, I can fetch the databases even though the access is denied in browser.
Accessing Database via Shell
Thus, I am seeking for the help on why can't I access the databases via localhost/phpmyadmin on the browser? Please guide me thoroughly!!
I found the solution on my own:
For this we have to go to the drive where the XAMPP is installed (for me it's C:\xampp). Then, we have to look for the folder phpmyadmin and click on that.
Inside the phpmyadmin, we have to look for the file config.inc and open with notepad or any other text editor. Look for the line $cfg['Servers'][$i]['host'] = '127.0.0.1:3306'; and change it to $cfg['Servers'][$i]['host'] = '127.0.0.1:3307';
This works for me.

XAMPP, MAMP, MySQL errors

I'm facing a lot of errors at the moment ranging from "No such file or directory" to "Error 403 - Access to the requested directory is only available from the local network." along with a series of permission obstacles relating to mysql.
Admittedly I was playing around with mysql, XAMPP and MAMP today (I'm new to back-end programming) and think I've screwed something up somewhere that's preventing them from working correctly.
Specifically, I'm using XAMPP now and while the status is fine (green) and connected to my IP address, along with MySQL, Apache and ProFTPD services all being connected, I can't find any of the related XAMPP files needed to resolve Error 403. Eg.
Bryans-MacBook-Pro:~ bryanjordan$ chmod -R 777 /Applications/XAMPP/xamppfiles/var
chmod: /Applications/XAMPP/xamppfiles/var: No such file or directory
When I open XAMPP, right-click and all in the Applications directory, all I see is a Contents folder with no reference to xamppfiles.
To clarify, I downloaded XAMPP, imported into Applications, opened, connected to servers and once re-directed in my browser, clicked phpMyAdmin but reached the 403 Error.
I've also linked MAMP and don't have this issue. I can access phpMyAdmin fine through this process.
I should also note, that even though I have MAMP operating fine, I can't access mysql via the command line even when I use the path directory instead of a simple, mysql -u root -p call. Instead I get this error:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/Applications/MAMP/tmp/mysql/mysql.sock' (2)
I'm unsure if this is related but before downloading MAMP or XAMPP I was able to type "localhost/~bryanjordan" into the browser and I'd be redirected to my Sites directory. When I type the same URL in now, I receive this error:
The requested URL /~bryanjordan/ was not found on this server.
Thanks for the help!
Setting up xampp or mamp should be simple to setup. Here is a link to a handy tutorial: https://www.webucator.com/how-to/how-install-start-test-xampp-on-mac-osx.cfm
For XAMPP if it cannot find the folder make sure its actually in your applications folder and make sure your system has permissions to read and write to it.
For MAMP or even XAMPP, if you cannot start your mysql it might be permissions. Please see the link above for the relevant command to run on the command line.
Also given the amount of errors you are having i would recommend removing both and starting from scratch with just one of them using my link above.
Hope this helps!

homebrew: MySQL not starting, Can't update PID file

I am a new Mac user and trying to set up the development environment with Apache, PHP and MySQL. Initially, after a lot of installs and reinstalls i succeeded in installing MySQL (Apache and PHP came bundled with Mac) but now again mysql refuses to start up and gives the error, The server quit without updating PID file (/usr/local/var/mysql/Nikhils-MacBook-Pro.local.pid).
I have literally gone through entire SO questions regarding this problem but have not found a way to fix this and i mean i have done everything to start this but in vain. I have created the PID file too but it disappears in moments, i did a cleanup and reinstall using this SO Question but it has failed YET again. Please, i need to get my server started, i am really losing on to serious work and time.
Is there any other miraculous way to fix this unattainable feat? Also, if anyone asks what is the error in the log files, please don't as there is no log being registered as the server hasn't started yet.
I’ve got a similar problem with MySQL on a Mac (Mac Os X Could not startup MySQL Server. Reason: 255 and “ERROR! The server quit without updating PID file”) and after a long trial and error process, finally in order to restore the file permissions, I’ve just do that:
launch the Disk Utilities.app
choose my drive on the left panel
click on the “Repair disk permissions” button
This did the trick for me. Hoping this can help someone else.
brew install mysql on mac os
These instructions helped me. There was a my.cnf in /usr/local/opt/mysql/ which seems to have been the problem for me. YMMV.

MySQL won't configure, incorrect root password?

So i've installed MySQL server 5.6, and it just will not let me in as it keeps telling me i've got the root password wrong on the installer.
I may or may not have used another MySQL server before, but have long since deleted it and set a new root password upon installing this new server.
Since it wasn't letting me in, i decided to see if there was another way to find out my password (which there isn't) or change it (which there is) but this hasn't worked either.
This is the document i was using.
http://dev.mysql.com/doc/refman/5.0/en/resetting-permissions.html
I have changed my password multiple times now, it's accepted it according to the command prompt, and yet it still won't let me use SQL server...
Oh and i am on the administrator's account. How do i find out, or fix the root password permanently?
Okay i've finally figured out how to solve this (and in turn get it to install fully!).
What i did was delete everything from my system relating to MySQL, uninstall it and then re-download the installer. When installing i created a new file location and made MySQL install under C:\MySQL (a new folder i made), rather than let it install into C:\Program Files... and this seemed to make it install immediately, and meant that it couldn't find (if they were still there) any previously made root passwords.
The key to what it says in that link is to run it as administrator in the Windows sense. Otherwise it all appears to work but it reverts itself when you exit.
I just had this same issue. If you go into the installer and remove MYSQL Server and re-install, it will allow you to set the root password again and continue with your configurations.

MySQL Workbench "fetching..." -- cannot browse DB

I've been having a lot of issues lately, basically since the last time I upgraded XAMPP for OSX (v1.7.3) and/or my MySQL GUI tools. Using MySQL Workbench (v5.2.44), I can connect to the DB running in XAMPP just fine, but trying to browse any database, under tables/views/etc it only shows "Fetching..." and never shows anything else. I can actually query tables, which is interesting, but I can't actually manage the databases in any meaningful way.
Googling, others reported having luck running mysql_upgrade on the command line, which ran fine but did not fix my issue.
The following command worked for me on windows:
C:\Program Files\MySQL\MySQL Server 5.5\bin>mysql_upgrade.exe -u root -p --force
If the root password is not set, you might need to do this before you run the command above:
mysql> SET PASSWORD FOR 'root'#'localhost' = PASSWORD('something');
The link above to mysql_upgrade did not solve my problem directly, but it did lead me to examine my mysql error file, which ultimately led me to the solution. I noticed several lines like this in the error file (located at [xampp root]/var/mysql/[dbname].err):
/Applications/XAMPP/xamppfiles/sbin/mysqld: Can't create/write to file
'/var/folders/y2/37h93r_931sdfpcr7vnc83380000gn/T/ibigNFFi' (Errcode: 13)
That led me to this page in the MySQL docs which states that you should explicitly set the temp folder for MySQL. I double-checked my config file ([xampp root]/etc/my.cnf) and saw this, which looked fine:
[mysqld]
tmpdir = /Applications/XAMPP/xamppfiles/temp/
However, looking back at the error log, I also noticed this:
Warning: World-writable config file '/Applications/XAMPP/xamppfiles/etc/my.cnf' is ignored
Duh. The config file was getting ignored, so the configured temp folder was not getting used (I have no clue why the file was world-writeable...). I edited permissions on the my.cnf file which was 777 and simply removed the "Everyone|write" permission (now 775 / -rwxrwxr-x), reloaded everything, and now everything works.
Not a very intuitive symptom for the ultimate fix, so hopefully this helps someone else.
If you have MAMP instead of XAMP the solution above won't work for you.
Open MAMP then on the top menu go to Tools->Upgrade MySQL databases.
Now open Mysql Workbench and it should list all your tables correctly
If you are using linux distro the run following command:
mysql_upgrade -u root -p
I set Authenticated Users with all privileges to the var/folders/y2/
For me work fine ;)
Before the process I removed authenticated users privileges.
Close and reopen Workbench. it worked for me.
Stop server.
close workbench window
start server
open workbench window
worked for me .. windows 64bit
I had that error with MySQL 8, win10. I've noticed that this line Where the error was
Was leading to another directory trying to find the my.ini file. Looked for it, found it in that directory, changed it. Opened Workbench, clik on every item that was in gray, and turned it into black and that's it!! Ok now!!