Welcome to the new location of Alien's Wiki, sharing a single dokuwiki install with the SlackDocs Wiki.

Welcome to Eric Hameleers (Alien BOB)'s Wiki pages.

If you want to support my work, please consider a small donation:

no way to compare when less than two revisions

Differences

This shows you the differences between two versions of the page.


Previous revision
Next revision
slackware:fixes [2006/04/14 14:40] alien
Line 1: Line 1:
 +===== Fixes for annoyances in Slackware =====
  
 +==== USB scanner and hotplug ====
 +
 +When you have a USB scanner attached to your computer when it boots, and the computer uses //hotplug// to initialize your hardware, you will probably see something similar to the following message: <code>
 +chown: cannot access `/proc/bus/usb/001/005': No such file or directory
 +chmod: cannot access `/proc/bus/usb/001/005': No such file or directory
 +</code> When you plug in your USB scanner //after// the computer has already booted up, the error does not appear and scanning works for non-root users. It is annoying to have to unplug the scanner before booting in order to be able to scan as a non-root user. Here's a fix.
 +
 +The problem is due to an error in the ''/etc/hotplug/usb.rc'' script, but that can be repaired easily. Look for the following line in  ''/etc/hotplug/usb.rc'' <code>
 +devbus=$( ( echo -n 000 ; cat $devlink/../../devnum ) | grep -o ...\$ )
 +</code> and change that line to <code>
 +devbus=$( ( echo -n 000`echo $devlink| sed 's/^.*usb\([0-9]\+\)\/.*$/\1/'` ) | grep -o ...\$ )
 +</code>
 +After this change, either reboot the computer or restart hotplug: <code>/etc/rc.d/rc.hotplug restart
 +</code> Now, the correct permissions and ownership are applied to the device file.
 +<note tip> Remember to add yourself to the ''scanner'' group if you want to use your scanner as a non-root user! You can use the ''vigr'' command to add your name to the ''scanner'' group, but if you're uncomfortable with directly editing the system files, here is a one-liner to add user 'geek' to group 'scanner' (replace 'geek' with your own account name): <code>
 +usermod -G $(id -Gn geek | tr ' ' ','),scanner geek
 +</code> If the group scanner does not exist, simply create it using the command <code>groupadd scanner</code>
 +</note>
 +
 +----------------
 +
 +==== ALSA OSS sequencer not loaded ====
 +
 +In Slackware 10.2, the ALSA OSS-compatible sequencer module is not loaded. This results in missing device files ''/dev/midi'' and ''/dev/sequencer''.\\
 +Edit the file ''/etc/rc.d/rc.alsa'' and look for the function <code>
 +load_alsa_oss_modules() {
 +  if ! cat /proc/modules | grep -wq snd-pcm-oss ; then
 +    if ! cat /proc/modules | grep -wq snd_pcm_oss ; then
 +      echo "Loading OSS compatibility modules for ALSA."
 +      modprobe snd-pcm-oss
 +      modprobe snd-mixer-oss
 +}</code> Add the following line after the line ''modprobe snd-mixer-oss'' in that function: <code>
 +      modprobe snd-seq-oss
 +</code> and restart ALSA.
 Fixes for annoyances in Slackware ()
SlackDocs