I took the plunge and upgraded my Ubuntu install from Gutsy Gibbon to Hardy Heron and now apt-get doesn’t work.  Everything that depends on it or anything like it doesn’t seem to work.  dpkg still does.  So, if I update and upgrade (or dist-upgrade), it’ll fetch the packages, just as the update-manager does, but it will crap out with a segmentation fault when its time to install the packages.  I’ve joined Lymatas thread at the Ubuntu forums.  This will be the first time that I’ve ever asked for help, as the solution has always been a search query away.  The solution presented (which is the one that helps most people) does not work for me.  If anyone has overcome this problem, let me know how you solved it.  I’m about to ask a question on LQ for the first time.

I’ve decided that Lymatas has a different problem and have created my own thread - the first ever linux question I’ve posted to a forum (will also request help at LQ - this is getting to be ridiculous).  Check out my request right HERE and see if you can help me kill apt and ressurect it from its death! (or something like that).

I thought that I’d follow up on my complaint about the non-working PenguinTV on Ubuntu Gutsy Gibbon. From a forum post, I found a workaround:

In a terminal, type export LD_LIBRARY_PATH=/usr/lib/firefox and then export MOZILLA_FIVE_HOME=/usr/lib/firefox and then execute PenguinTV: PenguinTV &, which allows the program to find what its looking for.

That’s a bit arduous, so why not automate it? I did so, and it is really a hack, but I thought that I’d share it with you. Anyone who has created bash scripts before (or batch files in Windows/DOS) will find this to be quite trivial, but there are many out there who still haven’t “gotten their feet wet”.

So, the first thing that you’ll want to do is open your favorite editor. For quick and dirty scripts like this one, I use nano, as many systems have it included and the learning curve is quite small. So, for nano, you would open a terminal and type nano -w Pengi. I use Pengi as the name for my script. you can use whatever you want. The -w flag for nano causes it to continue beyond the border of your terminal when writing a line, keeping you from truncating a long command. Its not really necessary for this script because the commands are quite short, but its a good habit.

Here’s what you put in your editor:

#!/bin/bash

export LD_LIBRARY_PATH=/usr/lib/firefox

export MOZILLA_FIVE_HOME=/usr/lib/firefox

PenguinTV

Save the file.  Ensure that you’ve typed each command on a new line.  Then change it to executable with a quick chmod: chmod a+rwx Pengi

You can now open PenguinTV on the command prompt by typing /home/your-username/Pengi
That’s not the end of it, though, right?  You want your nice little icon to execute the file when you click it, I am sure.  Whether I use Gnome, KDE, or XFCE, I’ve become accustomed to putting a quick launch for my favorite applications on the taskbar for easy access.  This is the case for PenguinTV as well.

Its quite easy, in these desktop environments, to change the attributes of an application launcher.  Its even a tad easier than when using Microsoft Windows, as you don’t have to remember to put quotes around the application path.  So, you would right-click the PenguinTV icon and select “properties” from the menu.  In the “path to executable”, you would replace “PenguinTV” with “/home/your-username/Pengi" (without the quotes, of course) and click OK.  You should be in business and PenguinTV should open with the right environment variables to launch successfully.

I found a nice entry today that you might like if you want to speed up your Ubuntu. Its pretty much common sense, but its a nice collation of tips. Here’s the article: A Quick Way to Improve Ubuntu Linux Operating Speed Performance.

Have you had a problem with an application that you got from outside the approved Ubuntu mirrors? Did it refuse to run? Did you know that you can execute a program from a command prompt by typing its name and hitting ENTER? Did you know that most programs will give you extra info via the -v (verbose) switch?

I have recently had that problem with a rss aggregator named PenguinTV. Its nice and simple and will grab just about any audio or video feed, like Miro, without the heavy system requirements (it uses the default apps to play the media, for example, instead of handling that itself). Its ideal for podcast fetching. The problem is that the version that is available in the software showcase does not work without telling the program some things that it should figure out itself. I tried the solution on the forum post about the same problem that I’d encountered of trying to get the latest .deb from the project’s home page. However, I was getting a “bad syntax” error.

