LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-28-2005, 12:48 PM   #1
bokini
LQ Newbie
 
Registered: Oct 2003
Posts: 9

Rep: Reputation: 0
stderr messages


hello
Im having a little problem here
I got this code in a script:

test=`smbmount //ip/partition directory/ -o username=user,password=pass`

when the partition or the ip are wrong the smbmount return 3 messages do the stdout, that 3 messages goes directly to de $test. BUT there is another message that goes do the stderr (monitor). What a want to do is to put all the messages in the $test so i can analize the erros.
 
Old 11-29-2005, 08:30 AM   #2
Agrouf
Senior Member
 
Registered: Sep 2005
Location: France
Distribution: LFS
Posts: 1,596

Rep: Reputation: 80
test=$(smbmount //ip/partition directory/ -o username=user,password=pass 2>&1)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
stderr is not a tty - where are you? lazyboy0001 Slackware 12 12-02-2005 10:44 AM
Redirecting error messages to stderr and file in Bash lowpro2k3 Programming 1 04-14-2005 07:47 PM
stderr redirection evilop Linux - Newbie 3 09-21-2004 05:27 PM
redirecting stderr nodger Programming 2 03-11-2004 11:58 AM
stderr is not a tty where are you? davidschob Slackware 6 10-31-2003 11:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration