Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

mail on SunOS5.9

Status
Not open for further replies.

Calator

Programmer
Feb 12, 2001
262
AU
We have migrated from Digital Unix to Sun OS5.9.
We had shell scripts for emailing, invoking following command:

mail name@domain <file-name

This command no longer works under Sun, the message is saved to dead.letter

I checked "man mail" under Sun, the syntax appears a bit different, and there are NO examples to help me with this. I could see there is also rmail(recommended by Sun for sending email from applications) and mailx. Again the lack of examples in "man" makes it very difficult.

Can anyone help?
 

You an try using mailx:
Code:
mailx -t name@domain <file-name

[3eyes]


----------------------------------------------------------------------------
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
 
It did not work:

mailx -t name@domain <file-name
Ignoring recipients on command line with -t
No recipients specified

 
Try this...
Code:
mailx name@domain < file-name
The "[tt]-t[/tt]" option says to ignore any addresses on the command line and scan the body of the mail for "To:", "Cc:", and "Bcc:" fields. If the file you're mailing doesn't have them, then you will get an error message that looks something like...
Code:
Ignoring recipients on command line with -t
No recipients specified
 
The result of
mailx name@domain < file-name
is:
/home/ell6lg/dead.letter... Saved message in /home/ell6lg/dead.letter
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top