This is a situation where you need ETRN. ETRN is not an acronym like SMTP or POP. It is an SMTP command used by remote hosts to force a server to queue mail to a client. It is defined in RFC 1985: SMTP Service Extension for Remote Message Queue Starting.
This is done with a Perl script or with a bash script. The source code for sendmail includes a copy of etrn.pl but it's not included in the Red Hat Linux binary RPM for sendmail. If you really need it you can get it by downloading the source code for sendmail from sendmail.org or installing the src.rpm and extracting it from there.
You could also use fetchmail to do the same thing. See man fetchmail for more information but essentially to use fetchmail for ETRN your .fetchmailrc would look something like this:
poll server.uguessit.com proto ETRN
Set the permissions on your .fetchmailrc file to 0710 by issuing the command chmod 0710 .fetchmailrc. Then to run fetchmail run the command like shown below:
[root@boss /root]# fetchmail -v -S server.uguessit.com fetchmail: 5.1.0 querying server.uguessit.com (protocol ETRN) at Sun, 05 Dec 1999 19:54:57 -0500 (EST) fetchmail: SMTP< 220 server.uguessit.com ESMTP> fetchmail: SMTP< EHLO boss.uguessit.org> fetchmail: SMTP< 250-server.uguessit.com fetchmail: SMTP< 250-PIPELINING fetchmail: SMTP< 250-SIZE 10240000 fetchmail: SMTP< 250-ETRN fetchmail: SMTP< 250 8BITMIME fetchmail: ETRN< ETRN ns.uguessit.org fetchmail: ETRN< 250 Queuing started fetchmail: Queuing for ns.uguessit.org started fetchmail: Polling server.uguessit.com fetchmail: ETRN< QUIT fetchmail: SMTP< 221 Bye fetchmail: normal termination, status 0
You could also create a cronjob which would force a connection and an ETRN query at the interval you specify (once an hour for example).
|4.11 I'm running sendmail on my firewall or bastion host but I don't want my users accessing this machine to send and receive mail. The external MX records all point at the bastion host which works fine, but I want to configure a host on my internal network for my users to use to send and receive mail. How do I get the mail off of the bastion host and onto the internal host, and how do I still use the bastion host to route the mail?||Up||Additional Questions?|