Skip to main content

Multiple XAMPP installations simultaneously on Windows 11

We need to keep the following in mind while having multiple installations of XAMPP in windows 11:

To run multiple XAMPP instances on Windows, we must change the default ports for the Apache and MySQL services in each additional installation. This prevents port conflicts, which would stop the services from starting correctly. 
So, we will need to change the following ports:
  • Apache (HTTP): The default is port 80. We need to change this to a new, unused port like 8080
  • Apache (HTTPS/SSL): The default is port 443. We need to  change this to a new port, such as 444.
  • MySQL: The default is port 3306. We need to change this to a new port, such as 3307
There are few additional steps, which are listed in sequence below:

1. Installing to separate folders

e.g., XAMPP version 8.0 in the folder C:\ProgramFiles\xampp8.0
and XAMPP version 8.2 in the folder C:\ProgramFiles\xampp8.2

(Note: C:\ProgramFiles is a user created folder with write permission for the user, and not the C:\Program Files. This is needed, as in Windows 11 PC, UAC is enabled)

2. Keep one of the php executables in the PATH.

e.g., I have kept the C:\ProgramFiles\xampp8.2\php\php.exe in my PATH environment variable
 

3. Change MySQL port for one of the XAMPP's MySQL.

e.g., I have changed the port to 3307 for the MySQL in the XAMPP8.0 in the following files:
C:\ProgramFiles\xampp8.0\mysql\bin\my.ini
  • Find the line port = 3306 and change to port = 3307.

4. Change Apache ports for one of the XAMPP's Apache.

e.g., I have changed the following in the C:\ProgramFiles\xampp8.0\apache\conf\httpd.conf file:
  • Find the line Listen 80 and change to Listen 8080.
  • Also, find the line ServerName localhost:80 and change to ServerName localhost:8080.
Then, I changed the following in the C:\ProgramFiles\xampp8.0\apache\conf\extra\httpd-ssl.conf file:
  • Find the line Listen 443 and change to Listen 444.
  • Find the line <VirtualHost _default_:444> and change to <VirtualHost _default_:444>.
  • Find the line ServerName localhost:443 and change to ServerName localhost:444.

5. Update the XAMPP Control Panel's port settings

In the XAMPP Control Panel, click the main Config button (the one at the top right of the window).
Select Service and Port Settings, then go to the Apache tab.
Change the Main Port and SSL Port fields to our new values (e.g., 8080 and 444) and click Save.

Go to the MySQL tab and change the Main Port to our new value (e.g., 3307), then click Save. 

6. Change the server port in PhpMyAdmin config:

Find the server configuration section. Look for a block of code that starts like this:
/* Servers configuration */ 
$i = 0;
$i++;

e.g., I added the following line in the server configuration section in C:\ProgramFiles\xampp8.0\phpMyAdmin\config.inc.php 

  • $cfg['Servers'][$i]['port'] = '3307';

7. Restart the services:

Restart the MySQL and Apaches services from the XAMPP Control Panel.

Now, Apache will be listening to port 8080 and SSL 444, and MySQL will be using the port 3307 for the XAMPP 8.0; while XAMPP 8.2 will be using the default ports (i.e., Apache: 80 & SSL 443, and MySQL: 3306)

XAMPP 8.0's Apache server can be accessed via localhost:8080, while simply localhost will point to the Apache server of XAMPP 8.2

XAMPP 8.0's PhpMyAdmin can be accessed via localhost:8080\phpmyadmin, while localhost\phpmyadmin will point to the PhpMyAdmin of XAMPP 8.2


Happy Coding!!!


Comments

Popular posts from this blog

How to change message center number in Android?

Have issues with sending or receiving sms-es?? Tip: Your message center number might be empty or wrong! Solution: Very simple :)  Dial *#*#4636#*#*. You will get a menu, from that select Phone Information You will find a setting "SMSC"  Refresh it. It is most likely to retrieve the message center number from your operator. (Or call your operator, and get the message center number, and then update in this field) Then the problem should be resolved! Happy messaging! [Courtesy: http://www.droidforums.net/forum/tech-issues-bug-reports-suggestions/10135-how-do-you-change-sms-message-center-numbers.html]

My takeaways from JavaOne 2013

This year I attended the JavaOne at Novotel HICC Hyderabad. I attended mainly the sessions on Java. J2EE, and JavaFX, with a bit of extremely innovative enhancements to Oracle DB sessions. Here's the main takeaways from the sessions I attended: 1. Lambda operator and closure coming to JDK8. This is an outright change, a change to all the 4k+ classes in the java libraries. Code will become simpler, neater, and also improve in performance. This is not just a cosmetic sugar coating change, there have been performance improvements as well with these new features. 2. Going by their philosophy of less boiler plate code (which also includes the closure introduction), they have introduced simpler ways to code and work with various J2EE components like the JMS2.0, etc. 3. JavaFX can now be programmed from any of the languages that run on JVM, such as Groovy, Scala, Clojure, etc. I was amazed by the language Groovy! even learning it our of my own interest :) 4. A brand new JavaScript engine...

Part-time courses from IIIT Hyderabad

Let me paste here some details of the PGSSP course offered by IIIT-H for the working professionals in Hyderabad, and on the future route that one may wish to take (either a MTech, MS, or PhD). I had written this to one friend who was interested in PhD, but I feel that the same should give anyone (a working professional, looking for a part-time course) a good idea about the PGSSP programme, and a later MTech/MS, as well. [Disclaimer: The information and the opinion presented here are based on my personal opinion and experience. While I have tried to be as correct and unbiased as possible, the following can not be taken as the ultimate or the final word or information for the part-time courses offered by IIIT Hyderabad. For official information, please go to iiit.ac.in and also enquire from IIIT-H's admission office before taking any decision. ] Q. The offer says that u have to enroll in few courses max of two per semester. Does this course offer a degree of Master? If...