[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: How to diagnose hdd health?



On Tue, 2005-04-26 at 11:04, Red Hat wrote:
> What's the command to redirect error messages to a file?

Stderr is file descriptor 2, thus:

command 2>/path/to/file

Or for both stdout (1) and stderr:

command >/path/to/file 2>&1

And by the way, I wouldn't consider that a 'command to redirect'.  It
is just the syntax for the shell that parses every command line.  If
you don't specify where to connect standard I/O the file descriptors are
inherited from the parent process.

-- 
  Les Mikesell
   les futuresource com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]