Hello.
After reading a lot of things I have built my postfix config from robin_listas’s thread :
https://forums.opensuse.org/showthread.php/473991-Setting-up-postfix-to-send-local-mail-to-an-internet-email-address-OpenSUSE-12-1
In the following user1a, user1b, user1c are user account @ ISP; and user_1a, user_1b, user_1c are linux account users @ my local network.
I should have miss things because my test mail sent from the linux local network server by user_1a is delivred to the mailbox user_1a @my_local_network. The test was done under the user account and not under root account.
aliases : http://paste.opensuse.org/46868116
generic : http://paste.opensuse.org/70647934
main.cf : http://paste.opensuse.org/30964508
master.cf : http://paste.opensuse.org/82676013
sasl_passwd : http://paste.opensuse.org/49225605
sender_canonical : http://paste.opensuse.org/36874958
sender_relayhost : http://paste.opensuse.org/36154735
virtual : http://paste.opensuse.org/54742290
The command (from user_1a linux session) :
echo "This is the message body and contains the message from mailx -USING MAILX " | mailx -s "Test with mailx - port 587" -r "user1a@free.fr" user1b@free.fr
journalctl:
May 02 20:15:27 hostname-1 postfix/pickup[4056]: 1C709E01D5: uid=1001 from=<user1a@free.fr>
May 02 20:15:27 hostname-1 postfix/cleanup[4614]: 1C709E01D5: message-id=<5545143f.36RlPVkO6OaL1B2f%user1a@free.fr>
May 02 20:15:27 hostname-1 postfix/qmgr[4057]: 1C709E01D5: from=<user1a@free.fr>, size=541, nrcpt=1 (queue active)
May 02 20:15:27 hostname-1 postfix/local[4616]: 1C709E01D5: to=<user_1b@hostname-1.my-dom-test.nwk>, orig_to=<user1b@free.fr>, relay=local, delay=0.14, delays=0.1/0/0/0.04, dsn=2.0.0, status=sent (delivered to mailbox)
May 02 20:15:27 hostname-1 postfix/qmgr[4057]: 1C709E01D5: removed
It seems that user1b@free.fr (good destination) is rewrite in user_1b@hostname-1.my-dom-test.nwk who is linux local user.
The delivered mail:
From [EMAIL="user1a@free.fr"]user1a@free.fr[/EMAIL] Sat May 2 20:15:27 2015
Return-Path: <user1a@free.fr>
X-Original-To: [EMAIL="user2a@free.fr"]user2a@free.fr[/EMAIL]
Delivered-To: [EMAIL="user_2a@hostname-1.my-dom-test.nwk"]user_2a@hostname-1.my-dom-test.nwk[/EMAIL]
Received: by hostname-1.my-dom-test.nwk (Postfix, from userid 1001)
id 1C709E01D5; Sat, 2 May 2015 20:15:27 +0200 (CEST)
Date: Sat, 02 May 2015 20:15:27 +0200
From: [EMAIL="user1a@free.fr"]user1a@free.fr[/EMAIL]
To: [EMAIL="user2a@free.fr"]user2a@free.fr[/EMAIL]
Subject: Test with mailx - port 587
Message-ID: <5545143f.36RlPVkO6OaL1B2f%user1a@free.fr>
User-Agent: Heirloom mailx 12.5 7/5/10
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
This is the message body and contains the message from mailx -USING MAILX
After I have modify sasl_passwd and sender_relayhost I make another try, but the address of the recipient of the mail is still incorrect. sasl_passwd : http://paste.opensuse.org/13332412
sender_relayhost : http://paste.opensuse.org/65860146
Test Command : http://paste.opensuse.org/78556842
journalctl : http://paste.opensuse.org/35223866
sender : user_1a.mailbox : http://paste.opensuse.org/53734161
recipient : user_1b.mailbox : http://paste.opensuse.org/80866384
Any help is welcome