Postfix help

Gerald Combs gerald at ethereal.com
Sun Mar 31 16:21:17 CST 2002


As you indicated, both Sendmail and Postfix need a fully qualified domain
name to start up.  You seem to have your hostname set to 'jojo' (with no
domain).  You can fix this by:

1) Forcing the issue system-wide.  Set your hostname to a FQDN by running
   'hostname jojo.my.domain' as root.  This address should be resolvable,
   either via DNS or by using /etc/hosts.  Note that this will get your
   mailer up and running, but outgoing mail will still appear to come from
   'jojo.my.domain' in some cases.

2) Force the issue in your mailer:

  a) If you're using Postfix, adjust the values of 'myhostname',
     'mydomain', and 'myorigin' in /etc/postfix/main.cf. 'Myhostname'
     and 'mydomain' let you force the system's host and domain names,
     respectively.  Technically you shouldn't need to set 'mydomain';
     by default it strips the first bit off of 'myhostname'.  'Myorigin'
     tells it to what name to use as the 'from' address in outgoing mail.
     On one of my machines I'm using the following values:

     myhostname=pow.zing.org
     mydomain = zing.org
     myorigin = $mydomain

  b) If you're using Sendmail, you first have to figure out if you're
     using old-style or new-style configuration files.  Sendmail has been
     around nearly 15 years, and the old-style configuration file was
     meant to be quickly parsed by the machines of that era.  Which is why
     the majority of a sendmail.cf file looks like line noise.  I don't
     know if Mandrake still uses the old-style config files or not.
     If it does, you can force your host name by using the 'w', 'm', and
     'j' directives, and your origin (Sendmail calls it masquerading)
     by setting the 'DM' directive in sendmail.cf like so:

     Dwjojo
     Dmmy.domain
     Djjojo.my.domain
     DMmy.domain

     If you're using the newer-style m4 configuration files, you would
     use the following:

     Dwjojo
     Dmmy.domain
     define(`confDOMAIN_NAME', `$w.$m')dnl
     MASQUERADE_AS(host.domain)

     Note the backtick (`) vs single quote (') usage - they make a
     difference.  Also note that if you're using a newer-style config
     you still have to convert it to an old-style config in order for
     the Sendmail executable to be able to use it.  Doing that is another
     couple of paragraphs and my fingers hurt.  More information can be
     found at http://www.sendmail.org/m4/basics.html.

On Fri, 29 Mar 2002, Chris Rickert wrote:

> I've got an issue with Sendmail/Postfix myself that should be pretty easy to
> troubleshoot.  It's also a FQDN issue i think.
>  
> using mandrake 8.1 on a desktop at home.
>  
> i am about 3 months into my whole linux experience.
>  
> i've got an apache webserver running with a domain name i registered
> through godaddy.com.  Using time warner kc roadrunner cable modem - DHCP, of
> course.  websites work great with the dynamic dns service www.hn.org
> <http://www.hn.org>  and virtual hosting in apache.  after getting mysql and
> php working, i set up a few websites that are "suppose" to send confirmation
> emails to those people who register login names.  At first i installed
> Sendmail from the mandrake CD.  the problem is when the php script calls the
> mail function, my sendmail would stall out.  maillogs of course said that
> "jojo" which is my machine's name, was unqualified domain name.  Sendmail
> must default to the machine name as the FQDN.  Of course i know this.  Now,
> is where I am confused.  Since i am using roadrunner, my host name is given
> to me via dhcp which is in the form: mkc-xx-xx-xx-xx.kc.rr.com.  know this
> from an nslookup.  I guess i don't know how to configure my machine to
> recognize the correct fully qualified domain name instead of 'jojo'(machine
> name). After fiddling with Sendmail config on Webmin, i was unsuccessful in
> getting it to work.  So i tried the postfix rpm.  Postfix will not start
> without knowing a fully qualified domain name.  My needs are simple.  I
> don't need a full fledged mail server.  I just need the system to
> occasionally send an email out when a user register on a website or if they
> forget a password.  Any ideas would be appreciated.  From reading the docs
> online, most of postfix & sendmail documentation is geared toward a more
> sophisticated setup than what i need.  It would be nice if i could get
> postfix to work and just relay my email to Roadrunner's smtp's mail servers
> that i normally use to send personal email on Kmail and Mozilla.  
>  
> end
>  
> madjack 
>  
> "I have not failed. I've just found 10,000 ways that won't work." - Thomas
> Alva Edison (1847-1931)
>  
> 
> 
> This e-mail and any files transmitted with it are confidential and are intended solely for the 
use of the individual or entity to whom they are addressed. If you are NOT the intended recipient 
or the person responsible for delivering the e-mail to the intended recipient, be advised that you 
have received this e-mail in error and that any use, dissemination, forwarding, printing, or 
copying of this e-mail is strictly prohibited. 
> 
> 
> 
> 




More information about the Kclug mailing list