Whenever I try to serve project from VS Code, after Windows restart I get message like this:
J���
8.0.29����MNguts]�ےےے�ےك����������uE&)c^L:{�caching_sha2_password�!��ے„#08S01Got packets out of order
After I reinstall Wamp everything works, until I restart Windows.
It was port 3000 being taken by TCP.
You should open CMD as an administrator and follow up to solve this error.
netstat -ano | findstr :<PORT>
Port, in my case, was 3000
and then
taskkill /PID <PID> /F
After that, reload the server and enjoy!
Related
I'm not using php or php-fpm, but it's hogging port 9000. I need port 9000. I'd like to change the port. I changed it in /etc/php-fpm.conf and /etc/php-fpm.d/www.conf. listen = 127.0.0.1:9005. Still listening on 9000. If I kill it it just loads back up instantly with a different PID.
I'm ok uninstalling it too, but I can't figure out how to do that either. Any ideas?
which php version do you have and did you install it via homebrew?
I was having this problem today and solved it by changing the configuration of the listening port:
in the config file in:
/usr/local/etc/php/7.2/php-fpm.d/www.conf
change the line listen = 127.0.0.1:9000 to whatever port you want
If you don't have the config file it might have been a brew problem when copying files. You have to do something like this before attempting to change www.conf:
cd $(brew --prefix php#7.2)
cp -R .bottle/* /usr/local/
All the credits go to this blogpost: https://www.dionysopoulos.me/custom-apache-and-php-server-on-macos-the-definitive-2019-edition/
Update for Apple Silicon Chips
Although the current answer is correct for Mac's on Intel chips it's not correct for changing the PHP-FPM Port on Mac with Apple Silicon chips.
If following the blogpost https://www.dionysopoulos.me/custom-apache-and-php-server-on-macos-the-definitive-2019-edition/
Do Not copy the brew files to /usr/local/ as this is for intel chips.
Instead, after installing php with brew, the file should already exist in:
/opt/homebrew/etc/php/8.0/php-fpm.d/www.conf
Or for php 5.6: /opt/homebrew/etc/php/5.6/php-fpm.conf
Where you can then change listen = 127.0.0.1:9000 to the port you like.
Remember to then restart apache.
My website was working fine till yesterday. But it suddenly started showing this error:
mysql connection error: Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2)
I don't think I made any changes except adding the site to alexa. I googled this and found a lot of resources but all those couldnt help me because I did not fully understand them. I am also not able to locate the file mysql.sock.
I want to know if my website has been hacked. Plus, the solution to the problem.
Might want to start with checking all your db configuration and make sure you did not overwrite or accidentally changed something?
If not that, then try restarting your mysql server. Not sure what Linux env your running, but whichever one it is, Google how to restart mysql.
You could also try and restarting apache. I think the command for that is
sudo service apache2 reload
sudo service apache2 restart
sudo service mysql restart
Then verify if mysql is running on the socket, run this command to see the process
ps aux | grep mysql
this is simple. Run this on commandline
mysql -uroot -p -hlocalhost
sudo service mysql restart
mysql -u root -p
I hope that works.
Recently, I installed xampp 5.6.3 successfully. For this, I turned my UAC off and uninstalled my antivirus, but now it's not working. From control panel, I started Apache, MySQL and filezilla. For my Skype I changed the port of Apache from 443 to 4433. And now it's running.But whenever I got to browser and go to http://localhost it shows a blank page with nothing.So please help me.It is hampering in learning PHP. I will be really thankful.
Thanks.
If you changed the Apache port from 443 to 4433, then you need to change your URL accordingly:
http://localhost:4433
Note: you can use netstat from a command prompt to see if the port is running.
netstat -a | find "4433"
http://technet.microsoft.com/en-us/library/bb490947.aspx
I have updated my XAMPP version to 1.8.2. Now I have the problem that the MySQL Database-server won't start.
If I try to start the Apache Web Server (in 'Application manager'), it says "starting..." and after a few seconds it says "Running". When I do the same thing with the MySQL Database, it says "starting..." for a few seconds and then it says "Stopped".
When I look at the config file (my.cnf), I see this:
# The following options will be passed to all MySQL clients
[client]
#password = your_password
port = 3306
socket = /Applications/XAMPP/xamppfiles/var/mysql/mysql.sock
I think the problem is in the socket. mysql.sock does not exist in that directory and not even in the whole XAMPP-directory.
Does anyone know how to fix this?
PS: I have PHP 5.4 installed on OS X.
i had experienced the same error on Mac OS X (10.9) Mavericks i fixed by following these steps
Open terminal and use sudo su
Run ps aux | grep mysql
Kill all process using kill -9 PROCESS_ID
Start your MySQL using control panel
Port 3306 might be used by other process, Can just change the Port number in Xampp mysql configuration and start the mysql.
I had the same experience with xampp but I wasn't performing an update, this was a clean install. I have had good luck running MAMP right out of the box. This isn't exactly a direct answer to your problem, but if you just wanted to install something and get work done, MAMP could be an option. I did a couple of hours of googling and I still haven't figured out the xampp issue here...
I have run into a problem. I do both pHp development and JSF development. But i ran into a problem. You see, a while ago I installed Apache2 so that I could do pHp. But then a month later I had to install Apache Tomcat. That's when the problem arose. I followed all the instruction give on the tomcat.apache.org site for Ubuntu. It did not install. And 127.0.0.1 always pointed to Apache2's page. I tried 127.0.0.1:8080 but that did not return anything.
So I am here to ask you if there is anyway I can turn off Apache2 when i want to work with Tomcat? And turn it back on whenever I want?
The two servers should be configured to listen on different ports if you want them both available on the same host.
Instructions for changing ports for Apache2 on Ubuntu
Instructions for changing ports for Apache Tomcat on Ubuntu
Now, if you've configured Apache to listen on 80 and Tomcat to listen on port 8080, you should be able to access them at http://localhost:80 (or just http://localhost) and http://localhost:8080 respectively.
You should ensure both the servers are actually up as well. netstat -npl | grep :8080 and netstat -npl | grep :80 should help you identify what processes are bound to these two ports. If the ports are bound but don't say java or apache2, you've got some other process listening on these ports and that's going to stop the server that tries to bind to that port from starting up.
For Apache2, you could also run service apache2 status to see what the status is.
If however, you want to run both servers bound to the same port( perhaps 80) then as you seem to have guessed, you'll have to stop the other.
To stop Apache2, execute the command service apache2 stop
Stopping Tomcat depends on how you started it. You might simply run the shutdown.sh script in ${CATALINA_HOME}/bin i.e. the bin directory in your Tomcat installation folder.
Note
You will [probably] need to execute the commands as root so you'll need to prefix sudo.