LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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!

Notices


Reply
  Search this Thread
Old 11-08-2004, 04:20 AM   #1
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Rep: Reputation: 30
basic questions on hostname and domain name + related postfix questions


ok I'm just not understanding hostnames and domains properly. I just bought a web server that I'm sharing with my friend to host our client's websites on. Which means I'm not using just one domain. I'm not sure what I should set it to. Furthermore, I'm not sure what I should set the hostname to. Does it really matter? Right now the hostname is just "debian" Should I change it to the IP of the server?

Also, what should I set in things like the postfix server for mydomain and myhostname? I don't want to be stuck with one domain. For instence my domain is zacwittedesign.com and my friend's domain is culture graphic.com so he doesn't want his clients incoming mail server to be mail.zacwittedesign.com and visa versa. Is there a way I can have mail.clientdomain.com? On http://www.postfix.org/postconf.5.html#myhostname it says my hostname should be my fully qualified domain name. Since I don't want to specify a paricular domain name, can I just put the IP of the server?

But I'm not just worried about postfix, it goes for most other things as well. I guess I'm not too sure on what the exact deffinition of "hostname" and domainname" is... I need help figuring out what to put for /etc/hostname, /etc/hosts, /etc/dnsdomainname and in the config files for various servers.

Thanks for helping me through this.

Last edited by Moebius; 11-08-2004 at 04:49 AM.
 
Old 11-08-2004, 12:28 PM   #2
amfoster
Member
 
Registered: Aug 2004
Distribution: debian, SuSE
Posts: 365

Rep: Reputation: 36
Are you talking about the machine that is the web server? If so, you can certainly set the hostname to www.whatever.com

Probably the most important factor is what you have propogated in dns. a dns record can point to for instance
192.168.0.1 as www and you can use cnames.

Also, you can bind as many IP addresses to a singe NIC as you want.

Here is a for instance...

ifconfig eth0 192.168.0.1
ifconfig eth0:0 10.10.10.1
ifconfig eth0:1 65.25.100.1

etc etc etc.

Now in your web server, you are merely going to create virtual hosts. They can be done on a name basis, or using ip based. If you do ip based, then those "virtual IP adresses" above will come into play.

Note: those virtual addresses made at the command line are only good until you reboot. If you want them retained via the boot process, then you need to make entries in the /etc/network/interfaces file

(I am assuming that box is debian based)

If it is redhat, then the file would be /etc/sysconfig/network-scripts/ifcfg-eth0:0 eth0:1 etc

So before any help can come that way, are you first off dealing with hostnames for the web server? Are you using apache web server using ip based or named based virtual hosts?
 
Old 08-27-2007, 07:07 AM   #3
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
The hostname on your mail server MUST match the Name registered in DNS for the MX record, or your server will get blacklisted.. so yeah it's sorta important.

Heres a quick guide on setting your servers hostname properly. http://www.cpqlinux.com/hostname.html



-

Last edited by farslayer; 08-27-2007 at 07:24 PM.
 
Old 08-27-2007, 10:36 AM   #4
bskrakes
Member
 
Registered: Sep 2006
Location: Canada, Alberta
Distribution: RHEL 4 and up, CentOS 5.x, Fedora Core 5 and up, Ubuntu 8 and up
Posts: 251

Rep: Reputation: 32
Hi there!

Are you hosting only one web site or do you plan on hosting many? Looks like you are going to host both your site and your friends site plus a clients.

Are you using any sort of Web Hosting Control Panel? Where did you purchase this hosting package from?

From my knowledge and experience I name my server whatever I want. I am hosting virtual sites so each site has its own settings. For example site getalifespammers.com would have the following setup for DNS records:
A record - IP address of your server 68.100.123.123
CNAME - getalifespammers.com
Pointer - getalifespammers.com
Mail MX Record(s) - mail.getalifespammers.com (this can be different depending on your clients HOME/BUSINESS isp - some isp's block port 25 so they wont be able to use your mail server (SMTP incoming/outing)

Once I know a little more about the server package you purchased and what was included I can help.

Cheers!

Last edited by bskrakes; 08-27-2007 at 10:38 AM.
 
Old 09-03-2007, 03:22 PM   #5
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Original Poster
Rep: Reputation: 30
Hey. The original message is a few years old. I've changed hosts since then and its now much more managed and working correctly. Thanks for the help.
 
Old 09-03-2007, 10:08 PM   #6
bskrakes
Member
 
Registered: Sep 2006
Location: Canada, Alberta
Distribution: RHEL 4 and up, CentOS 5.x, Fedora Core 5 and up, Ubuntu 8 and up
Posts: 251

Rep: Reputation: 32
No prob, if you need anything just PM me.

Cheers!
 
Old 09-04-2007, 10:54 AM   #7
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
weird.. how did I end up replying to a message that was 3 years old.. I didn't search for it.. **scratches head** Oh well
 
Old 09-04-2007, 11:50 AM   #8
bskrakes
Member
 
Registered: Sep 2006
Location: Canada, Alberta
Distribution: RHEL 4 and up, CentOS 5.x, Fedora Core 5 and up, Ubuntu 8 and up
Posts: 251

Rep: Reputation: 32
it showed up in the list as one of the newer threads... even though it wasn't new.... weird!
 
  


Reply



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
Two hardware-related questions DaBlade Linux - Hardware 4 10-27-2005 01:33 PM
3 non-related questions Rognon Slackware 5 02-06-2004 04:45 PM
some daemon-related questions Vincent Slackware 3 09-21-2003 02:15 PM
Internet-related questions loner Linux - Newbie 4 07-07-2003 09:00 AM
2 slack related questions NetScripter Slackware 3 10-13-2002 12:38 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:44 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