nerdexam
LPI

010-150 · Question #18

How can the normal output of a command be written to a file while discarding the error output?

Sign in or unlock 010-150 to reveal the answer and full explanation for question #18. The question stem and answer options stay visible for context.

Legal, Professional, and Ethical Responsibilities

Question

How can the normal output of a command be written to a file while discarding the error output?

Options

  • Acommand >2>file 1&>/dev/null
  • Bcommand < output > /dev/null
  • Ccommand > discard-error > file
  • Dcommand > /dev/null 2&>1 output
  • Ecommand >file 2>/dev/null

Unlock 010-150 to see the answer

You've previewed enough free 010-150 questions. Unlock 010-150 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Topics

#I/O redirection#stderr#stdout#/dev/null
Full 010-150 Practice