Re: mailx (how is it able to send email?!?)



Beowulf wrote:
I have mailx on my system, it was installed yesterday as part of the
package installation of aide. sudo apt-get install aide
(mailx got installed as a dependency)

My question is I do not really understand how mailx is able to send me
email, and it does because I tested it:
echo "Hi" | mailx -s "A test email message" myemail@xxxxxxxxx

How does the above work? I mean, when I set up an email account with
evolution or kmail I needed to specify my mail server of my ISP, username,
password, etc.

mailx tries to connect to the local SMTP (the one running on your computer), at least on Unix and Unix like OS's there are some kind of SMTP installed, they usually only listens to the localhost (127.0.0.1) and can deliver mail to your local machine or send it to a remote SMTP, but won't accept mail from the outside.

So in theory if I wanted to, could I
use mailx for all my email, have friends send me email somehow and then
read that email with mailx?

Yes, if you have a SMTP running on your machine which is accessible from the the internet and your ISP isn't blocking incoming traffic on port 25.


//Aho


--

//Aho
.



Relevant Pages

  • mailx (how is it able to send email?!?)
    ... I have mailx on my system, it was installed yesterday as part of the ... package installation of aide. ... sudo apt-get install aide ... Is mailx acting as a mail server, and does an ISP simply ...
    (alt.os.linux)
  • Re: Equivalent of mailx
    ... I checked with the firm's sys admins, ... me that mailx is not installed. ... RHEL installation we have. ...
    (comp.os.linux.misc)
  • Re: Equivalent of mailx
    ... me that mailx is not installed. ... RHEL installation we have. ... (this usually exists even if you have an other MTA then sendmail ... The header ends with the first empty line, ...
    (comp.os.linux.misc)
  • Sending SMTP mail via mailx
    ... I am confused on how mailx actually sends mail via SMTP ... ... What confuses me is that I have not told mailx (or sendmail for that ... IP address of my ISP's SMTP server. ...
    (comp.unix.solaris)
  • Re: send email from command line
    ... SMTP is a transport protocol which defines the interaction ... between a client and a server to move a mail message ... There is no dialogue in mailx's interaction with the sendmail process. ... It is simply a unidirectional pipe from mailx to sendmail down which the ...
    (Ubuntu)