From: WinterSun Zhao <zhaohl () midea ! com ! cn>
To: tru64-unix-managers
Subject: Summary: How to config mail server in Digital Unix
Date: Tue, 20 Mar 2001 01:03:23 +0000 [thread overview]
Message-ID: <98505031311586.tru64-unix-managers.marc@archive.invalid> (raw)
Hi, Experts:
With the help of you, the mail server in My Digital Unix 4.0E=
can send mail to my NT mail server now.
Thank all of you very much! More thanks to Mr. Phil Baldwin, I=
followed his advice at the first and it works.
Origin Question:
We are using Digital Unix 4.0E. Our mail server is base on MS=
NT4.0 and Exchange 5.0.
I want to know how to config mail server in Digital Unix, So=
I can let the system send mail to my mail
box on the NT when there is some thing need me to notice. We=
had not config NIS in digital unix.
So, would you please give me the detail procedure how to=
config the mail server in Digital Unix?(If it
need NIS to be set, then please tell me how to set it too.)
Answers:
Mr. Baldwin (baldwinp@eurodis.com ):
We use sendmail. This should be installed on your system. If=
not, I
believe it is on the OS distribution CD. In order for this to=
work, you need
to configure it in sendmail.cf (normally in /var/adm/sendmail).=
I've
enclosed a 'copy' of ours. You need to change the bits for <<your=
domain
name>>, <<your NTserver hostname>>.
=09The references to sendmail.cR and sendmail.hosts are to prevent
illicit relaying using the SMTP port by unscrupulous spammers.
=09sendmail.cR contains a list of permitted hosts that can relay=
(LAN
servers etc.)
=09sendmail.hosts contains a list of permitted sub-domain names=
(eg
fsmith@xxx.midea.com.cn)
=09Hope this helps in some way... <<sendmail.cf>>
The main modify of file /var/adm/sendmail/sendmail.cf is:
# Other local host names
Dw<<Insert your domain name>>
Cwlocalhost
Dz<<NT Server hostname >>
# major relay mailer (NOTE: same as $w)
DG<< Insert your domain name>>
# major relay host
#DRIBM_Mail_X
DR<< Insert your ISP's mail server eg post.xxxxx.co.uk>>
#DR
Dj$w
Then I tried and encounter the new problem as following:
> I had tried by add the following settings in the file.
> *****
> Dwmdmc2.11idemo
> Dzmidea.com.cn
> DG<< mdmc2.11idemo>>
> DRmidea.com.cn
> *****
> There is the definition of midea.com.cn and mdmc2.11idemo in=
the file
> /etc/hosts.
>
> But after I execute the following command:
> #mailx zhaohl@midea.com.cn
> It mailed me the following mail.
>
> ----- The following addresses had permanent fatal errors=
-----
> zhaohl@midea.com.cn
>
> ----- Transcript of session follows -----
> .. while talking to midea.com.cn:
> >>> MAIL From:<root@<<mdmc2.11idemo>>> SIZE=3D41
> <<< 553 malformed address: <root@<<mdmc2.11idemo>>> SIZE=3D41
> 501 zhaohl@midea.com.cn... Data format error
>
> ----- Message header follows -----
>
> Need your further help.
Then, Mr.Baldwin point out my mistake:
You don't want the double <<,>> in the file. Sorry, for not=
making it
clear....
After I had changed as his advice, it solved! I can send mail=
from my unix server to my NT mail server now.
**********
Mr. Hajnik (Ferenc Hajnik, FHajnik@suzuki.hu) replied me very=
soon too. He adviced:
You mustn't configure a NIS server.
If you use graphical interface then configure the mail as client.=
Write into
the fill-in your email server hostname. If you haven't got a=
graphical
interface then simpy add the following lines into yor=
sendmail.cf:
# name exported on external internet mail
DWemailservername
# Fake hosts in my domain
R$+ $#smtpr $@email $:$1 all other mail; gw
And when I encounted the new problem, he adviced:
You must configure your email server to route the mails. If you=
use
Exchange(we use it with more than 400 users) you can write in the=
domain
names where you want to send mails into the Exchange Server=
Administrator.
I think it is needed for me to send mails to Unix Server routed=
by NT server.
********
Mr. Araujo (Guilherme Teixeira de Araujo=
<garaujo@usiminas.com.br>) send a detail mail to me too. But=
because of different time-zone. When I read the mail, the=
problem had been solved with the advice of Mr. Baldwin=
(baldwinp@eurodis.com ).
I will try Mr. Araujo's advice later.
Thank you, Mr. Araujo.
I am sending the steps that I used to configure unix 4.0d to
communicate with my exchange server.
Bindsetup
Add
usiminas.com.br
Client
Hostname bind server : usiminasd01 =
--> wins
server name
Ip : 123.100.1.245 =
--> wins
server ip
Adicionar no hosts : Y
Order : 1
Change hostname : No
Mailsetup
Quick : No
Host definition : uipa01b12 =
-->
server name
Default Values : Y [ usiminasd01.usiminas.com.br ] =
--> wins
server name
Domain definition : usiminas.com.br
Top level : usiminas.com.br
General purpose relay : uipa01m02.usiminas.com.br =
-->
exchange server name
Tcp
2 [ mail hub-no ]
Format : tpc-3
N [ user aliases ]
Y [ aliases local ]
N [ uucp ]
N [ dec ]
N [ umc ]
N [ nick ]
Y
=B7 Include in \etc\hosts
=B7 123.100.0.252 uipa01m02.usiminas.com.br uipa01m02 =
-->
exchange server name
*************
Mr. Richardson (pricha - Phil Richardson <PRICHA@acxiom.co.uk>)=
Suggested:
check out the mailsetup command
I will try it later. Thanks!
**********
Mr. Pat ("O'Brien, Pat" <pobrien@mitidata.com>) Suggested:
run mailconfig
select client, and add using exchange as the relay system, and=
remove all
other mail server/standalone configs
I will try it later. Thanks!
*********
Mr. Dewhurst ("Dewhurst, Cy" <cy.dewhurst@rbch-tr.swest.nhs.uk>)=
give me another option for send mails.
I will try it later. Thanks!
And at the same time, I will forward Mr. Baldwin=
(baldwinp@eurodis.com ) 's mails to him.
The following is his advice:
Yeuch... sendmail!
I never could get it to work. You might have more joy with=
qmail
(www.qmail.org). Alternatively, you could do it raw using a=
script like
the following, you'll need expect. The script (mailit2) should=
be
called with:
cat mymessage | mailit2 fromaddress zhaohl@midea.com.cn "This is=
where
the summary goes"
You'll need to define a host called mailserver in /etc/hosts or=
change
the mailserver in the script.
smtp should also be defined as port 25 in /etc/services.
SCRIPT STARTS HERE--->
#!/bin/sh
cat - <<EXPECT > /tmp/mailit2.expect
#!/usr/local/bin/expect -f
# Script:=09mailit
# Date:=09=0917/5/2000
# Purpose:
# This script mails a recipient using SMTP
#if {[fork]!=3D0} exit
#disconnect
set timeout 10
spawn telnet mailserver smtp
send "HELO\r"
expect "250 OK"
send "MAIL FROM: $1\r"
expect "250 OK mail - from ($1)"
send "RCPT TO: $2\r"
expect "250 OK - Recipient ($2)"
send "DATA\r"
expect "354 Send data. End with CRLF.CRLF"
send "From: automailer\r"
send "Subject: $3\r"
send "\r"
EXPECT
echo "send \"\c" >> /tmp/mailit2.expect
cat - | while read FLINE; do
=09echo "$FLINE" >> /tmp/mailit2.expect
done
echo "\"" >> /tmp/mailit2.expect
cat - <<EXPECT >> /tmp/mailit2.expect
send "\r"
send "\r.\r"
expect "250 OK"
send "QUIT\r"
EXPECT
chmod +x /tmp/mailit2.expect
/tmp/mailit2.expect
rm /tmp/mailit2.expect
<--SCRIPT ENDS HERE
Hope this helps. If anyone does tell you how to configure=
sendmail to
do this, please let me know.
**********
Thank all of you again!
I find the list is very great!
(0765)-6339137
Oracle Database Administrator
Digital Unix Sys Admin
WinterSun Zhao
zhaohl@midea.com.cn
reply other threads:[~2001-03-20 1:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox