Results 1 to 5 of 5

Thread: Send mail from command line in Linux

  1. #1
    Join Date
    Mar 2010
    Posts
    202

    Send mail from command line in Linux

    Hello,
    I wish I could send mail from the command line in Linux based operating system
    > Mutt-s "test send"-a ". / Foo.txt" mon@adresse.com foo.txt
    I have no error but the mail never arrives. So I install the software 'biabam' which serves just to send mails with a piece, command line (and do nothing else). But the mail still can not:
    Code:
    > Echo "test of sending mail" | biabam foo.txt-s "hello hey ho" mon@adresse.com
    I think it is because I never specified SMTP server. But I do not know or configure the server address? Any help regarding this is appreciated. Thanks in advance.

  2. #2
    Join Date
    Nov 2009
    Posts
    343

    Re: Send mail from command line in Linux

    Hello,
    there 's probably way to specify your SMTP server but I think it uses the default smtp server locally (on localhost), gender sendmail or postfix. Otherwise, more simple, you have the mail command. If you need more details for sending the mail then you can fire the man command with the keyword front of it, you will find detailed help about the same. I hope you will do this.

  3. #3
    Join Date
    Nov 2009
    Posts
    335

    Re: Send mail from command line in Linux

    Hello,
    I am not attempting a mutt-x. But first you should do a "man mutt" because mutt is a mail client so he can not send mail:
    Here is what you have to do
    Code:
    mutt (1) User Manual mutt (1)
    DESCRIPTION
           Small but very powerful, Mutt is a client for reading court-
           courier text mode under operating systems like Unix. It
           including support color terminals, MIME, and a representation
           Chart of the discussion tree.

  4. #4
    Join Date
    Dec 2009
    Posts
    192

    command line mail from linux

    Hello,
    Even i am trying a similar kind, that is I am trying to send a mail from the command line. I tried with the mail command:
    Code:
    mail-s "subject" mon@adresse.com somemessage
    and it is not send to the sender and also it is not received there. I guess I am correct with the syntax, I mean the command line. If I am wrong then please correct me with the same. Any other command to do the same that is to send the mail, if you know one then it will be appreciated. Thanks in advance.

  5. #5
    Join Date
    Nov 2009
    Posts
    518

    linux command line mail

    Hello,
    Just have a look at this
    Code:
    mail marcg@paradis.com <somefile text
    and in a script:
    Code:
    marcg@paradis.com mail <<EOF
    here is contained
    my
    Courier
    EOF
    you can put anything else instead of EOF condition that the sequence of character does not appear in the message.

Similar Threads

  1. Command Line in Linux to clear the /tmp folder
    By BBC123 in forum Operating Systems
    Replies: 4
    Last Post: 26-02-2012, 02:41 PM
  2. How to perform Cut and paste from command line in Linux
    By Malik B in forum Operating Systems
    Replies: 4
    Last Post: 11-11-2010, 04:12 PM
  3. Inroduction of Linux command line
    By Ceesar in forum Operating Systems
    Replies: 5
    Last Post: 31-12-2009, 02:20 AM
  4. How to send email from the Linux command line
    By roumieh2000 in forum Windows Software
    Replies: 4
    Last Post: 15-09-2009, 06:38 PM
  5. Download files from Linux command line
    By chaosblade in forum Operating Systems
    Replies: 3
    Last Post: 28-08-2009, 03:18 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,713,503,737.51624 seconds with 17 queries