Hi to all. I'm using Sendmail. I must send all mail sent by the system (cron notifications, for example) to an external address on my central server. For this I do:
Now I receive the mail on the central server and the correct address, but:
OK, now I have to see "sender in body" and "sender in headers" as a specific address, like "machine ID@machine hostname"; for this I try Sendmail's genericstable function, compile the file genericstable.db and add to the .mc file:
but it appears that this does nothing.
And now the question:
Thanks a lot for the support.
Bye.
- set user name:
pw usermod root -c "system ID"
- set machine hostname: in /etc/hosts:
Code:
127.0.0.1 "machine real name"
- add in .mc file:
Code:
define(`SMART_HOST',`main server address')
- add in .mc file:
Code:
define(`RELAY_MAILER_ARGS', `TCP $h PORT')
- add in /etc/mail/aliases
Code:
root: "address to send on central server"
make
and compile all files etc. etc. etc.
Now I receive the mail on the central server and the correct address, but:
- I receive in the mail body the "sender name" = root user name (point 1)
- I see in the mail header that the sender address is root@"hostname" (point 2)
OK, now I have to see "sender in body" and "sender in headers" as a specific address, like "machine ID@machine hostname"; for this I try Sendmail's genericstable function, compile the file genericstable.db and add to the .mc file:
Code:
FEATURE(genericstable)
And now the question:
- for this purpose, is it correct to use genericstable?
- if yes, what did I omit for it not to work?
Thanks a lot for the support.
Bye.