wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 29, 2015 02:46PM

Hi

I've installed wamp on our server to try and get classroombookings.com working. It's taken a few days as I'm not very experienced with this sort of thing, but I feel like I'm nearly there and just need to get over the last hurdle.

Currently I have wamp running on the server, the booking system working, I've set up the virtual hosts etc so that I can click on the projects link. This bit is fine.

If I try navigating to it from a network machine (those who'll be using the booking system) I can get to the wamp page by going to //servername or //servername:80 but if I try and get to the project page //servername/classroombookings I get an error ERR_CONNECTION_REFUSED.

So in short, I can get to the wamp page and the project page from the server. From a client I can get the wamp page but the project page returns err_connection_refused.

I'm sure I'm missing something simple, but any help would be appreciated. I can post the contents of any config files on request.

Thanks

Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: September 29, 2015 03:35PM

Hi Josh,

You had better answer these questions READ BEFORE YOU ASK A QUESTION

And also show us your Virtual Host Definitions

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 29, 2015 03:46PM

Hi Riggs, thanks for that

1 - Windows Server 2012 x64
2-5 - WampServer 2.5 x86 (the latest version of wamp downloaded last week, including apache, PHP and MySQL)
6 - What color is the WampServer icon? Green

<VirtualHost *:80>
DocumentRoot "d:/wamp/www"
ServerName localhost
ServerAlias localhost
DirectoryIndex index.php index.html index.htm
<Directory "d:/wamp/www">
Options All
AllowOverride All
Require all granted
</Directory>
</VirtualHost>

<VirtualHost *:80>
DocumentRoot "d:/wamp/www/classroombookings"
ServerName classroombookings
ServerAlias classroombookings
DirectoryIndex index.php index.html index.htm
<Directory "d:/wamp/www/classroombookings">
AllowOverride All
Require all granted
</Directory>
</VirtualHost>


Thanks for your help

Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 29, 2015 03:56PM

7 - In the file c:\Windows\System32\drivers\etc\hosts, what are the active lines with the name [localhost] in them?

127.0.0.1 localhost
::1 localhost

127.0.0.1 classroombookings
::1 classroombookings


If the WampServer icon is green:

8 - Do you have access to localhost (Homepage WampServer)? Yes
9 - Do you have access to phpMyAdmin? Yes

10 - If you refer to an error message, please include the EXACT wording of the error in your post
11 - If you use an Antivirus and / or Firewall, please include the names of these. Symantec Endpoint Protection 12
12 - What is the full path to the installation of WampServer? D:\wamp\


sorry, I missed these questions off smiling smiley



Edited 1 time(s). Last edit at 09/29/2015 03:57PM by mister__joshua.

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: September 29, 2015 04:10PM

Do you have a local DNS Server?

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 29, 2015 04:15PM

Yes, which isn't the server wamp is on.

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: September 29, 2015 04:29PM

In that case I suggest you change your Virtual Host definitions to this as you are basically running an intranet i.e. no access outside the local network


# only allow access from the server machine itself not the world
# or maybe server and the admins ip address
<VirtualHost *:80>
   DocumentRoot "d:/wamp/www"
   ServerName localhost
   <Directory "d:/wamp/www">
       AllowOverride All
       Require local

       # example admins ip address    
       Require ip 192.168.0.10   
   </Directory>
</VirtualHost>

<VirtualHost *:80>
   DocumentRoot "d:/wamp/www/classroombookings"
   ServerName classroombookings.office
   ServerAlias www.classroombookings.office
   <Directory "d:/wamp/www/classroombookings">
       AllowOverride All
       # Example, just the subnet that all the users are on
       # eg just the first 3 of the 4 quartiles of the subnet allows any ip in that subnet
       # your subnet may be different, check it first
       Require ip 192.168.0
   </Directory>
</VirtualHost>

You then get the DNS Server setup to point `classroombookings.office` to the ip of the server (which should be a static ip of course)

So that you can still access the domain from the server amend the SERVERS C:\windows\system32\drivers\etc\hosts file to :-

127.0.0.1  classroombookings.office
::1   classroombookings.office

Now all your users can use the domain name `classroombookings.office` as the url to get to the booking system.


The TLD of `office` could be anything pretty much if you dont like the idea of `office` but stay away from the normal TLD's of `.com` `.co.xx` etc.

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 30, 2015 12:19PM

Hi Riggs

Thanks for the information.

I tried this this morning but now I am getting 403 Forbidden errors locally and (111) Connection Refused errors from the network machines. I believe my DNS is correct as before I set it up typing classroombookings.office would just start an internet search whereas now I get the error.

I weren't sure if my error was in the 'require ip' section. Our machines use 10.133.44-47. Is that a valid input? I tried 10.133.44 and also 10.133. I wouldn't think this would also cause the local connection to fail? The server is on 10.133.44.41.

Cheers

Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: September 30, 2015 01:00PM

if you have multiple ranges of ip's then use


   Require ip 10.133.44
   Require ip 10.133.45
   Require ip 10.133.46
   Require ip 10.133.47

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: September 30, 2015 05:23PM

Still getting the same problem. Forbidden locally. When trying from a desktop machine I get this error:

Connection to 127.0.53.53 failed. The system returned: (111) Connection Refused.


My vhosts now looks like this:

<VirtualHost *:80>
DocumentRoot "d:/wamp/www"
ServerName localhost
<Directory "d:/wamp/www">
AllowOverride All
Require local

# example admins ip address
# Require ip 192.168.0.10
</Directory>
</VirtualHost>

<VirtualHost *:80>
DocumentRoot "d:/wamp/www/classroombookings"
ServerName classroombookings.office
ServerAlias www.classroombookings.office
<Directory "d:/wamp/www/classroombookings">
AllowOverride All
# Example, just the subnet that all the users are on
# eg just the first 3 of the 4 quartiles of the subnet allows any ip in that subnet
# your subnet may be different, check it first
Require ip 10.133.44
Require ip 10.133.45
Require ip 10.133.46
Require ip 10.133.47
</Directory>
</VirtualHost>


I've also added classroombookings.office to the host file.

Thanks again

Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: September 30, 2015 05:31PM

Oh sorry!

Yes you also need to add the `Require local` so


Require local
Require ip 10.133.44
Require ip 10.133.45
Require ip 10.133.46
Require ip 10.133.47

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: October 01, 2015 10:33AM

Hi Riggs

Thanks, it works again locally now. I'm still having problems trying to connect from network machines. I receive the following error.



ERROR

The requested URL could not be retrieved

The following error was encountered while trying to retrieve the URL: [classroombookings.office]

Connection to 127.0.53.53 failed.

The system returned: (111) Connection refused

The remote host or network may be down. Please try the request again.

Your cache administrator is cachemaster@ifl.net.


Generated Thu, 01 Oct 2015 08:15:23 GMT by proxy01.edc.sln3.net (squid)


Is this a firewall issue?

Cheers, and thanks for the help so far.


Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: October 01, 2015 01:19PM

127.0.53.53 is a special ip address see this ICANN doc [www.icann.org]

Looks like there may be an issue with you local DNS setup.

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: October 01, 2015 02:04PM

I've removed the dns rule now, but I don't think that's my problem.

If I type 10.133.44.41/classroombookings it's trying to load the correct page (http://localhost/classroombookings/index.php/login) but I get the ERR_CONNECTION_REFUSED message. It seems like it's permissions/restrictions based but I can't figure it out.
I thought it may be to do with the <Directory /> configuration in httpd.conf?

Apologies if this I'm confusing.

Cheers

Josh

Options: ReplyQuote
Re: wamp projects connection refused
Posted by: RiggsFolly (---.as43234.net)
Date: October 01, 2015 02:28PM

This looks like a code issue!

When you use `10.133.44.41/classroombookings` in a browser and you see an address of `[localhost].....` then the browser will be looking on the client PC (remember `localhost` is always the machine running the browser) and of course the client does not have an Apache etc.

Looks to me like the classroombookings app has been installed or configured incorrectly.

---------------------------------------------------------------------------------------------
(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: wamp projects connection refused
Posted by: mister__joshua (78.40.232.---)
Date: October 02, 2015 10:16AM

Hi Riggs

It was indeed a problem with the config of the bookings system and I've corrected it. Thanks for your help smiling smiley

Options: ReplyQuote


Sorry, only registered users may post in this forum.