XAMPP - can not access from public ip - dynamic

before I was accessing to my xampp server from my dynamic ip. Now I installed latest version of xampp under c:\xampp3
i have no antivirus windows firewall disabled still I can not access.
Forwarding is done correctly.
My local ip is: 192.168.0.13
In router interface displayed WAN IP:
100.98.20....
but when I check it from browser that is:
94.54.225....
if I type 100.98.20.... which is displayed in router's interface it is okay from local computer but if I type it in different net not responding.
When I type 94.54.225.... not responding from anywhere.
Whats wrong here ?
My ISP gives ips many times to each other and that is why I can not access from public ? Should I buy a static ip ?

It depends on your ISP.
Your "WAN" IP is 100.98.20.... it's IPv4 ISP: Carrier-Grade NAT RFC6598
By the wiki https://en.wikipedia.org/wiki/Carrier-grade_NAT
Disadvantages
* It makes it impossible to host services
Read the wiki for more details and/or contact with your ISP for public IP address.

Related

Apache home server connects to domain inside network and not out

Hello i have an old windows xp pc im trying to turn into a server for hobbyist purposes. I downloaded and installed the apache xampp 1.8 distribution. Once installed and tested that the localhost worked, I connected my domain to my servers ip. So my problem is when i tried to connect to my site on my pc on the same network, they all were able to load the domain/site inside the network successfully but when i have a pc thats outside the network try it fails. Any ideas?. thanks.
You have used a private IP instead of public IP so it does not get resolved to your server. You have to use a public IP (if you have a static IP from your provider you have to setup port forwarding on your router.) If you get the IP from DHCPD server you will need to use dynamic DNS and port forwarding.
More info on private networks: http://en.wikipedia.org/wiki/Private_network

Localhost vs ip-address (e.g. 192.xxx.x.xxx)

When I host a page in /var/www/page, I can view it via:
localhost/page
192.xxx.x.xxx/page
Recently, I have started playing with websockets (using this repository).
When I activate the server, I can connect using localhost/page but not with 192.xxx.x.xxx/page (note that I can access the page but not connect to the server)
Can someone explain why?
"On most computer systems, localhost resolves to the address 127.0.0.1, which is the most-commonly used IPv4 loopback address..." (https://en.wikipedia.org/wiki/Localhost)
It's likely that the "localhost" host name is being resolved to the loopback interface IP address (127.0.0.1), as that is the standard on most machines.
If you want the server to respond to another IP address, you'll have to configure it.

How to access a web server installed on Hyper-V

I have installed Ubuntu on Windows 8 using Hyper V. Having also installed Apache 2 I had the notion that I was going to use this as a web dev environment. I set up an external switch so that my ubuntu installation could access the internet. So far everything was progressing swimmingly. The problem I am encountering is that I have no idea how to access the web server from my machine. I can get the IP address that ubuntu picks up and type that into my browser whereupon I am informed "It works!". That's all good but I move around among several networks and I should not have to look up the IP address every time, and that can't facilitate having multiple sites installed. I just want to be able to enter something like
"http://mytestserver/"
into my browser to access it.
Any pointers on how to set this up properly would be much appreciated.
I have always had the most success with Bridged networking in VM Guests and would definitley recommend you go with that option. What you then could do and what I have done is to assign a static IP for the server and assign the hostname as below. You will have to know what IP addressing is available or you can use 192.168.1.x if your inside your network.
The easiest way would be to assign a static IP in /etc/network/interfaces replacing the 0.0.0.0 with the correct entries for your network
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 0.0.0.0.0
netmask 0.0.0.0.0
gateway 0.0.0.0.0
broadcast 0.0.0.0.0
dns-nameservers 0.0.0.0.0 0.0.0.0.0
and then edit your /etc/hosts file and add that static IP and add the Hostname mytestserver. You will already have the localhost entry and possibly others. Just make sure you assign the Static IP address you assigned in interfaces to mytestserver. You may also have to make this same entry in your machines hosts file simply because it will not have a DNS record.
127.0.0.1 localhost
0.0.0.0 mytestserver

Unable to Access my own website from the Server console

I am having a weird issue hosting my web application. I am able to access the website from any other computer (from outside the network and from within the network) but unable to
access it from the Server!! (using the browser )
The details are as follows
Windows Server 2003
IIS 6.0
The system has got a private IP and a public ip
Accessing by Domain name/Public IP from external and intranet clients works fine.
Accessing by Private IP from the intranet clients works fine
Accessing by PrivateIP or localhost works from the server
Accessing by Public IP or Domain name from the server doesn't work!!
As an extra troubleshooting, I did
telnet localhost 443 - works
telnet publicip 443 - doesn't work
Maybe public IP isn't routeable from your server.
Verify what happens when you try to access publicip:
tracert publicip
Check your network settings:
ipconfig /all
Check your socket listenings:
netstat -a -n
Local firewall rules?
Also, there's always the issue of server loopback, wherein a server cannot resolve a named reference to itself from within the server. Most commonly occurs on intranets, or on SharePoint sites, I've noticed.
The problem was with our DNS settings. We recently changed from Public IP to Private IP and the DNS reply was somewhat messed up when we tried opening it from the Server!!.
Thanks for your answers!

Why I can't use my physical ip to see my website after using NAT in Eucalyptus

I have two real machines.
One is responsible for NAT and IP redirect called NC2 and another is responsible for eucalyptus KVM established 3 virtual machine.
No doubt, the OS of machine which is responsible for eucalyptus is Linux.
The guest OS of virtual machines are Windows XP.
Each virtual machine is a web server which runs Tomcat
NC2 gives an private IP 192.168.0.3 to Linux server.
Linux server gives 3 IPs which are private class B to virtual machines.
For example, one of guest OS gained IP 172.16.1.5
Now I use NC2 to redirect a physical IP x.x.x.x to 172.16.1.5
Here is my problem:
I can use other PC ,outer IP, connect to the website which is established on 172.16.1.5 with IP x.x.x.x, but I can't use machine with IP 172.16.1.5 to connect to it's own website.
I turned off the firewall on 172.16.1.5, and it's able to connect to internet such as yahoo or amazon. But it just can't use x.x.x.x to connect to it's own website.
I tested other guest OS which are gained 172.16.x.x also not able to connect to x.x.x.x.
How can I do to make guest OS connect it's redirected physical address?
It look likes this is caused by a NAT issue called 'hairpin'. Here is the explanation:
Let machine A on a LAN have a private IP address 192.168.0.10.
Let NAT N translate A's private IP to public 77.33.45.67 for the WAN.
Some 'early/old' NATs take for granted that the translated address in only going to be used from the WAN. Therefore, they don't forward packets on the LAN having ip address = 77.33.45.67 and only let in and forward those with this ip address when they come from the WAN.
This problem is solved in more recent NATs which detect these situations and forward packets properly. This problem is sometime encountered in P2P systems.
If you are lucky, your NAT be may be reconfigured to enable usage of translated address on the LAN. If not, then you need a new NAT.