Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Hi. I recently bought a domain name through godaddy.com and I want to use my computer as a web server using Apache. I can start up apache just fine and I get my apache test page when I type "http://localhost" into my browser. What I don't understand, though, is how that relates to my recently purchased domain name. What's the missing link? When I type my domain name's address, how does it get to my computer? That's what I seem to be lacking...
This is probably the most basic question, but one has to start somewhere and I'm very new to this!
Basically, translating names to IP addresses is the job of the Domain Name Service or DNS. When you go to your domain control panel page on your registrar, there will be a place for you to enter two DNS servers for your domain (each domain needs two authoratative servers in case one goes down). You probably don't want to run your own DNS unless you have two boxes with static IPs and the time to learn how DNS works in and out. If your Web server has a static IP address you can use one of the many free DNS services like www.zoneedit.com -- if it's a dynamic IP, a la most resedential DSL connections, you can get a dynamic DNS service like www.dyndns.org to handle things (their name servers will automagically update your IP address when it changes).
AH... I'm slowly starting to understand. Thanks, www.dyndns.com was definately the step in the right direction for me.
At dyndns.com, I registered two hosts: patrickclay.homelinux.com and patrickclay2.homelinux.com.
Both are pointed to my own IP address. I have the Apache server running and all in dandy in that capacity.
Yet again I come back to the same dilemma: How does my godaddy.com domain get in on this? Do I just have to forward my domain to point to one of the dyndns hosts I created or is there something else I can do?
Originally posted by patrickclay How does my godaddy.com domain get in on this? Do I just have to forward my domain to point to one of the dyndns hosts I created or is there something else I can do?
if what you want is to use the domain you bought at godaddy.com with your dynamic home ip address, then you're gonna have to transfer the domain to something like no-ip or dyndns, as godaddy doesn't seem to provide that service...
Originally posted by patrickclay Is there any way to bypass my Linksys router? On my router setup page, there's something called port forwarding. Is that what I want?
yeah, if you wanna have a web server on a machine on your lan (with an internal ip) and your linksys router is what has the public ip address, then you need to forward port 80 from the linksys to the web server on your lan...
Originally posted by win32sux yeah, if you wanna have a web server on a machine on your lan (with an internal ip) and your linksys router is what has the public ip address, then you need to forward port 80 from the linksys to the web server on your lan...
i was searching and this thread was about the closest that i could come to the problem i am having...it's probably something simple i am missing.. but.... :P
okay, i got two rh9 boxes...one is acting as dhcp server/default gateway.. i am using port forwarding with iptables... okay, the second rh9 box is being used as a webserver on lan side...
here's the problem.. when i forward port 80 to the rh9 web server box, i am able to hit the web page from outside lan (the internet) however, it kills http (web browsing capability) for the rest of the pc's on the lan, including if i try browsing the web from the web server, yet still being able to view the web page from internet... is there an iptables argument that i am leaving out or is there another default http port that i can forward form gateway to internal web server besided 80?
Originally posted by maze_fire when i forward port 80 to the rh9 web server box, i am able to hit the web page from outside lan (the internet) however, it kills http (web browsing capability) for the rest of the pc's on the lan, including if i try browsing the web from the web server, yet still being able to view the web page from internet... is there an iptables argument that i am leaving out or is there another default http port that i can forward form gateway to internal web server besided 80?
hello maze_fire... no, you don't need to forward port 8080 to your webserver, that would be just too weird... you don't want people having to specify port numbers in a URL... of course, the web server itself can listen on any port you want, as long as the port you forward is 80... having said that, the issue you are having sounds like it's caused by the rules you are using for doing the forwarding... it sounds like your rules are affecting tcp --dport 80 packets on all interfaces... you only need them to affect incoming tcp --dport 80 packets on the internet interface...
could you post the rules you are using?? maybe even your entire iptables script??
in this example, the web server is running on port 3210, where it's fed the packets that come into tcp port 80 on the firewall:
i tried the cmds you gave me and it still didn't work....btw, i need to correct what i said earlier... when i said that when i forward port 80 you can access the internal web server, that was a typo....i forgot that when i was testing it out, i still had httpd running on gateway
so anyways, unable to actually get the port forwarding to work just for httpd, but works for other apps, i.e., vnc, teamspeak & remote desktop
okay, here is my iptables script:
iptables -F -t nat
iptables -A POSTROUTING -t nat -o etho -j MASQUERADE
the last two lines are just examples of the successful port forwarding i was able to do...i even set the httpd to listen on like, port 3210 as in your example above, restarted the service, used the iptables cmds as in your example above and still no dice... thx again for help!