0
cvlc --play-and-exit /usr/share/sounds/My_Sounds/Alarm-sound-buzzer.mp3 2> /dev/null

When I use this, I get these irritating messages like

Simple mixer control 'Master',0
  Capabilities: pvolume pswitch pswitch-joined
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 65536
  Mono:
  Front Left: Playback 19661 [30%] [on]
  Front Right: Playback 19661 [30%] [on]

Any to suppress them?

  • Does this happen with normal typical audio files? – doug Aug 12 '18 at 10:25
  • @doug Yes. With mp3 files. I am using Ubuntu Mate 18.04. It never occurred with 16.04. – fixit7 Aug 12 '18 at 12:29
  • If you were to run the same commands but using vlc instead do you see the same? If so what does just plain vlc produce in terminal? – doug Aug 13 '18 at 12:12
  • 2
    Possible duplicate of What does 2>/dev/null mean? – Fabby Aug 13 '18 at 20:59
2

Instead of just redirecting stderr with 2>, replace it with &> to redirect both stdin and stderr to /dev/null

cvlc -q --play-and-exit /usr/share/sounds/My_Sounds/Alarm-sound-buzzer.mp3 &> /dev/null
  • It did not help. – fixit7 Aug 12 '18 at 4:31
  • @fixit7 try adding the -q flag as shown – Amith KK Aug 12 '18 at 6:49
  • -q did not help. Did you try this out? – fixit7 Aug 12 '18 at 7:38
  • @fixit7 It seems to work for me even without the -q flag – Amith KK Aug 15 '18 at 4:46
0

This can be made to work by redirecting all output (error and normal output) to /dev/null

cvlc --play-and-exit /home/andy/MY_SOUNDS/Tone.wav /dev/null 2>&1
  • Don't you mean ... >/dev/null 2>&1 (mind the first >)? – David Foerster Aug 15 '18 at 21:22
  • This works. cvlc --play-and-exit /usr/share/sounds/My_Sounds/Alarm-sound-buzzer.mp3 > /dev/null 2>&1 – fixit7 Aug 15 '18 at 22:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.