Operating System - Tru64 Unix
1753474 Members
4650 Online
108794 Solutions
New Discussion юеВ

Re: sendmail not using .forward

 
TMcB
Super Advisor

sendmail not using .forward

Hi everyone

My sendmail does not appear to be using .forward files for anyone except the root account.

When I send to root using :
# echo "this is a test" | /usr/sbin/sendmail -v root
/.forward: line 1: forwarding to \root, sapteam@s1rts.co.uk
... and so on..

When I send to any other user, even though their .forward files exist in their home directories :
# echo "this is a test" | /usr/sbin/sendmail -v orgadm
orgadm... Connecting to smtp.uk.aero.bxxx.net. via smtpr...

It doesnt even try to forward in the first line (as it did for root).

Would anyone have any ideas on this?
Much appreciated
8 REPLIES 8
Ivan Ferreira
Honored Contributor

Re: sendmail not using .forward

What do you see in the maillog? Ensure that the .forward file is owned by the user and does not allow group o world write.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
TMcB
Super Advisor

Re: sendmail not using .forward

Hi
Permissions semm Ok :
sappayorg> ls -l .forward
-rw-r--r-- 1 oraorg dba 30 Oct 4 2004 .forward


Mail.log file shows :
Oct 16 16:25:00 sappayorg sendmail[196160]: k9GFP0g0000196160: from=mcbridt, siz
e=15, class=0, nrcpts=1, msgid=<200610161525.k9GFP0g0000196160@sappayorg.s1rts.
co.uk>, relay=root@localhost
Oct 16 16:25:00 sappayorg sendmail[196160]: k9GFP0g0000196160: to=orgadm, ctladd
r=mcbridt (0/1), delay=00:00:00, xdelay=00:00:00, mailer=smtpr, pri=30015, relay
=smtp.uk.aero.bxxx.net. [172.25.81.97], dsn=2.0.0, stat=Sent (Message acce
pted for delivery)

Whereas when it works for root, mail.log shows :
Oct 16 15:14:36 sappayorg sendmail[194786]: k9GEEaG0000194786: to=\root,sapteam@
s1rts.co.uk, ctladdr=mcbridt (0/1), delay=00:00:00, xdelay=00:00:00, mailer=smt
pr, pri=60015, relay=smtp.uk.aero.bxxx.net. [172.25.81.97], dsn=2.0.0, sta
t=Sent (Message accepted for delivery)
Steven Schweda
Honored Contributor

Re: sendmail not using .forward

> sappayorg> ls -l .forward
> -rw-r--r-- 1 oraorg dba 30 Oct 4 2004 .forward

And whose home directory is this? "oraorg"?

[...] to=orgadm, [...]

Doesn't look to me like "oraorg". Or am I
missing something?


What's the user name to which you're sending
the e-mail?

What's the home directory of that user?

What's "ls -l" say about the ".forward" file
in the home directory of that user?

Does that user own his own ".forward" file?
TMcB
Super Advisor

Re: sendmail not using .forward

Hi

there are 2 users : orgadm and oraorg
the 2 .forward files are in their home directories and permissions are :

-rw-r--r-- 1 oraorg dba 30 Oct 4 2004 .forward

-rw-r--r-- 1 orgadm sapsys 30 Oct 4 2004 .forward
Don Ritchey
Frequent Advisor

Re: sendmail not using .forward

Make sure that all of the directories in the chain above the home directory of the users are NOT group-writable. The requirement on group writes is not just for the user's home directory, but for all directories in the path to the home directory. If, for example, the home directory path is "/opt/home/user", if either "/opt" or "/opt/home" is group-writable, then the forward action will fail.

We have been bitten by that "feature" here.
TMcB
Super Advisor

Re: sendmail not using .forward

Hi

just checked -
all dir's look OK. (/usr/users/oraorg)
drwxr-xr-x 34 root system 8192 Oct 3 14:19 usr
drwxr-xr-x 9 root dba 8192 Nov 22 2004 users
drwxr-xr-x 10 oraorg dba 8192 Oct 17 09:22 oraorg

Thanks
Philip Lawrence_1
Occasional Advisor

Re: sendmail not using .forward

try adding the user oraorg to the file /var/adm/sendmail/local.users as the mail may be going directly to the mailserver and bypassing the .forward file
TMcB
Super Advisor

Re: sendmail not using .forward

Issue was resolved when I ran "mailsetup" to reconfigure sendmail