Category: Troubleshooting

Updating PulseAudio to Nightly Build

Warning — This did not work, and I ended up going to Fedora instead!  So, don’t try this at home!

I just tried to record a tape by hooking the headphone jack of my stereo to the microphone jack on my laptop. I used Audacity to try to record the tape, and it would have worked if it wasn’t for a bug with Ubuntu/PulseAudio. My laptop would only record from the built-in microphone. It acted as if the external mic jack wasn’t even there. I tried to adjust settings in the audio settings and the alsa mixer. Nothing seemed to fix it.

So, I decided to try to update Pulse. This is risky, but hey, it wouldn’t work anyway. Why not make things worse!

First, I checked my current version.

skp@pecan:~$ pulseaudio --version
pulseaudio 0.9.22-24-g67d18

Then, I tried to install the “PulseAudio daily builds” PPA. Here’s the command:

skp@pecan:~$ sudo add-repository ppa:ubuntu-audio-dev/pulse-testing
[sudo] password for skp:
sudo: add-repository: command not found
skp@pecan:~$ sudo add-apt-repository ppa:ubuntu-audio-dev/pulse-testing
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /etc/apt/secring.gpg --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keyserver.ubuntu.com:80/ --recv 4E9F485BF943EF0EABA10B5BD225991A72B194E5
gpg: requesting key 72B194E5 from hkp server keyserver.ubuntu.com
gpg: key 72B194E5: public key "Launchpad Ubuntu Audio Dev team PPA" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)

Next, I opened update manager:

skp@pecan:~$ sudo update-manager
[sudo] password for skp:

Now, I realized too late, that I hadn’t done an update yet, but I found I had a few pending updates that I didn’t know about. So, I installed those first before worrying about the pulse updates.

Then, I clicked the “Check” button and I saw all of the pulseaudio updates. So, I installed once again.

Now, the pulseaudio version is very weird!

skp@pecan:~$ pulseaudio --version
pulseaudio 0.98-201107121852

Update: I just tried my mic out in Fedora 15. Audacity records correctly from the external mic when it is plugged in and the built-in mic when the external is not. Many other things in Fedora don’t work, but sound works well!

Gizmod for Volume on Mythbuntu

Our remote control has been working fine with my Mythbuntu setup for a while now, but there are a few things I would like to work better. Volume is one of those thing. Lirc controls the volume differently between Hulu Desktop and the built-in video player. It is a little annoying.

So, after a little Googling, this thread sparked my interest in Gizmod.

Installing…

To install it on my system, I followed the Ubuntu directions. That calls for installing via the repositories:

sudo apt-get install gizmod

Next, I had to address the UDev / Security. First, that means creating an “input” group:

sudo groupadd -f input
sudo gpasswd -a username input

Then, I added the following lines to /etc/udev/rules.d/99-input.rules:

KERNEL=="event*",       NAME="input/%k", MODE:="660", GROUP="input"
KERNEL=="js*",          NAME="input/%k", MODE:="664", GROUP="input"

Then, to make the changes take effect, I ran:

sudo service udev restart

Here’s the problem. When I tried to start gizmod, I got this error:

GizmoDaemon v3.4 -=- (c) 2007, Tim Burrell <tim.burrell@gmail.com>=---------=
Unable to Initialize Gizmod :: User Script dir [/usr/etc/gizmod/modules.d] does NOT exist or permissions are wrong!
GizmoDaemon Shut Down.

Recompiling

I found a bug report that seemed to suggest that maybe recompiling from the source might fix the problem. So, here is what I did.

So, I downloaded the latest version from the Download Page. Then, here’s the command to unzip:

tar -xjvf gizmod-3.5.tar.bz2

cd gizmod-3.5/

Installing dependencies

The easiest way to make sure that you have all the dependencies is with apt-get. Otherwise, you need to check the documentation and manually go through the list installing all the programs.

sudo apt-get build-dep gizmod

Then, continuing on, I followed the instructions and ran CMake.

mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DSYSCONF_INSTALL_DIR=/etc ../../gizmod-3.5

make

The make command failed with this error:

skp@gabriel:~/Downloads/gizmod-3.5/build$ make
[ 29%] Built target H
[ 31%] Building CXX object libGizmod/CMakeFiles/Gizmod.dir/CPUUsage.o
/home/skp/Downloads/gizmod-3.5/libGizmod/CPUUsage.cpp: In constructor ‘Gizmod::CPUUsageInfo::CPUUsageInfo()’:
/home/skp/Downloads/gizmod-3.5/libGizmod/CPUUsage.cpp:83: error: ‘memset’ was not declared in this scope
make[2]: *** [libGizmod/CMakeFiles/Gizmod.dir/CPUUsage.o] Error 1
make[1]: *** [libGizmod/CMakeFiles/Gizmod.dir/all] Error 2
make: *** [all] Error 2

I found a fix online. The fix was to add #Include <cstring>:

Then, it worked. Everything compiled with no problem.

Lastly, I finished the compile/install with:

sudo make install

Now, I haven’t used it very much. I think I need to do some configuring and hacking to get it to do what I want it to. Currently, it doesn’t seem to do well with Hulu Desktop.

