LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 07-16-2004, 10:21 AM   #1
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Rep: Reputation: 0
Postfix Domain name problem


Hello i am new to linux but i have setup a postfix server on mandrake 10.

it is a basic setup from a tutorial, the server will send but not receive.

i think the problem is a domain name setting in linux somewere, the outgoing email are coming out as my host name not domain name.

if anyone can help i would be greatful.
 
Old 07-16-2004, 12:20 PM   #2
edcutis
Member
 
Registered: Jun 2003
Location: USA, Missouri
Distribution: mandriva , Kubuntu, MEPIS
Posts: 140

Rep: Reputation: 15
In order for postfix to receive email from the internet, don't you have to have that mail domain registered with dns? Have you made an **MX** record with DNS? If you are using a dynamic internet connection, you must register your DNS and MX records with a DNS registrar, and update them every time they change.

I use http://dyndns.org They offer a free account and utilites to update your DNS record (and MX mailserver record).

Postfix will automatically relay outbound emails through your ISP's mailserver, if you set it up that way. This may be why your outbound traffic is getting out, but inbound traffic has to know the DNS/to/IP translation to get to you.

Example: bigmailserver.fuzzy.homelinux.org = 192.168.1.22
 
Old 07-16-2004, 08:05 PM   #3
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
dns

thank you for the replay,

i have a no-ip.com doing all that for me i can telnet into my mail server useing "telnet main.domain.com smtp" so i a pretty sure this is not the problem.

postfix seems to be getting my hostname from somewere other than the main.cf.

i have entered hostname = main.domain.com and domainname = domain.com but it is not using these names.
 
Old 07-16-2004, 08:38 PM   #4
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
this is my main.cf file

mydomain = domain.com.au
myhostname = mail.domain.com.au
mydestination = $myhostname, $mydomain, localhost.$mydomain
myorigin = $mydomain

but when i send mail it is sent from user@comp001 not user@domain.com.au

i can not work out why it is using comp001 nor where it is getting it from.

Last edited by fuzzy_trb; 07-16-2004 at 08:42 PM.
 
Old 07-16-2004, 09:48 PM   #5
edcutis
Member
 
Registered: Jun 2003
Location: USA, Missouri
Distribution: mandriva , Kubuntu, MEPIS
Posts: 140

Rep: Reputation: 15
Do you have webmin installed? Webmin makes it easy to see all your postfix settings, laid out in a nice gui. That's how I set mine up. You can see and adjust your name, hostname vs domain name from there.

I guess you could do it the old fashioned way, and edit the conf file. I like to use webmin whenever I can. :>
 
Old 07-16-2004, 09:54 PM   #6
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
webmin

yes i have webmin installed,

I have set the domain setting but it still comes up under "user@comp001"
 
Old 07-16-2004, 10:33 PM   #7
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
Stupid question, but did you restart Postfix after setting the domain name in the config file? Most servers don't automaticcaly detect changes and need to be restarted. Also, check your mail log, the mail might be getting there, but is being rejected for some reason (you're maillog is usually /var/log/maillog).
 
Old 07-16-2004, 11:06 PM   #8
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
restart and logs

yes i did restart the server after each change.

in the logs i have found an error
fatal: open database /var/lib/mailman/data/aliases.db: No such file or directory

connect from bay1-f8.bay1.hotmail.com[65.54.245.8]
lost connection after CONNECT from bay1-f8.bay1.hotmail.com[65.54.245.8]
disconnect from bay1-f8.bay1.hotmail.com[65.54.245.8]

but i do not know if this has anything to do with my problem nor how to fix it.
I think the bottom error is when i have tryed to send an email to myself

Sorry about all this thanks for your help, please bear with me.

Last edited by fuzzy_trb; 07-16-2004 at 11:13 PM.
 
Old 07-17-2004, 01:31 AM   #9
Pete M
Member
 
Registered: Aug 2003
Location: UK
Distribution: Redhat 9 FC 3 SUSE 9.2 SUSE 9.3 Gentoo 2005.0 Debian Sid
Posts: 657

Rep: Reputation: 32
fuzzy_trb

Quote:
i can not work out why it is using comp001 nor where it is getting it from.
Have you set your hostname and domain name in /etc/hosts and /etc/sysconfig/network

Not sure about Postfix but Sendmail checks these files to determine which domain it is responsible for

Just a wild guess but may help

Pete
 
Old 07-17-2004, 01:37 AM   #10
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
yes i just had a look in network and the domain and hostname are both set.
my hostname is comp001 but i do not know why it is using this and not my domainname
 
Old 07-17-2004, 01:52 AM   #11
Pete M
Member
 
Registered: Aug 2003
Location: UK
Distribution: Redhat 9 FC 3 SUSE 9.2 SUSE 9.3 Gentoo 2005.0 Debian Sid
Posts: 657

Rep: Reputation: 32
fuzzy_trb

etc/hosts should look something like this

127.0.0.1 localhost.localdomain localhost
192.168.0.10 mybox.mydomain.com mybox

/etc/sysconfig/network like this

NETWORKING=yes
HOSTNAME=mybox

I have no idea if this is your problem just trying to help postfix is obviously getting comp001 from these files so just check that the format is correct

If you make any changes to these files you may have to reboot to make the changes take effect

Regards
Pete
 
Old 07-18-2004, 03:44 AM   #12
fuzzy_trb
LQ Newbie
 
Registered: Jul 2004
Location: Australia
Distribution: mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
well that did not work, but i got around the problem by changing my hostname to domain.com.au

it the bad way of doing things but it works.

Thanks to veryone that tried to help.
 
  


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
Fetchmail/Postfix domain problem EldinTux SUSE / openSUSE 0 01-09-2005 05:47 AM
POSTFIX+REPLY Domain PRoblem pin_bk Linux - General 3 09-15-2004 04:25 AM
Postfix: localhost.domain.com iantri Linux - Networking 8 07-27-2004 11:21 AM
Postfix virtual domain eyt Linux - Newbie 0 02-23-2004 05:07 PM
Mysql - Postfix alias domain paulten Linux - Networking 0 11-03-2003 04:05 PM

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

All times are GMT -5. The time now is 12:50 PM.

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