Tags: ubuntu

RSS - Atom - Subscribe via email

Calibre and Qt 5.5

| geek, linux

A recent apt-get dist-upgrade resulted in the removal of calibre and calibre-bin from my system. I've been using Calibre to convert e-books from HTML and EPUB (some developer references, some fanfiction =) ) and copy them onto my Kindle.

It turned out that the Calibre packaged in Ubuntu required qtbase-abi-5-4-2 and my recent dist-upgrade installed Qt 5.5. I needed to upgrade to Calibre 2.49, which wasn't available on any of the PPAs I checked (despite instructions to the contrary).

Installing Calibre from the Calibre website made it work, though. In fact, the Calibre website says:

Please do not use your distribution provided calibre package, as those are often buggy/outdated. Instead use the Binary install described below.

I wasn't too keen on piping the output of a wget command to sudo , but a quick scan of the script didn't turn up anything suspicious. Anyway, now I can convert EPUBs to MOBIs and easily copy them onto my Kindle, yay!

Using supervisord for Nginx+FastCGI+PHP

Posted: - Modified: | geek, linux

I was having problems with spawn-fcgi-standalone occasionally resulting in dead PHP processes, which caused 502 Bad Gateway errors on my site. Crontabbing an /etc/init.d/init-fastcgi start didn't help much, so I looked for other ways to do it. Supervisord looked promising.

Here’s how to get Supervisord:

apt-get install python-setuptools
easy_install supervisor

 

Here’s what to add to /etc/supervisord.conf:

[fcgi-program:php5-cgi]
socket=tcp://127.0.0.1:9000
command=/usr/bin/php5-cgi
numprocs=5
priority=999
process_name=%(program_name)s_%(process_num)02d
user=www-data
autorestart=true
autostart=true
startsecs=1
startretries=3
stopsignal=QUIT
stopwaitsecs=10
redirect_stderr=true
stdout_logfile=/var/log/php5-cgi.log
stdout_logfile_maxbytes=10MB

So far, so good. When I kill the php process, supervisord starts it back up. Progress!

supervisord doesn’t come with an init.d script, but you can get one for Ubuntu.

Getting sound to work again

| laptop, linux

Things to remember when setting up sound in Ubuntu Linux on a Sony Vaio U1:

  • modprobe trident
  • modprobe snd_trident
  • Be very very thorough with alsamixer settings. For some brain-dead reason, all the important stuff is muted.

Moved to Vaio!

The power adapter on my Fujitsu Lifebook P1110 has just completely given up. Fortunately, my parents had given me the Sony Vaio U1 to use as a backup computer. After a day of upgrading it from Ubuntu Breezy Badger to Ubuntu Dapper Drake (that should teach me to deselect all of the GNOME packages before I dist-upgrade!) and another afternoon for getting my various CVS Emacs stuff compiled and put together, I'm now back on an approximately working system. I still need to get software suspend working, but everything else works beautifully.

The Sony Vaio U1 is actually a pretty sweet machine. It's *tiny* – 8.9″ screen and a keyboard that even I find just a bit small. No Dvorak on this one; the combination of a Japanese keyboard and chiclet keys makes it too difficult for me to remember the proper keyboard mappings through muscle memory. I type with four fingers: the middle finger and index finger of my left hand and the thumb and index finger of my right.

When Simon saw me setting up the Vaio, he insisted that I borrow a proper-sized keyboard. Heh. ;)

So I'm on Ubuntu now. It's certainly slicker than the Debian system I've just moved from, with a pretty bootup sequence and a lot of other things that Just Work. I'm no longer a poseur. The Ubuntu stickers on my skateboard actually mean something. ;) Sweet.

Now that that's sorted out, maybe I can work on my writing backlog. I owe so many people e-mail and I owe Don Marti an article…