Fixing Issues with Android ADT Plugin

I have been having trouble using my Android Development Tools ever since I upgraded my Eclipse.  Here is what I went through:

Some possibilities:

First, I tried to uninstall the plugin, and that was quite challenging.  I finally found this article that explains how to do it.

  • Go to the Help > About Eclipse dialog
  • Click the “Installation Details” button
  • Click on the plugin in the list on the first tab.  (You have to do each Android plugin individually)
  • Click the Uninstall button at the bottom of the screen
  • Click finish in the next dialog
  • Once uninstalled, I clicked “Not Now” to repeat the process without rebooting.  After uninstalling all the Android plugins, I clicked the “Restart Now” button.

Next, I opened the Error Log view with Window > Show View > Error Log.  I clicked on the Clear Log Viewer so that I could see only the new messages.  Then, I installed just the first Android plugin from the Update Site.

When the plugin install opened the restart dialog, I still didn’t see any messages in my Error Log view.  So, I just clicked “Restart Now”.  Even after the restart, I didn’t see any messages relating to the install.  Doesn’t make sense!

So, let’s try the permission thing.  I am copying the security over to make the eclipse directory accessible to everyone:

sudo chmod g=u -R /usr/lib/eclipse
sudo chmod o=u -R /usr/lib/eclipse

Note, I found the chmod command option to copy the permissions from a PDF that Google turned up.

After that, it worked!  So, I guess it really was a security issue.  I can see the DDMS option in the Preferences and the DDMS Perspective can be opened from the Window menu.

Help! Maintenance Mode in WordPress

I got a little scare last night when I was updating one of my plugins in WordPress.  I got a little click-happy, and I think I didn’t let the page finish loading when I told it to install the update.

Anyway, I went to the front page, and I got a message like this: “Briefly unavailable for scheduled maintenance. Check back in a minute.”  Thankfully, I found the solution here:

WordPress Forums: [resolved] Blog now stuck in maintenance mode

The solution is to delete a .maintenance file in the root directory of my WordPress installation.  I use nautilus for my FTP connection to the website.  Because the file begins with “.”, it is hidden by default.  You can hit Ctrl + H to show the hidden files, and then I could delete the file.

What’s Using My CPU and RAM?

My computer has been running slowly periodically, and so, that leads me to ask the question: what is the problem?  Here’s my tool of choice:

Gnome-System-Monitor

You can launch it either from the terminal or with Alt+F2 and typing “gnome-system-monitor”.  You can sort the processes by clicking on the column title.  I find it helpful to sort by the CPU and the Memory.

Resources

Bug: cdda2wav required by Brasero

I tried to copy a music CD this evening and got this error message:

Please install the following manually and try again:
cdda2wav (application)
cdda2wav (application)

I installed cdrao first, and it still gave me the same message.  Then, I installed icedax.  I restarted Brasero, and it worked fine.

Resources

Resources for Grub/Lilo

I have been trying to solve a problem with Ubuntu booting on one of my machines.  So, I have found these links helpful:

These instructions were very handy for mounting an already installed system from a LiveCD:

sudo mount /dev/sda5 /mnt
sudo mount /dev/sda1 /mnt/boot
sudo mount -o bind /dev /mnt/dev
sudo mount -t proc none /mnt/proc

Then, to be able to get Internet from the system, I had to copy my resolv.conf into it:

sudo cp /etc/resolve.conf /mnt/etc

Then, to work on the system, I ran:

sudo chroot /mnt /bin/bash

And, then, I can run commands like:

sudo apt-get update
sudo apt-get install lilo

Here are some more Lilo links:

I still haven’t solved my problem with all of these links, so here is my forum post if you know of anything that I am missing:

http://ubuntuforums.org/showthread.php?p=9885240#post9885240

dualscreen-mouse-utils

I ran across this tool a while ago, but I hadn’t had the opportunity to try it out.  It is called dualscreen-mouse-utils, and the thing that I want to use it for is to create a way to switch between my monitors with a remote control button. Here are some links to start with:

So, my first attempt was to download the compressed file, extract it, and try to compile.  I got a slew of errors, the first of which, was:

mouse-wrapscreen.c:63:22: error: X11/Xlib.h: No such file or directory

I did a little research and found this post:

It said to install this package:

sudo apt-get install xlibs-dev

But, the package didn’t exist.  I received this error:

E: Package xlibs-dev has no installation candidate

A quick search revealed this package that did install successfully:

sudo apt-get install libx11-dev

Then, it compiled cleanly with the “make” command.

I just tested it and it worked!  Next step is to setup a script to make it do a couple more things and add that to my lirc configuration.  I’ll save that for another post!

Shutter Bug: Can’t edit

I just upgraded to Lucid (Ubuntu 10.04), and I reinstalled Shutter.  I had found it not too long ago, and it does a great job with screenshots.  One of my favorite features is the way you can edit the screenshots and draw circles to point out things in the shot.  It’s great for documentation.

Problem is, in Ubuntu 10.04, the Edit button is disabled.  I found this bug post: Editing disabled in Ubuntu Lucid.

Solution: install the package: libgoo-canvas-perl

It was that easy, and now it is working like a charm!