1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Random Linux+ Question March 21

Discussion in 'Linux+' started by tripwire45, Mar 21, 2006.

  1. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    A particular program is generating an excessive amount of error messages (named "error" in this case) that are of no use to you and you want to discard them rather than have to wade through them as they appear in a console session. Choose the best command below that will accomplish your task:

    1. error > /dev/null
    2. error >> /dev/null
    3. error 0> /dev/null
    4. error 0>> /dev/null
    5. error 2> /dev/null
    6. error 2>> /dev/null
     
    Certifications: A+ and Network+
  2. Bluerinse
    Honorary Member

    Bluerinse Exabyte Poster

    8,871
    167
    256
    [HIDE]I will go for 1 this time [/HIDE]
     
    Certifications: C&G Electronics - MCSA (W2K) MCSE (W2K)
  3. hbroomhall

    hbroomhall Petabyte Poster Gold Member

    6,623
    115
    224
    If I understand the q correctly - I'll go for [HIDE]5[/HIDE]

    Harry.
     
    Certifications: ECDL A+ Network+ i-Net+
    WIP: Server+
  4. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    Correct answer is 5. error 2> /dev/null. If you use the command error > /dev/null, error messages won't be picked up...just stdout messages.
     
    Certifications: A+ and Network+
  5. hbroomhall

    hbroomhall Petabyte Poster Gold Member

    6,623
    115
    224
    <Does a little dance> :biggrin

    Harry.
     
    Certifications: ECDL A+ Network+ i-Net+
    WIP: Server+
  6. Bluerinse
    Honorary Member

    Bluerinse Exabyte Poster

    8,871
    167
    256
    Learning is like chucking mud at a wall, some sticks but an awful lot just falls away :blink
     
    Certifications: C&G Electronics - MCSA (W2K) MCSE (W2K)

Share This Page

Loading...