This is because Ubuntu has switched from bash as its default shell to dash (lighter and faster, closer to the original ash shell). On nearly every distribution of GNU/Linux, /bin/sh is a symbolic link to /bin/bash, so nearly all executable scripts in /usr/bin will begin with the shebang #!/bin/sh. With /usr/bin/PenguinTV, open it up with a text editor as root and change the shebang to #!/bin/bash and it will run, as the developer is using bash!

…now if I can only find out why it sometimes core dumps…(I just found gPodder, which might be the ultimate solution)

If you remember, I  mentioned a hard drive replacement a while ago.  I haven’t tried to revive it yet with a tool like Spinright yet, but I may still be able to get something out of it.  That was a hard drive failure.  It doesn’t boot or recognize at all at the moment.

I thought that I was going through that with another one as well.  The hard drive in Frankenputer seemed to have gone on me after another update of Hardy Heron.  I had split the drive up into three partitions, one as the root partition “/”, swap, and a third one as “/home”.  The root partition was formatted as EXT3 and the /home was partitioned as ReiserFS.  After yet another update (development software after all), I rebooted into a corrupted first partition and E2FSCK didn’t help, dropping me to a single user recovery shell.  I ran FSCK manually and was able to get the partition reorganized.  I carried on but this was not the end of my troubles.

One more update killed it for good, I thought.  My drive was not even recognized on boot.  Its the second hard drive and I actually have GRUB, my bootloader on the first drive.  I’ve been letting whichever operating system that does the latest update handle GRUB, which meant that the config file with the instructions for GRUB “/boot/grub/menu.list”, was on the second drive on the corrupted partition.  no problem, I just popped in a Linux install CD (Ubuntu of some version, I recall), and chose the option to boot from the first hard drive to get into Arch Linux o that I could do some online digging about this problem.

Somehow, the corruption of the first partition seemed to have affected the boot sector of the second drive as well, which was causing the problem with the BIOS picking up the drive.  I was able to “see” and mount the “/home” partition, so I figured that the drive just couldn’t be dead, as I had thought.  I immediately attempted to back up as much data as I could access onto DVD, which was quite successful, albeit a tad slow, as the OS and the DVD burner were on the same IDE cable.  On a lark, I reformatted the first partition with ReiserFS, which in my opinion, has a far superior recovery on unexpected shutdown.  Suddenly, the whole drive was once again visible to the BIOS.

I reinstalled Gutsy Gibbon and used my existing “/home” and restored my user and each of the kids.  The only difference was that a few programs were missing, which  can be recovered, and some theme-related files which were in “/usr/share” were not available.

So, the take away from this story is that your hard drive may not actually be bad.  It might just be that your hardware is not perfectly suited to go together and a file system corruption may be the cause of your troubles.

As anybody who’s bored enough to read even my blog knows, I am no stranger to software testing.  I’m no programming genius (that would be Lloyd, Westi, Matt, Linus, Devin, and others) at all, but I know how to find a bugzilla or bug reporting tool, and I do my best.  I’ve not alpha or beta tested Wordpress since 2.3 was released, as I’ve been concentrating more on Ubuntu lately (and there are some really nice touches that Hardy Heron is going to present to the world, very nice).

I’ve remained subscribed to the WP-testers mailing list, though, and I’ve been reading every post.  It looks like Wordpress is going to be a lot more friendly to the new user and have a lot more power for the power user.  I’m not sure if this blog will go through any more trauma or not.  I may keep with a stable (older) version until support is stopped.  But, I may move another over to 2.5 and see how easy it is to do the hard things.  BTW, there’s a lot of good discussion about it on the latest Wordpress Podcast

Will you be switching right away?

So, a few weeks ago, Ubuntu “upgraded” Firefox 2.0.0.12 (which is a decent release) to Firefox 3 Beta and I couldn’t view any java applets any more.  The reason is because some of the file paths are changing and the plugins need to be linked to a different spot.  I had to try Opera but it crashed.  That left me with Konqueror, which is not native to Gnome, for the time being.

That has just changed.  I just found Bug #173966 and there was a hack proposed that helped me to get back on track.  The solution, for now:

cd  /usr/lib/xulrunner-addons/plugins/

ln -s /usr/lib/firefox/plugins/libjavaplugin.so .   <–note the “dot”

Your plugin path might be different, but that’s where one place mine can be found (actually, its a symbolic link to the plugin, which is in  /etc/alternatives/firefox-javaplugin.so)

TopOfBlogs