Sponsored Content
Full Discussion: trouble using mailx command
Top Forums Shell Programming and Scripting trouble using mailx command Post 18719 by ldrojasm on Tuesday 2nd of April 2002 10:39:19 AM
Old 04-02-2002
Data trouble using mailx command

Hi. I have been trying to send mail using the mailx command. I also tryed to use the mail command.

The thing is that when I try to send the email, i receive automatically to my mailbox a DAEMON response sayng that the mailhost is unknown...

The syntax I am using is this:

$mailx -s "this is a test" myaddress@mydomain.com < /home/myhome/filetosend

the file "filetosend" is the file that i want to send as the body of the msg.

and what i get is this:

To: ldrojasm
MIME-Version: 1.0
Subject: Returned mail: Host unknown (Name server: mailhost.mydomain.com: host not found)
Auto-Submitted: auto-generated (failure)

The original message was received at Tue, 2 Apr 2002 17:24:56 -0600 (CST)
from ldrojasm@localhost

----- The following addresses had permanent fatal errors -----
myaddress@mydomain.com

----- Transcript of session follows -----
550 myaddress@mydomain.com... Host unknown (Name server: mailhost.mydomain.com: host not found)

thanx
 

10 More Discussions You Might Find Interesting

1. AIX

Trouble formatting egrep command with AWK

Hi, I'm new to scripting and AIX. I'm running the following: lspv | awk '{ print "lspv",$1" | egrep 'PP\|PHYSICAL'; lspv -l",$1 }' Which creates this command: lspv hdisk0 | egrep PP|PHYSICAL; lspv -l hdisk0 lspv hdisk1 | egrep PP|PHYSICAL; lspv -l hdisk1 Troube is, I need the... (2 Replies)
Discussion started by: cruiser
2 Replies

2. UNIX for Dummies Questions & Answers

Trouble with flex command in makefile

Hey all, im trying to create a makefile in unix. cpp2html is a program created from the files cpp2html.o and lex.yy.o. cpp2html.o is created from compiling cpp2html.c and lex.yy.o is created from another created file lex.yy.c. and lex.yy.c is created from a command "flex cppscanner.l" and here is... (1 Reply)
Discussion started by: iwatk003
1 Replies

3. Shell Programming and Scripting

Mailx: How to send a attachment using mailx command

Hi All, Can anyone please provide the command for sending an mail with attachment using mailx command. Thanks in Advance :) Regards, Siram. (3 Replies)
Discussion started by: Sriram.Vedula53
3 Replies

4. UNIX for Dummies Questions & Answers

Trouble with the Source command..

Hi everyone, I've been writing a script as an assignment which essentially does the exact same thing as the tree -d function (bash shell btw), except next to every directory name it gives a number which you can input into the same command in order to change the current working directory to the... (1 Reply)
Discussion started by: petey22uk
1 Replies

5. Shell Programming and Scripting

trouble executing a command in csh

Hi All!! I am having trouble in executing the following command into a c-shell script. mv "$file" "$(head -1 "$file")" The funny thing is that the same command works perfectly from the command line, but when incorporated into a "foreach loop" of a c-shell script, it shows an error -... (1 Reply)
Discussion started by: chen.xiao.po
1 Replies

6. Shell Programming and Scripting

Command pipeline trouble

Hello, I am attempting to ssh to a server and run a set of commands on a remote set of servers. I am getting the following error below, I am thinking quotes may be the problem. This command works on the local machine in bash. Not when I ssh to a remote server. Basically the command should... (3 Replies)
Discussion started by: jaysunn
3 Replies

7. Shell Programming and Scripting

Trouble with awk command

Hi, I need to read a string with ; separated using loop one filed by one field and perform some operation. Can you please check and let me know how to print command parameterised. key=phani;ravi;kiran number_of_keys=`echo $key|awk '{print NF}' FS=';'` for (( i = 1; i <= $number_of_keys;... (4 Replies)
Discussion started by: Ravindra Swan
4 Replies

8. Shell Programming and Scripting

Trouble with variable and command assignment

I have a section of a script where I want to check a log file for a certain oracle error and if there is only one error (and it is ORA-39152) then I want to email that script is complete. Otherwise email failure and log. Somehow with this while the log only has one error and it is ORA-39152, I... (5 Replies)
Discussion started by: cougartrace
5 Replies

9. Shell Programming and Scripting

Trouble using awk command

Hi, I have 2 .txt pads containing data. I need a script which reads content of one .txt file, performs some operations and calculates a number which is stored in a variable. Now , all the content of another .txt pad should be appended to first .txt pad at pre calculated nth line number. ... (4 Replies)
Discussion started by: Ravindra Swan
4 Replies

10. UNIX for Advanced & Expert Users

awk trouble inside another command

I tried running this. dsh -w server1 'lsof /audit | awk '{ print $2 }'' It did not like above so I tried to escape the single parenthesis at the end. dsh -w server1 'lsof /audit | awk '{ print $2 }\'' It then hung so I changed up the parenthesis to this. This worked. dsh -w server1... (6 Replies)
Discussion started by: cokedude
6 Replies
SCRIPT-EMAIL(8) 					  System Administration Commands					   SCRIPT-EMAIL(8)

NAME
script-email - Amanda script to send email notifications DESCRIPTION
script-email is an Amanda script implementing the Script API. It should not be run by users directly. It sends a notification email to the addresses specified in the MAILTO property. PROPERTIES
This section lists the properties that control script-email's functionality. See amanda-scripts(7) for information on the Script API, script configuration. MAILTO List of email addresses that will receive an email on command execution. It is a multi-valued property: property "MAILTO" "amanda@domain.com" "sysadmin@domain.com" "amandauser@domain.com" EXAMPLE
In this example, script-email is scheduled to be run before the DLE, on the server. The unqualified email address amanda will be passed to the email system unchanged. The script is then attached to a dumptype, which can then be specified for any DLEs which require notification. define script-tool pre-email { comment "email me before this DLE is backed up" plugin "script-email" execute-on pre-dle-backup execute-where server property "mailto" "amanda" } define dumptype user-tar-email { user-tar script "pre-email" } SEE ALSO
amanda(8), amanda.conf(5), amanda-client.conf(5), amanda-scripts(7) The Amanda Wiki: : http://wiki.zmanda.com/ AUTHORS
Jean-Louis Martineau <martineau@zmanda.com> Zmanda, Inc. (http://www.zmanda.com) Dustin J. Mitchell <dustin@zmanda.com> Zmanda, Inc. (http://www.zmanda.com) Amanda 3.3.1 02/21/2012 SCRIPT-EMAIL(8)
All times are GMT -4. The time now is 04:55 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy