Created attachment 327878 [details] soundcard.py 1 ) Description of problem: ------------------------------ It would be very helpful if we have a sos-plugin to gather the information on sound cards from the machine. Many a time, we have to request this information separately and this leads to the delay in the case resolution. 2 ) How reproducible: ------------------------ Currently there are no sos plugins to extract details on soundcards. 3 ) Steps to Reproduce: ---------------------------- a) Create a new file named 'soundcard.py' in the sos plugins directory '/usr/lib/python2.4/site-packages/sos/plugins/'. b) Add the following content in the file 'soundcard.py' : <snip> import sos.plugintools import commands import os class soundcard(sos.plugintools.PluginBase): """ Sound card information """ def setup(self): self.addCopySpec("/proc/asound/*") self.addCopySpec("/etc/alsa/*") self.addCopySpec("/etc/asound.*") self.collectExtOutput("/sbin/lspci | grep -i audio") self.collectExtOutput("/usr/bin/aplay -l") self.collectExtOutput("/usr/bin/aplay -L") self.collectExtOutput("/usr/bin/amixer") self.collectExtOutput("/sbin/lsmod | /bin/grep snd | /bin/awk '{print $1}'", suggest_filename = "sndmodules_loaded") return </snip> c) The above steps will create the sos plugin named 'soundcard'. This plugin can be run individually using the command 'sosreport --only-plugins=soundcard'. d) The collected details are : (i) /proc/asound/ (ii) /etc/alsa/ (iii) /etc/asound.state (iv) It creates a folder named 'soundcard' under the folder 'sos_commands' in the sosreport tar-ball and collects the output of the given commands : # '/sbin/lspci | grep -i audio' (To collect information of the audio controller, this information is already available in the file 'lspci' created by the plugin 'hardware.py'. But this is gathered again to bring all the details on sound cards to a single location) # '/usr/bin/aplay -l' (To collect the data on all the sound cards and audio devices [man aplay]) # '/usr/bin/aplay -L' (To collect the details on all the PCM devices [http://alsa.opensrc.org/index.php/PCM, man aplay) # '/usr/bin/amixer' (To collect the mixer settings of the default soundcards) # /sbin/lsmod | /bin/grep snd | /bin/awk '{print $1}' (This will gather the module names which are related to 'snd' and save it to a file name 'sndmodules_loaded') Additional info : This is only tested on RHEL5 machines and not on RHEL4 and lower.
Since this FutureFeature was not resolved for RHEL 5.4 Beta, it has been moved to RHEL 5.5 for inclusion consideration.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2010-0201.html