From: RICCARDO on
On my last debian, which I'm using as smart, I'm not able to send
emails to specific domain.
In logs I can see
E.g.

1)on /tmp/ folder:
ls -l | sendmail r.castellani(a)example.com

msg is sent and in logs, on row where is written recipient "to", there
is written relay=212.102.33.45

2) on /
ls -l | sendmail r.castellani(a)example.com

msg is NOT sent and in logs, on row where is written recipient "to",
there is written relay=127.0.0.1 !

What happens to y / folder content ?
Why there is written localhost on as relay in 2) case ?
From: ska on
RICCARDO wrote:
> On my last debian, which I'm using as smart, I'm not able to send
> emails to specific domain.
> In logs I can see
> E.g.
>
> 1)on /tmp/ folder:
> ls -l | sendmail r.castellani(a)example.com
>
> msg is sent and in logs, on row where is written recipient "to", there
> is written relay=212.102.33.45
>
> 2) on /
> ls -l | sendmail r.castellani(a)example.com
>
> msg is NOT sent and in logs, on row where is written recipient "to",
> there is written relay=127.0.0.1 !

Actually, there should be two log lines, because you are submitting
the message to the local sendmail server first, which then relays the
message further on.

What does "mailq" says? Add "-v" option for verbose operation.

You might try "sendmail -Am", that should mean to run as server
instead of submission agent, but I may be wrong.

Regards, ska
From: RICCARDO on
On 5 Ago, 10:37, ska <s...(a)mail.inf.fh-brs.de> wrote:
> RICCARDO wrote:
> > On my last debian, which I'm using as smart, I'm not able to send
> > emails to specific domain.
> > In logs I can see
> > E.g.
>
> > 1)on /tmp/ folder:
> > ls -l  | sendmail r.castell...(a)example.com
>
> > msg is sent and in logs, on row where is written recipient "to", there
> > is written relay=212.102.33.45
>
> > 2) on /
> > ls -l  | sendmail r.castell...(a)example.com
>
> > msg is NOT sent and in logs, on row where is written recipient "to",
> > there is written relay=127.0.0.1 !
>
> Actually, there should be two log lines, because you are submitting
> the message to the local sendmail server first, which then relays the
> message further on.
>
> What does "mailq" says? Add "-v" option for verbose operation.
>
> You might try "sendmail -Am", that should mean to run as server
> instead of submission agent, but I may be wrong.
>
> Regards, ska

With:
ls -l | sendmail -v castellani(a)test.it

I got block during "data" stage:

250-PIPELINING
250-8BITMIME
250-SIZE 5242880
250-ETRN
250-DELIVERBY
250 HELP
>>> MAIL From:<root(a)example.it> SIZE=10797
250 2.1.0 <root(a)example.it>... Sender ok
>>> RCPT To:<castellani(a)test.it>
>>> DATA
250 2.1.5 <castellani(a)test.it>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .



While whith
ls -l | sendmail -Am castellani(a)test.it
went rights !!! It's sent.

Where is problem ?
From: RICCARDO on
On 5 Ago, 10:37, ska <s...(a)mail.inf.fh-brs.de> wrote:
> RICCARDO wrote:
> > On my last debian, which I'm using as smart, I'm not able to send
> > emails to specific domain.
> > In logs I can see
> > E.g.
>
> > 1)on /tmp/ folder:
> > ls -l  | sendmail r.castell...(a)example.com
>
> > msg is sent and in logs, on row where is written recipient "to", there
> > is written relay=212.102.33.45
>
> > 2) on /
> > ls -l  | sendmail r.castell...(a)example.com
>
> > msg is NOT sent and in logs, on row where is written recipient "to",
> > there is written relay=127.0.0.1 !
>
> Actually, there should be two log lines, because you are submitting
> the message to the local sendmail server first, which then relays the
> message further on.
>
> What does "mailq" says? Add "-v" option for verbose operation.
>
> You might try "sendmail -Am", that should mean to run as server
> instead of submission agent, but I may be wrong.
>
> Regards, ska

With:
ls -l | sendmail -v castellani(a)test.it

I got block during "data" stage:

250-PIPELINING
250-8BITMIME
250-SIZE 5242880
250-ETRN
250-DELIVERBY
250 HELP
>>> MAIL From:<root(a)example.it> SIZE=10797
250 2.1.0 <root(a)example.it>... Sender ok
>>> RCPT To:<castellani(a)test.it>
>>> DATA
250 2.1.5 <castellani(a)test.it>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .



While whith
ls -l | sendmail -Am castellani(a)test.it
went rights !!! It's sent.

Where is problem ?
From: RICCARDO on
On 5 Ago, 12:00, RICCARDO <ric.castell...(a)alice.it> wrote:
> On 5 Ago, 10:37, ska <s...(a)mail.inf.fh-brs.de> wrote:
>
>
>
> > RICCARDO wrote:
> > > On my last debian, which I'm using as smart, I'm not able to send
> > > emails to specific domain.
> > > In logs I can see
> > > E.g.
>
> > > 1)on /tmp/ folder:
> > > ls -l  | sendmail r.castell...(a)example.com
>
> > > msg is sent and in logs, on row where is written recipient "to", there
> > > is written relay=212.102.33.45
>
> > > 2) on /
> > > ls -l  | sendmail r.castell...(a)example.com
>
> > > msg is NOT sent and in logs, on row where is written recipient "to",
> > > there is written relay=127.0.0.1 !
>
> > Actually, there should be two log lines, because you are submitting
> > the message to the local sendmail server first, which then relays the
> > message further on.
>
> > What does "mailq" says? Add "-v" option for verbose operation.
>
> > You might try "sendmail -Am", that should mean to run as server
> > instead of submission agent, but I may be wrong.
>
> > Regards, ska
>
> With:
> ls -l  |  sendmail -v castell...(a)test.it
>
> I got block during "data" stage:
>
> 250-PIPELINING
> 250-8BITMIME
> 250-SIZE 5242880
> 250-ETRN
> 250-DELIVERBY
> 250 HELP>>> MAIL From:<r...(a)example.it> SIZE=10797
>
> 250 2.1.0 <r...(a)example.it>... Sender ok>>> RCPT To:<castell...(a)test.it>
> >>> DATA
>
> 250 2.1.5 <castell...(a)test.it>... Recipient ok
> 354 Enter mail, end with "." on a line by itself
>
> >>> .
>
> While whith
> ls -l  |  sendmail -Am castell...(a)test.it
> went rights !!! It's sent.
>
> Where is problem ?

It's very strange !!!
now it works with "ls -l | sendmail castell...(a)example.com" too.

I tried to put outside of my dmz network a windows client, using
telnet and it worked.

I tried, with a windows client inside my DMZ network, using telnet and
it worked.

From my smartHost, which is in from both ext. and int. network, I gave
same commands, but nothing !

Then I tried with -Am , it worked

Then I tried again with "ls -l | sendmail castell...(a)test.it " and
now worked !!!!
What's it happening ?