website doesn show outside


14 posts
by sarvinen » Sun Oct 28, 2012 10:57 am
I have a problem. In my home network I can see my website with my computer on the same network, but outside of my network it does not show up.

This is what I did:
I have followed these instructions: http://www.deviousweb.com/index.php/blogs/item/6
I did all the 4 parts plus I installed joomla: http://www.deviousweb.com/index.php/blogs/item/10-raspberry-pi-installing-joomla

Then i created a cool site with joomla.
Then I gave my raspberry pi a static ip:
http://frustrateditengineer.wordpress.com/2012/07/22/raspberry-pi-setting-your-pi-to-a-static-ip-address/

Next I gave my raspberry pi a dynamic dns. I can access to raspberry with that adress. And i also get ping from that adress. So, I think i succeeded with that. http://www.element14.com/community/groups/raspberry-pi/blog/2012/07/26/dynamic-dns--open-up-your-pis-webserver-to-the-world My provider is dynamicdns.com


I port forvaded my router (zyxel prestige 600 series) as in the image.
Image

But still, my website doesn show outside. :roll: Where migth the problem be?
Sorry for my bad english. :(
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by bgirardot » Sun Oct 28, 2012 1:33 pm
(Your English is great)

What is the website address that should work?

I didn't pick through the dynamic dns info yet, but for the most part it seems like you have identified and done all the correct things.

Letting us know either the website ip address or the website name, www.something.com, will help me at least troubleshoot your problem a little more.
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by bredman » Sun Oct 28, 2012 1:43 pm
Note that your Internet Service Provider may be blocking port 80 incoming. Some ISPs charge extra for incoming port 80.
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm
by sarvinen » Sun Oct 28, 2012 2:10 pm
Thanks. :)
The website adress would be http://reissuli.dnsdynamic.com but as you see, it wont work.

Sorry I gave you wrong link, this is the one (dynamic dns)
http://raspberrypipod.blogspot.co.uk/2012/07/dynamic-dns-open-up-your-pis-webserver.html?m=1

I maeby have to call to my ISP tomorrow, to check if they are blocking port 80 incoming.
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by bgirardot » Sun Oct 28, 2012 2:22 pm
The problem is you do not have your public IP address in the dynamic DNS configs:

reissuli.dnsdynamic.com has address 192.168.1.34

That needs to be the public IP address of your router, which will then forward traffic on port 80 to the private 192.168.1.34 address.

Hope that helps.
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by sarvinen » Sun Oct 28, 2012 2:25 pm
Om.. Okay, so do I change the ip adress in the dnssynamic's settings to my routers ip?
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by bgirardot » Sun Oct 28, 2012 2:35 pm
Yes, that is correct.

Some where in the router administration interface it should tell you what its IP is. This is usually on the main page, or a status page or something for the router.
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by sarvinen » Sun Oct 28, 2012 2:40 pm
Yippee! It works! Thank you so mutch!!
I did as said in the link I sent ubove.
Go into /etc/ddclient.conf
Change the line
use=if, if=wlan0
and add a # in front of it.
Add the line
use=web, web=checkip.dyndns.org
Save and quit.
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by sarvinen » Sun Oct 28, 2012 2:41 pm
Ouh, just remembered, should I be worried about safety? Maeby do some firewalls?
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by bgirardot » Sun Oct 28, 2012 2:55 pm
Yes, you should be worried about safety.

But your router is already acting as a firewall, the only traffic that can get to your web server is traffic on port 80.

The place you need to worry about safety is on the webserver itself. That means if you are doing anything other than server up static .html files (like running joomla ;) you need to make sure that software if always up to date and follow the software publisher's recommendations on how to securely install and run it. This includes the web server software itself, like Apache. You can google search things like "securing apache" or "securing joomla"

The software is where you will be vulnerable.

If it is just for you or a limited number of people you could restrict who has access to the site.
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by sarvinen » Sun Oct 28, 2012 2:58 pm
Ok. Thanks! :)
Posts: 20
Joined: Sun Oct 28, 2012 10:36 am
by Wendo » Mon Oct 29, 2012 6:55 am
You also need to worry about your external IP address changing, as thats the whole point of dynamic DNS services.

That would likely mean loading the DNS providers client on a computer inside your network (or the pi if they have a linux version) and leaving it running all the time, then when your external IP changes the client updates the DNS provider
Posts: 142
Joined: Sun Jun 10, 2012 8:27 pm
by hotlikedimes » Mon Oct 29, 2012 6:15 pm
Wendo wrote:You also need to worry about your external IP address changing, as thats the whole point of dynamic DNS services.

That would likely mean loading the DNS providers client on a computer inside your network (or the pi if they have a linux version) and leaving it running all the time, then when your external IP changes the client updates the DNS provider


Correct about the external ip changing.. It is a pain, but if you don't want to use client side software you can sign up for a trial account with DynDNS (http://dyn.com/dns/dyndns-pro-free-trial/). it ends up being free, you just have to cancel the payment thing and you get 1 forwarded address, and it keeps everything up to date with no software being necessary to install. It's kind of annoying because the addresses are like yoursite.dyndns.org, but if you're just doing it for fun then it's a pretty solid option.
Posts: 6
Joined: Mon Oct 29, 2012 6:10 pm
by xcorex » Tue Oct 30, 2012 1:41 am
I don't like ddclient for my server, because it consumes more RAM than a simple script.

paste that on /etc/network/if-up.d/
remember chmod it as executable.
Code: Select all
#!/bin/sh
EMAIL=post@reply.com
PASSWORD=changeit
DOMAIN=user.dnsdynamic.com

IP=`curl --silent http://myip.dnsdynamic.com/`
curl --silent --user "$EMAIL:$PASSWORD" -k "https://www.dnsdynamic.org/api/?hostname=$DOMAIN&myip=$IP"

After that, it's good to "cron" the script, in case of a WAN IP change
Code: Select all
*/15 * * * * /etc/network/if-up.d/dnsdynamic > /dev/null
Posts: 4
Joined: Thu Oct 04, 2012 8:01 pm