Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.ppp.as43234.net)
Date: November 11, 2015 05:38PM

Hi, first post on this. I'm currently a final year student at University and I'm creating a website using Concrete5 supported by a WAMP server. Everything was going okay, I nearly finished the website. Now when I go back to the website it says "#2002 - No connection could be made because the target machine actively refused it.". I've followed the guidance on all the posts regarding this however nothing has seemed to work. I'm in desperate need of help as I really need this website back for my final year project to work!

Wamp Icon: Orange
OS: Win10 64bit
Complete fresh Win10 build, not a lot of other programs on the laptop.

If anyone can help then you would be a life-saver (literally).


Kindest regards,
Tim

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: RiggsFolly (---.as43234.net)
Date: November 11, 2015 06:33PM

Hi Tim,

Lets see what we can do.

So first what is reporting the 2002 error? Apache or MySQL.

Have you looked at the Apache error log?

Have you looked at the MySQL error log?


What colour is the Wampmanager icon?

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.ppp.as43234.net)
Date: November 11, 2015 07:24PM

Error #2002 is being reported when I try and log onto the website from Localhost and PHPmyadmin.
Do apologise, it's a MYSQL error. When going into the error logs there's NOTHING in the logs.. In the other logs there is something, just not in the MySQL logs.

In the Apache logs there's nothing that's failing.. All starting and stopping fine.

Wampmanager logo is Orange saying Server Online. I'm guessing that MySQL can't start? When I press 'Start/Resume Service' it goes on but still can't get into anything and the logo doesn't turn Green.


Really appreciate you coming back to me.

Kindest regards,
Tim

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: RiggsFolly (---.as43234.net)
Date: November 11, 2015 08:43PM

Ok

So look in the Windows Event Viewer, (Using the Event Viewer: [www.sevenforums.com])

For messages from MYSQL, it writes to the event viewer even before it tries to write to its own log.

Are you sure you have not installed another MYSQL Server somehow?

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.as13285.net)
Date: November 13, 2015 02:17PM

Okay so there is the error message:
" wampmysqld64: unknown variable 'print("lower_case_table_names=0"winking smiley;'

For more information, see Help and Support Center at [www.mysql.com]. "


I'm guessing this is the problem?

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: RiggsFolly (---.as43234.net)
Date: November 13, 2015 03:52PM

It sounds to me like you may have installed another version of MYSQL that has placed a `my.ini` into the
C:\windows\systems32 folder, and WAMPServers MYSQL is picking up that `my.ini` instead of its own.

There is a search path and that is one place wheere MYSQL looks for a `my.ini` file.

Try renaming the `my.ini` in C:\windows\systems32

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.as13285.net)
Date: November 13, 2015 04:21PM

I've searched the whole Windows folder including System32 folder. There is no 'my.ini' file inside there.

The only my.ini files came back was in the C:\Wamp\bin\mysql\mysql5.6.17. There were two files: my.ini and my-default.ini

Hope this helps in any way. I haven't added another MySQL instance on this machine before I downloaded WAMP

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: RiggsFolly (---.as43234.net)
Date: November 13, 2015 04:45PM

In that case do you have a parameter in your 'my.ini` file called `lower_case_table_names`

If so try commenting it out and start MYSQL again.

It seems a little odd that this should suddenly appear out of knowhere though.

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.as43234.net)
Date: November 14, 2015 03:43PM

Okay I've commented it out now and now MySQL starts! The Wampadmin logo is now green.

I am now getting the error message:
"SQLSTATE[HY000] [1045] Access denied for user 'pk004233'@'localhost' (using password: YES)"

I think this is because I started messing about with the Password field in My.Ini file. Below is the my.ini (some of it), is there anything out of the ordinary here?

# The following options will be passed to all MySQL clients
[client]
password = "mypassword"
port = 3306
socket = /tmp/mysql.sock

# Here follows entries for some specific programs

# The MySQL server
[wampmysqld]
port = 3306
socket = /tmp/mysql.sock
key_buffer_size = 16M
max_allowed_packet = 1M
sort_buffer_size = 512K
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M
basedir=c:/wamp/bin/mysql/mysql5.6.17
log-error=c:/wamp/logs/mysql.log
datadir=c:/wamp/bin/mysql/mysql5.6.17/data

lc-messages-dir=c:/wamp/bin/mysql/mysql5.6.17/share


Really appreciate your help so far, nearly there!

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: Otomatic (Moderator)
Date: November 14, 2015 04:27PM

Hi,

> [client]
> password = "mypassword"
NEVER put a password in the my.ini file

The [client] group of my.ini file MUST be:
# The following options will be passed to all MySQL clients
[client]
#password = your_password
port = 3306
socket = /tmp/mysql.sock

> I am now getting the error message:
> "SQLSTATE[HY000] [1045] Access denied for user 'pk004233'@'localhost' (using password: YES)"

When and how?

Note: RiggsFolly is on vacation. Also, please do not be too great a hurry for answers. And... English is not my native language.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.as43234.net)
Date: November 14, 2015 04:47PM

Okay I've just amended the my.ini file to this above.. Just to be accurate.. Are you supposed to comment out the password?


> I am now getting the error message:
> "SQLSTATE[HY000] [1045] Access denied for user 'pk004233'@'localhost' (using password: YES)"

> When and how?

I was getting this when trying to get into the concrete5 site. So this is in chrome.. go to: localhost/projectname this would normally just take me to the site.

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: Otomatic (Moderator)
Date: November 14, 2015 06:22PM

Hi,

> Are you supposed to comment out the password?
What I wrote ?
« NEVER put a password in the my.ini file »
So the line MUST be commented as I wrote.
You need to put your password in the configuration file of the web application that want to connect to MySQL and the database.

> go to: localhost/projectname this would normally just take me to the site.
Using (http://localhost/projectname/) is a very bad idea.
I you want to avoid problem you need to use VirtualHost : The need for Virtual Host

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: pk004233 (---.as43234.net)
Date: November 15, 2015 12:09PM

> Are you supposed to comment out the password?
>What I wrote ?
« NEVER put a password in the my.ini file »
>So the line MUST be commented as I wrote.
>You need to put your password in the configuration file of the web application that want to connect to MySQL >and the database.

Okay I had commented it out, just wanted to validate.



> go to: localhost/projectname this would normally just take me to the site.
>Using (http://localhost/projectname/) is a very bad idea.
>I you want to avoid problem you need to use VirtualHost : The need for Virtual Host

Okay as soon as the issue is resolved I'll use a VirtualHost, thanks for the information.


However, I'm still with the issue of the error:
"SQLSTATE[HY000] [1045] Access denied for user 'pk004233'@'localhost' (using password: YES)"

Options: ReplyQuote
Re: Error #2002 - Cannot start WAMP server
Posted by: Otomatic (Moderator)
Date: November 15, 2015 02:59PM

Hi,

> However, I'm still with the issue of the error:
> "SQLSTATE[HY000] [1045] Access denied for user 'pk004233'@'localhost' (using password: YES)"

The web application wants to connect with user 'pk004233' and with a password.

Did you create the user 'pk004233' with its associated password into MySQL?
If you have not created this user, it is normal that Mysql not found it.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote


Sorry, only registered users may post in this forum.