Set default return address for all mails sent from mailx

Hi, I have a question about mailx in Red Hat:

If I use 'mail userid@mydomain.com -- -f root@mydomain.com', the return mail address will be root@mydomain.com.

How can I make all mails sent from this system use root@mydomain.com as return address by default?

Thank you in advance!

nz

It might be most robust to do it in sendmail rewrite rules, so all main originating on the host is rewritten. That takes care of everyone that sends mail using the localhost sendmail, but the right app, like netscape mail, could connect to a different SMTP/ESMTP server off-host. I have often done this when the local sendmail was locked up. I suppose a firewall could prevent off-host port 25 connections.