Find the answer to your Linux question:
Results 1 to 3 of 3
Hi all, I'm following; Postfix Virtual MailBox Clam Smtp Howto https://help.ubuntu.com/community/Po...tual_mailboxes building a mail server. Coming to; Test ClamSMTP for outgoing mail Send this file as an attachment to info@domain1.com ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux Guru
    Join Date
    Sep 2004
    Posts
    1,814

    how to send mail on command with attachment


    Hi all,

    I'm following;
    Postfix Virtual MailBox Clam Smtp Howto
    https://help.ubuntu.com/community/Po...tual_mailboxes

    building a mail server.

    Coming to;
    Test ClamSMTP for outgoing mail
    Send this file as an attachment to info@domain1.com
    (it is a virus .zip file)

    $ uuencode eicar_com.zip | mail info@domain1.com
    It was hanging there for prolonged time. I have to cancel it manually.

    $ mutt -s "Test mail" -a eicar_com.zip info@domain1.com < /tmp/mailmessage.txt
    Code:
    Can't stat info@domain1.com: No such file or directory
    info@domain1.com: unable to attach file.
    Any clue? TIA

    B.R.
    satimis

  2. #2
    Just Joined!
    Join Date
    Nov 2007
    Location
    San Diego
    Posts
    17
    Have you tried without an attachment first?
    mail -s "test" info@domain1.com
    where domain1.com is your real domain name,and info is a real user.

    The command is mail -s, not mutt -s.

  3. #3
    Linux Engineer
    Join Date
    Apr 2012
    Location
    Virginia, USA
    Posts
    917
    mutt is a terminal email program.
    The syntax looks fine for mutt. As the previous user suggested, try sending without attachment. You may be having network issues / dns issues as well.

  4. $spacer_open
    $spacer_close

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •