LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-09-2010, 04:01 AM   #1
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271
Blog Entries: 7

Rep: Reputation: 18
linux server


hi,

previously in our office there is no server for our domain.we just accessed it through public rental server.

but now we have planned to implement our own linux server.
can we configure the same old domain in our server, and if the client accesses our webpage they should get it from our server.is it possible


thanks in advance,
Dinesh.
 
Old 03-09-2010, 04:49 AM   #2
Absent Minded
Member
 
Registered: Nov 2007
Location: Washington State U.S.A.
Distribution: Debian testing
Posts: 74

Rep: Reputation: 21
Yes, what you are asking is feasible. You will want a static IP most likely and then you will need to redirect your domain to the new IP address. I do recommend that you use a firewall of some kind between your network and the Internet. Myself, I use a dedicated firewall and then use port-forwarding to the nessary servers.
 
1 members found this post helpful.
Old 03-09-2010, 01:26 PM   #3
Blue_Ice
Member
 
Registered: Jul 2006
Location: Belgium
Distribution: Debian, Fedora, CentOS, Windows
Posts: 361

Rep: Reputation: Disabled
As Absent_Minded already said, this possible. The URL, that you use to connect to a webserver, is nothing more then a a piece of text that can be easily remembered by humans. When you enter the URL in the addressbar of your browser, a DNS server will translate it into the ip address of the webserver. For this all the old records that may exist on dns servers over the entire world need to be updated, if not some users may try to connect to the old server until the replication has completed. Usually this is not a big issue, due to the way dns servers and internet is build up.
 
1 members found this post helpful.
Old 03-09-2010, 01:37 PM   #4
frieza
Senior Member
 
Registered: Feb 2002
Location: harvard, il
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,233

Rep: Reputation: 406Reputation: 406Reputation: 406Reputation: 406Reputation: 406
one more thing to consider is the bandwidth your ISP provides you with, depending on the volume of traffic your website sees and how much your office uses will determine what you need, then see if what you have is enough or if you need to talk to your isp for more

a decent cable connection should be enough for a low to medium volume web server
a dsl would be enough for a low volume web server that doesnt host any video content and small to medium images or low quality audio
a dialup would be enough for the occasional use personal website that doesnt host video or digital audio (midi/mod music might work) and small images and but doesnt usually provide static ip

you may also want to make sure with your isp that hosting a web server on your connection is allowed by their TOS, i've been burned by that one before

just my 2 cents

Last edited by frieza; 03-09-2010 at 01:41 PM.
 
1 members found this post helpful.
Old 03-10-2010, 01:42 AM   #5
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271

Original Poster
Blog Entries: 7

Rep: Reputation: 18
hi Absent minded,

Thank you very much for your reply. we are having our own static ipaddress.since i am new to linux i don't know how to redirect my domain to the new static ipaddress.i configured my domain in 192... series but my static ip is 50... series. so how to change my domain from 192... to 50....

ya you asked me to redirect it through iptables but what exact rule in iptables will allow me to do that.


thanks in advance,
Dinesh.
 
Old 03-10-2010, 04:25 AM   #6
Blue_Ice
Member
 
Registered: Jul 2006
Location: Belgium
Distribution: Debian, Fedora, CentOS, Windows
Posts: 361

Rep: Reputation: Disabled
Quote:
Originally Posted by dinakumar12 View Post
i configured my domain in 192... series but my static ip is 50... series. so how to change my domain from 192... to 50....

ya you asked me to redirect it through iptables but what exact rule in iptables will allow me to do that.
Is the server connected to the internet directly or is there a firewall server between the internet and the webserver?

In case it is connected directly to the internet, then you just have to open up the port on which httpd is running.
Code:
iptables -A INPUT -p tcp -m tcp --dport 80 -m state --state NEW -j ACCEPT
In the other case it is more complicated. For that you will have to add more rules that can work with NAT.
 
1 members found this post helpful.
Old 03-10-2010, 04:53 AM   #7
freelinuxtutorials
Member
 
Registered: Oct 2009
Posts: 70

Rep: Reputation: 21
1.setup your own linux web server. I assumed it has private IP address e.g. 192.168.1.100
2.In order to see in that internet, you need a public IP 200.200.200.200
now, it depends on your network setup now? what firewall/gateway do you have.I'll give you a typical setup
-some firewall can set one-to-one NAT. let say 192.168.1.100 translated to 200.200.200.200, now open port 80 for inbound traffic for that IP address 200.200.200.200
-or you only have 1 static NAT IP,you can use iptables here.
-some setup, you have two NIC on your server, one is private , one is public.
3.if you can access your server via your public address .e.g. telnet 200.200.200.200 80
or if you want the domain name. temporarily add the domain name on your hosts file to test
4. now point the A record of your www and domain name to your own public IP. This will be done via your registrar/DNS server access.
 
