Technical article 111465

How do I change the (from:) domain and node name for mailx email on my OpenServer machine?

OpenServer 5.0.0OpenServer 5.0.2OpenServer 5.0.4OpenServer 5.0.5OpenServer 5.0.6OpenServer 5.0.7

Written · Last revised

Problem

How do I change the domain name for email sent from my SCO OpenServer system? For example, email from my OpenServer machine says it's from:

root@machine1.somedomain.com
I want it to say:
root@themachine.other.domain.com

Cause

SCO OpenServer's mailx command compiles it from address using the variables from the file /usr/mmdf/mmdftailor.

This is also the case for systems that run sendmail or Office Mail Server.

In the /usr/mmdf/mmdftailor file there are two lines that change the mailx from address, MLNAME and MLDOMAIN.

Solution

To change your email, edit the /usr/mmdf/mmdftailor file. Below is an example:

MLNAME          machine1
MLDOMAIN        somedomain.com
MDLVRDIR        "/usr/spool/mail"
MMBXNAME        ""
MMBXPROT        0600
MLCKTYPE        advisory

With this setting, your email will look like it's from (with user root mailing out):

root@machine1.somedomain.com

Change the mmdftailor file so it now looks like this:

MLNAME          themachine
MLDOMAIN        other.domain.com
MDLVRDIR        "/usr/spool/mail"
MMBXNAME        ""
MMBXPROT        0600
MLCKTYPE        advisory

Your email will now look like it's from (with user root mailing out):

root@themachine.other.domain.com
NOTES:    Alternative for sendmail systems.

If you wish to have sendmail use the sendmail.cf file to change your email in this way, move the mmdftailor file out of the way:

# mv /usr/mmdf/mmdftailor /usr/mmdf/mmdftailor.bak

Now sendmail will use the sendmail.cf file to change your email.

Sendmail does NOT need to be restarted for these changes to take effect, it happens automatically every time an email is sent from any user on the system.

Another place where sendmail can store the system domain name is in: /opt/softmgmt/profiles/standard/SCO/SendMail/8.11.3Ni/rts/config

This file may have values for: HOSTNAME=machine1 DOMAIN=somedomain.com Changes to this file does require restarting sendmail.

NOTE:     On UnixWare systems, editing /usr/mmdf/mmdftailor has no effect on
          mailx and changing the from @domain.com requires that sendmail is
          configured to masquerade as domain.com.  In sendmail.cf this is
          noted by:
          DMdomain.com
          On later versions of sendmail in UnixWare, the masquerade option
          can be configured by /etc/mail/manage_sendmail, Miscellaneous Items.

See also

ta107656, "How do I hide the hostname in the origin line of my mail using sendmail?"

ta109776, "How can I test changes made to my sendmail.cf file?"

ta107702, "Basic troubleshooting for sendmail."

ta107679, "How can I get sendmail to recognize a new hostname?"

ta107667, "How do I configure sendmail to ignore case-sensitivity when looking up local usernames in mail addresses?"

From the Xinuos technical article database, record 111465. Reproduced with permission. The original is at www.sco.com/ta/111465, which is reachable but blocked from search engines.

Next step

Need this fixed rather than explained?

Tell us the release, what the system runs and what it is doing. We will reply by email with what we would do next.

  • You deal with the people who do the work
  • No obligation, and no upgrade required before we will help
  • We tell you plainly if something is not worth doing

Send an enquiry

We reply by email. If a server is down, say so in the first line. You can also write to help@scoexpert.com.