Raspberry Pi Public IP

Keep it clean but fun.
Post Reply
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Raspberry Pi Public IP

Post by vitinho444 »

Hey guys, I've been bored sometimes and as i was playing with raspberry pi, i thought, why not try owncloud and let's make a cloud huh?

So i tried a tutorial, and it works fine i guess, but the problem is, what if i want to access it outside my network, i need to visit a public IP right? Well that's the thing, i already did a ifconfig curl or something and i got the exact same public IP as in my desktop.. But the thing is, if i try to access it from my desktop it finds nothing.. But if i run apache on my desktop it find my webserver (in the desktop).

So how can i assign a public IP to my rasp PI to access it from anywhere?

Thanks
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
Jackolantern
Posts: 10891
Joined: Wed Jul 01, 2009 11:00 pm

Re: Raspberry Pi Public IP

Post by Jackolantern »

Are you forwarding the port calls through your firewall? Most port requests are considered malicious by the firewall unless you set it up.
The indelible lord of tl;dr
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Re: Raspberry Pi Public IP

Post by vitinho444 »

If you're talking about the router's firewall then yes, i forwarded port 80, 8080, SSH, and FTP and still can't connect... this is the only problem with my PI atm.
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
hallsofvallhalla
Site Admin
Posts: 12023
Joined: Wed Apr 22, 2009 11:29 pm

Re: Raspberry Pi Public IP

Post by hallsofvallhalla »

That was my point about DMZ. Open it to that lan address and try it again. If you can get through then you know there is an issue with a port or firewall. You can turn it off later.
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Re: Raspberry Pi Public IP

Post by vitinho444 »

hallsofvallhalla wrote:That was my point about DMZ. Open it to that lan address and try it again. If you can get through then you know there is an issue with a port or firewall. You can turn it off later.
Right ;) I'll try, but 2 questions:

1- What if it still doesnt work?
2- How can the browser pick a server (Desktop or PI)?
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
hallsofvallhalla
Site Admin
Posts: 12023
Joined: Wed Apr 22, 2009 11:29 pm

Re: Raspberry Pi Public IP

Post by hallsofvallhalla »

the browser doesn't pick a server. It is routed. Try the DMZ then let us know. Remember to open DMZ to LAN of Pi. Make sure desktop apache is off.
User avatar
Jackolantern
Posts: 10891
Joined: Wed Jul 01, 2009 11:00 pm

Re: Raspberry Pi Public IP

Post by Jackolantern »

vitinho444 wrote:2- How can the browser pick a server (Desktop or PI)?
Pretty much as Halls said, the browser does not pick a server. Every port can only be open with one application. This is why things like SQL Server Reporting Services and Skype cause problems with Apache: once one program opens a socket, no other program can open the same port. You can only have one server running.
The indelible lord of tl;dr
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Re: Raspberry Pi Public IP

Post by vitinho444 »

I tried DMZ host to my pi, and restarted apache and accessed the public IP but it still says "Ops, google chrome couldn''t find.."

I tried using the local IP (192.168.1.4) and it works, but with the public it just doesnt... What am i doing wrong?
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
Sharlenwar
Posts: 523
Joined: Mon May 28, 2012 7:14 pm

Re: Raspberry Pi Public IP

Post by Sharlenwar »

I'm not sure, what I do at home is I assign a static IP to a particular mac address within the network. This way you aren't using DHCP (so the ip's don't change when they are renewed). Then within the router itself you should be able to forward ports by assigning the IP and what ports are open for that IP. I believe http uses port 80 as it is a standard port. Once that is done, you should be able to type in your external ip and the website in theory should appear if it is port forwarded correctly. I would do screenshots, but I'm not home at the moment. In about 4 hours I'll be home, so I'll update this post.

Try this resource: http://portforward.com/
Deep within the Void of Quasion, a creation.

**My Corner of the Web**
***NEW***GrindFest - My own PHP/MySQL game!
Sharlenwar's Adventures
Torn-City - Massively multiplayer online text based RPG
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Re: Raspberry Pi Public IP

Post by vitinho444 »

Well DMZ should open EVERY port on the given IP. And in a tutorial installing xampp and stuff, they thought how to set the static IP, so i know its 192.168.1.4 EVERYTIME.

My router is a bit stupid.. :/

I read that it can take a minutes to apply... I'll try tomorrow again. If it doesn't work, do you guys have some sort of tut on installing apache and mysql for a webserver only?
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
Post Reply

Return to “Off-Topic”