I recently installed Apache web server in my machine. I checked whether the server was running or not by using
`[root#localhost httpd-2.4.7]# /etc/init.d/httpd stop
Stopping httpd: [ OK ]
[root#localhost httpd-2.4.7]# /etc/init.d/httpd start
Starting httpd: [ OK ]
[root#localhost httpd-2.4.7]# `
It is fine up to this.
My question is when I try to load a server page in the browser by using
http://localhost:8080 it's showing the error This webpage is not available.
What is wrong?
Check port for apache:
netstat -plnt | grep ':80'
and if port will be 80 run:
http://localhost/
first go to in configure httpd.conf folder in apache and open change the port value 80 instead of 8080 ( two place u need to check in code ) .
then go to services (click ur start button and type this in " search programs and file ") and then search for "Web Deployment Agent Service"and stop it. then go and restart ur apache. then ur local host will start work .
if not then after stop "Web Deployment Agent Service" in services , again open httpd.conf folder in apache and edit 8080 instead of 80( two place u need to check in code ) . hope this will work.
I hope it will help full to u
I think you need to change tomcat port number because for example oracle default port number is 8080,anyway do one thing go to ur tomcat home directory in conf folder open server.xml file you find below this tag u find portno=8080 ...change this to 2014 or somethig and save it same folder.restart u r server and give this url http://localhost:2014
Related
enter image description here
This is the problem that I currently have. I tried some options like running it as administrator, changing the port on http.conf & httpd-ssl.conf but it doesn't work. I hope you can help...
check if your apache is not already running,
run apachectl configtest (or change apachectl to your apache runtime),
check if default config is working,
check if config with modified dirs is working,
check your apache server logs (Im sure you'll find clue in there)
btw. from the error message it looks like something (tomcat server) is already running on 8080 port so you'll either need to change port of tomcat or change the port on which apache is trying to start (/etc/httpd/httpd.conf + virtuals dir or /etc/apache2/*.conf) - it looks like it wants to start on 8080 which is quite default port for web server (apart of 80 which is added by default so when you're writing something.com your browser is really going to something.com:80 - just you dont see it)
I use wamp2.2 for all the time, but i had to install xamp1.6.8 cause i've got to work with project created for old php version. Xamp installation goes fine but when i run it i cant get localhost site. Ive got blank page with favicon of wamp and comunicate that site is unavaible. I know that this is configuration case. Anybody know how to fix this?
I want to run only one of them at once, and i have configured some virtualhosts for wamp they dont have to be accesible while xamp is running i need xamp only for one project.
for run xampp and wamp in same computer you can use this tutorial from arasjoomla website: http://arasjoomla.ir/joomla-tutorial/how-to-run-xampp-and-wamp-on-same-computer
for example we used wamp with default port and setting and set changed in xampp:
Change xampp apache port 80 to example 8080 in httpd.conf from
directory C:\xampp\apache\conf
In my.ini from C:\xampp\mysql\bin change port=3306 to port=3307
In config.inc.php from C:\xampp\phpMyAdmin after this code:
$cfg['Servers'][$i]['AllowNoPassword'] = true;
add this code:
$cfg['Servers'][$i]['port'] = '3307';
restart xampp now we cab use xampp and wamp for example use this
code in xampp port 3307 for connection database:
$servername = "localhost";
$username = "root";
$password = "";
$dbname = "my_db";
$port = '3307';
$conn = mysqli_connect($servername, $username, $password, $dbname,$port);
if (!$conn) {
die("Connection failed: " . mysqli_connect_error());
}
$sql = "SELECT id, name FROM users";
$result = mysqli_query($conn, $sql);
if (mysqli_num_rows($result) > 0) {
while($row = mysqli_fetch_assoc($result)) {
echo "id: " . $row["id"]. " - Name: " . $row["name"]. "<br>";
}
} else
echo "0 results";
mysqli_close($conn);
WAMP and XAMPP are basically the same thing i.e. Apache MySQL and PHP so if one is running it's Apache will have captured port 80, so the second one wont be able to get to port 80, ditto one's MySQL server will have captured port 3306 so the others wont run.
Why do you need to install XAMPP to get an old version of PHP running, WAMPServer is designed to allow you to switch between multiple versions of Apache/MySQL and PHP fairly easily.
But now you have done it, just make sure that the Apache and MySQL services from XAMPP are set to start manually and also Wampservers [wampapache] and [wampmysqld] services as well. then just run only one of them at any one time.
I have two working together, first was wamp. So xampp has to be changed at:
httpd.conf :
Listen 8080
ServerName localhost:8080
httpd-ssl.conf :
Listen 4433
<VirtualHost _default_:4433>www.example.com:4433
By the way, I realised so xampp has much better, mean faster, refreshing time.
The chances are that they are both trying to run on the same port via localhost.
I think it will be difficult to run both at the same time, there's a much better way to this using a tool called "Vagrant".
Vagrant allows you to start up a virtual host that you have full control over, including PHP version. You can see more information about Vagrant at http://www.vagrantup.com/. This tutorial is what helped me get set up and understand how it works: http://code.tutsplus.com/tutorials/vagrant-what-why-and-how--net-26500.
Good luck!
If you want to run both XAMPP and WAMP together on the same machine but access only one of the servers at a time then you could go ahead installing both of them one after another. But, keep in mind that before installing the other server you have to completely stop all the services running from the XAMPP or WAMP control panel then quit the application. After this step you can go ahead installing the other server without changing any configurations or port numbers. This is because in this case we assumed that only one of the servers would be accessed at a time. Hence, before launching the other server one has to completely quit the application that is running currently by stopping all of it's services. If skype is installed then one has to change the default incoming connection ports to other than port 80 and 443.
If you messed up changing ports and config files then you could end up with the following error while trying to access phpmyadmin from XAMPP control panel:
**mysql said: Cannot connect: invalid settings. xampp**
note: while launching the servers , run it as administrator else some services will not start properly.
I TRIED INSTALLING BOTH XAMPP AND WAMP ON WINDOWS 10 AS SUCH AS
POINTED BY MANY THREADS I CHANGED THE DEFAULT PORTS FOR MYSQL & APACHE
XAMPP AS IT WOULD CONFLICT WITH WAMP ALREADY INSTALLED ONLY ENDING UP
UNABLE TO ACCESS PHPMYADMIN FROM XAMPP CONTROL PANEL. THEN REINSTALLED
XAMPP WITHOUT CHANGING ANY CONFIGS OR PORTS. STOP THE WAMP SERVICES,
QUIT THE APP AND THEN LAUNCH PHPMYADMIN FROM XAMPP CONTROL PANEL. AT
LAST IT WORKED!. THE PROCESS LOOKS SHORT THOUGH WHEN IN REALITY IT
TOOK ME COUNTLESS HOURS AND PAIN RESEARCHING ON THE WEB AND TESTING
FOR A POSSIBLE SOLUTION UNTILL I CAME UP WITH THIS.
Hopes, this quick tips and guides would be helpful.
If you guys wanna use MYSQL specifically on Both Wamp and Xampp . Yes It's possible. Not only that You can use the Apache server and all the components of it parallely. Let's say you need two different versions of MYSQL on a same machine then this solution that I am gonna tell you will be helpful.
First Install WAMP server and then after launching it Just go down to the bottom right of ur desktop and hit on the wamp server icon. You will be able to see All the components there. Now if you hit on MYSQL specifically then you'll see a my.ini file pointed there. Now open that file on a notepad and then search for "port" and replace the existing port of mysql which is 3306 to a new random port let's say 3360.
Now after this just press on restart all the services It's done.
Now Install xampp server and now go to xamp folder and search for mysql and rename that to mysql_old. Create a new and empty mysql folder now. Now redirect to the below link https://dev.mysql.com/downloads/mysql/5.5.html?os=3&version=5 and download the zip and extract it. After extracting it just paste all the contents of it in the newly created mysql folder. Now redirect to the bin path inside newly created mysql folder and create a new my.ini file. Over there just paste the below contents:
[mysqld]
# Set basedir to your installation path
basedir=C:/xampp/mysql
port=3306
key_buffer_size = 256M
# Set datadir to the location of your data directory
datadir=C:/xampp/mysql/data
# Default: 128 MB
# New: 1024 MB
innodb_buffer_pool_size = 1024M
# Default since MySQL 8: caching_sha2_password
default_authentication_plugin=mysql_native_password
[client]
ssl-mode=DISABLED
port=3306 #This port can be again anything..
Now after this just redirect to bin folder and hit on mysql d --initialize.
And then you're good to run mysql server on xamp using the following command
mysql -u root -p -h localhost.
This can help u run mysql on a different port.
Cheers
I have a new server running CentOS, and it has httpd running on 192.168.1.100:80.
I can connect to my server through ssh on 192.168.1.100, but when I go to 192.168.1.100 in my browser, it says "Oops! Google Chrome could not connect to 192.168.1.100".
I also tried wget to see if that works, and here is where it gets interesting.
when I run:
wget 192.168.1.100
On my server it gets the index.html file as it should.
but when I run it on my laptop is says "Connecting to 192.168.1.100:80... failed: No route to host."
Does anyone know how to fix this?
Seems like your Apache configuration binds httpd to 192.168.1.100:80
Find line Listen 192.168.1.100:80 in Apache main configuration - something like /etc/httpd/httpd.conf or /etc/apache2/httpd.conf and change this line to Listen 0.0.0.0:80.
Restart Apache and it will probably work.
I have installed XAMPP on my windows 7 machine but can't get Apache to work.
On start I get the following errors:
13:09:21 [apache] Apache Service Detected With Wrong Path
13:09:21 [apache] Uninstall the service manually first
13:09:21 [apache] Possible problem detected!
13:09:21 [apache] Port 80 in use by "system"!
13:09:21 [tomcat] Tomcat Service Detected With Wrong Path
13:09:21 [tomcat] Uninstall the service manually first
After opening the XAMPP panel and installing Apache service: I have tried start it, it always get stuck "Starting apache service..."
Any advice on how I could resolve this ?
Thanks
Jamil
I was able to fix this!
Had the same problems as stated above, made sure nothing was using port 80 and still not working and getting the message that Apache and Mysql were detected with the wrong path.
I did install XAMPP once before, uninstalled and reinstalled. I even manually uninstalled but still had issues.
The fix. Make sure you backup your system first!
Start Services via Control Panel>Admin Tools (also with Ctrl+R and services.msc)
Look for Apache and MySQL services. Look at the patch indicated in the description (right click on service then click on properties). Chances are that you have Apache listed twice, one from your correct install and one from a previous install. Even if you only see one, look at the path, chances are it's from a previous install and causing your install not to work. In either case, you need to delete those incorrect services.
a. Got to command prompt (run as administrator): Start > all programs > Accessories > right click on Command Prompt > Select 'run as administrator'
b. on command prompt type sc delete service, where service is the service you're wanting to delete, such as apache2.1 (or sc delete Apache2.4). It should be exactly as it appears in your services. If the service has spaces such as Apache 2.1 then enter it in quotes, i.e. sc delete "Apache 2.1"
c. press enter. Now refresh or close/open your services window and you'll see it`s gone.
DO THIS for all services that XAMPP finds as running with an incorrect path.
Once you do this, go ahead and restart the XAMPP control panel (as administrator) and voila! all works. No conflicts
my friend this the will fix ur problem ;)
in root of folder ( xampp ) just run this file ( setup_xampp.bat ) then press enter
and try to start the apache server
every things will work like charm ;)
The most likely reason would be that something else is using port 80. (Often this can be Skype, IIS, etc.)
This tutorials shows How to Change the Apache Port in XAMPP
I spent over 3 hours to find out solution. Actually port 80 was being used by "system" service so I tried to change port from 80 to 8080 in "httpd" file but same problem raised "port 80 is used by system". It had driven me mad for 3 hours as every thing was changed like port , localhost server etc pointing to 8080.
At last I found mistake that was server root. Basically "Server Root" in "httpd" should be pointing to apache foler of xampp. In my case that's was
ServerRoot "xampp/apache"
I just changed it as follows:
ServerRoot "C:/xampp/apache"
It has worked successfully and now everything is running with OK status.
refer this:- http://www.sitepoint.com/unblock-port-80-on-windows-run-apache/
and to enable telnet http://social.technet.microsoft.com/wiki/contents/articles/910.windows-7-enabling-telnet-client.aspx
I encountered the same issue after XAMPP v3.2.1 installation. I do not have Skype as most people would believe, however as a Software Developer I assumed port 80 is already in use by my other apps. So I changed it by simply using the XAMPP Control Panel:
Click on the 'Config' button corresponding to the APACHE service and choose the first option 'Apache (httpd.conf)'. In the document that opens (using any text editor - except MS Word!), locate the text:
Listen 12.34.56.78:80
Listen 80
And change this to:
Listen 12.34.56.78:83
Listen 83
This can be any non-used port number.
Thanks.
I know this is somewhat of an old topic, but in case anyone reads this in the future...
I uninstalled xampp, deleted everything under the c:\xampp folder, then reinstalled xampp as administrator and it worked like a charm.
For me, the problem was I had two installations of Apache Tomcat
The following steps solved my problem:
Open up services.msc in command prompt
Select the Apache Tomcat service, right click and select properties
Check the path to the executable of the service
Follow the instructions in
https://stackoverflow.com/questions/7190480/modifying-the-path-to-executable-of-a-windows-service
to change the path to "\tomcat\bin\tomcat7.exe" //RS//Tomcat7
Restart XAMPP Control Panel
I had my Apache service not start same as MySQL one.
Please follow these steps if none of above tips works :
Open regedit.exe on any windows this available . Run as administrator. (Only on windows 7 and later editions )
Go to local machine/system/controlset001/services
Find and delete folders of services apache and mysql .
Uninstall xampp . Delete folder of xampp.
Restart computer and reinstall Xampp . After that your Xampp apache and Mysql should work.
Note: Ports 80 and 443 must be unused by any program.
If it is in use . Just edit ports. There is a lot of tutorials about that .
I have downloaded xampp-win32-1.7.7-usb-lite.7z and unzip it to C drive in my VirtualBox. Then i tried to start Apache through xampp-control.exe. when i press Start button in-front of Apache label, apache started port 80 display in text area in that window. but nothing happen. Start button not change to stop. but mysql is start properly. how could i start Apache ?
Try ZendServer CE, it works great in a Virtual Box. Apache gives problem inside a Virtual Box.
You can also refer this post: Apache won't start in VirtualBox
Try to Restart Xampp from the option Explore
Xampp Contorl-> Explore-> Xampp-Restart
If you have other service installed like .NET SQL Server it may block xampp
Xampp Contorl-> SCM -> SQL server-> Manual from Automatic
Xampp Control-> SCM-> Web client->Disabled
If you like to run service always Check SVC for both Apache Mysql It will ask you to install service click YES to install
Finally Restart your machine
i don't know whether your issue is resolved or not,if not please try the below mentioned cases
1.if your Skype account is logged in,please log out from that(usuall skype uses default Ports numbers 80 and 443 )
2.check whether any other application is running on the port 80,if so please change that port number to other.to see that from a command prompt, run netstat -a. This will output a list of ports that are currently running.
(how to change the default port number is open your httpd.conf file and search for localhost you will find 80 there and change that to your desired number)
i think these are the main cases so please go through this cases also..