1 members found this post helpful.
Old 03-10-2010, 05:31 AM   #8
Web31337
Member
 
Registered: Sep 2009
Location: Russia
Distribution: Gentoo, LFS
Posts: 399
Blog Entries: 71

Rep: Reputation: 65
This post may be offtopic, I know, please forgive me if this is not related: I am more concerned about how did you managed to get IP 50.*.*.*, I never saw them before.
The class A info for 50 says it belongs to
Quote:
Joint Tactical Command, Control, and Communications Agency, AZ (NET-JITCNET2)
Are you related to this? You're in India while this seem to be related to US. Most likely you are not, and in that case IP 50.*.*.* is not belong to you and it's not working. That may be your NAT again. I've seen many networks just like that, having beautiful IPs of internet class just to remember them.
See, I'm very curious about interesting IP addresses... I never really saw anyone from IP 50 ever anywhere. If it really belongs to you and it works, please reply here(or mail me from my nick dropdown menu) so I will mark subnet 50 has some users in it. Any additional info is welcome. Thank you for sharing information. I will understand if you won't reply this, you are right to do so.

Again, please, excuse me for my curiosity, I can't stay away from asking these questions, my head is full of this useless information about different subnets, IPs, etc :/
 
Old 03-10-2010, 05:47 AM   #9
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271

Original Poster
Blog Entries: 7

Rep: Reputation: 18
hi web31337,

mine is 59.....,but i had pointed that mine is 50.... by mistake.
so i feel sorry for making you curious.

thanks&regards,
Dinesh.
 
Old 03-10-2010, 06:15 AM   #10
Web31337
Member
 
Registered: Sep 2009
Location: Russia
Distribution: Gentoo, LFS
Posts: 399
Blog Entries: 71

Rep: Reputation: 65
oh, 59 is right one for india. thanks for input.
try going the way freelinuxtutorials points
 
Old 03-10-2010, 11:32 PM   #11
Absent Minded
Member
 
Registered: Nov 2007
Location: Washington State U.S.A.
Distribution: Debian testing
Posts: 74

Rep: Reputation: 21
Quote:
Originally Posted by dinakumar12 View Post
hi Absent minded,

Thank you very much for your reply. we are having our own static ipaddress.since i am new to linux i don't know how to redirect my domain to the new static ipaddress.i configured my domain in 192... series but my static ip is 50... series. so how to change my domain from 192... to 50....

ya you asked me to redirect it through iptables but what exact rule in iptables will allow me to do that.


thanks in advance,
Dinesh.
redirecting your domain to your ip address is done at your registrar (where you got your Domain from). There "should" be a place where you an log-in and change that information.
 
Old 03-11-2010, 02:43 AM   #12
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271

Original Poster
Blog Entries: 7

Rep: Reputation: 18
hi absent minded,

yes you are right. i did that.but we can't able to access our domain outside from our network. As you said this must be related with firewall.From our LAN (192...series)
we connected to static ip(59...series) through a gateway.but i dont know how to map this 192 series to 59 series.

i feel happy to have a reply from linux tutorial,but i don't know how to apply that in my scenario. can you say me what you have done through iptables for your domain, in detail.

thanks in advance,
Dinesh.
 
Old 03-11-2010, 10:48 PM   #13
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271

Original Poster
Blog Entries: 7

Rep: Reputation: 18
hi,

The job is almost done,but while opening the port 80,should i open it both for my internal(192...)ip and for my external ip(59...).

Because i can open the port for my internal ip using iptables but for my external ip i should login to the router to open port 80.

thanks&regards,
Dinesh.
 
Old 03-12-2010, 12:36 AM   #14
Absent Minded
Member
 
Registered: Nov 2007
Location: Washington State U.S.A.
Distribution: Debian testing
Posts: 74

Rep: Reputation: 21
Okay, you need to forward port 80 on the router to port 80 on the web server. If your router is not your active firewall then you will have to instead forward port 80 through your firewall to your web server. In that case iptables will have to be configured to accept incoming requests on port 80 and then port-forward the request to port 80 on the server. I a not clear on what your setup is.
 
Old 03-12-2010, 02:56 AM   #15
dinakumar12
Member
 
Registered: Mar 2010
Location: INDIA (chennai)
Distribution: centos
Posts: 271

Original Poster
Blog Entries: 7

Rep: Reputation: 18
hi

our LAN is connected to internet through the firewall in the router.hope this will give you some idea about our network.

thanks in advance,
Dinesh.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
can we configure a Linux server with mail server,file server and web server kumarx Linux - Newbie 5 09-09-2004 06:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration