Hi, paul,

I got why, the first time I run the command is under "tcsh", after I change to "bash" the command works.

===========================================
mysql@/usr/local/mysql > /usr/local/bin/mysql -ujqu -pjqu1234@ --opt nondb > bkp_nondb.sql 2> err.log
Ambiguous output redirect.
mysql@/usr/local/mysql > echo $0
-tcsh
mysql@/usr/local/mysql > bash
bash-2.05a$ /usr/local/bin/mysql -ujqu -pjqu1234@ --opt nondb > bkp_nondb.sql 2> err.log
===========================================

"mysql@/usr/local/mysql >" is PS1 setting.
"bash-2.05a$" is PS1 setting.


From: Paul DuBois <[EMAIL PROTECTED]>
To: "Jannie Qu" <[EMAIL PROTECTED]>
Subject: Re: How to direct mysqldump error to a file?
Date: Tue, 19 Nov 2002 16:12:53 -0600

At 22:09 +0000 11/19/02, Jannie Qu wrote:
Hi, Paul,

Here is more meaningful representation:

===========================================
shell> /usr/local/mysql/output > /usr/local/mysql/bin/mysqldump
-umysql -pmysqlpw --opt nondb > bkp1.sql 2> err.log
===========================================

mysql@ is our PS1 prompt (am I using the right term?) I guess
stdin=0
stdout=1
stderr=2,

so I put 2>err.log there.
It's still malformed.  What is the "/usr/local/mysql/output >" supposed
to represent?  Your command has two ">" output redirection operators
in it, that's why you get the ambiguous output redirect error message.








From: Paul DuBois <[EMAIL PROTECTED]>
To: "Jannie Qu" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
Subject: Re: How to direct mysqldump error to a file?
Date: Tue, 19 Nov 2002 16:00:28 -0600

At 20:45 +0000 11/19/02, Jannie Qu wrote:
Hi, all,

sql, query.

I am scheduling a cronjob to backup mysql database using mysqldump.
================================
mysql@/usr/local/mysql/output > /usr/local/mysql/bin/mysqldump -umysql -pmysqlpw --opt nondb > bkp1.sql 2> err.log
Ambiguous output redirect.
================================

How I can direct any stderr to a file?

Thank you,
Jing
In this case, you can't, because your command itself is malformed.
mysqldump isn't even executing.

What's that "mysql@/usr/local/mysql/output >" stuff at the beginning
supposed to represent?

---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

_________________________________________________________________
MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus

_________________________________________________________________
Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail


---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to