Re: File Write error

From: RANGI, JAI (JAI_RANGI@SDSTATE.EDU)
Date: Wed Apr 16 2003 - 15:19:58 EDT


rungms exam01 1> e01.log 2>&1 &
This command might create problem for me as the third argument is the number
of nodes the program can use default is 1. But this one worked for me
rungms exam01 > e01.log 2>&1 &

Thanks Simon....

Jai Rangi

From: Sergio Luiz Novaes [mailto:algol@LCC.UFMG.BR]
Sent: Wednesday, April 16, 2003 1:57 PM
To: aix-l@Princeton.EDU
Subject: Re: File Write error

">&" is CSH style for redirect. Simon give us the correct redirection for
SH/KSH.

Sergio Luiz Novaes
LCC/UFMG - CENAPAD-MG/CO
Tel: +55 31 3499 5391/4936
Fax: +55 31 3499 5390

It doesn't like the ampersand after the redirect. It expects to have a
number after that, to indicate a particular file descriptor. e.g. &1 for
standard out &2 for standard error or another number for some output file
that you've set up yourself.

I guess that you really want is...

rungms exam01 1> e01.log 2>&1 &

That will run your command in the background, (the final &), re-direct
Standard Out to e01.log and redirect Standard Error to the same place as
Standard Out. (It's important to put this AFTER you re-direct Standard
Out.)

Simon Green
Altria ITSC Europe s.a.r.l.

AIX-L Archive at http://marc.theaimsgroup.com/?l=aix-l&r=1&w=2
AIX FAQ at http://www.faqs.org/faqs/aix-faq/

N.B. Unsolicited email from vendors will not be appreciated.

> -----Original Message-----
> From: RANGI, JAI [mailto:JAI_RANGI@SDSTATE.EDU]
> Sent: 16 April 2003 19:26
> To: aix-l@Princeton.EDU
> Subject: File Write error
>
>
> I am trying to write the output to log file using the
> command below and its
> giving me this error... Can some give me any hint why I am
> getting this
> error.
>
> $ rungms exam01 >& e01.log&
> [1] 60942
> $ ksh: e01.log: 0403-007 Generated or received a file
> descriptor number that
> is not valid.
>
> [1] + Done(1) rungms exam01 >& e01.log&



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:45 EDT