Tuesday, November 30, 2010

Building a deb from installed files

I needed to create a deb of a currently installed package. I didn't have the original deb anymore but needed it so that I could use it for rolling back an upgrade in case of problems.

a google search for "create deb from installed" immediately pointed me at dpkg-repack


sudo apt-get dpkg-repack
sudo dpkg-repack


creates the deb file in the current directory. I don't know how complete that is, but it's certainly better than the nothing I had before.

Monday, November 22, 2010

Finally suspend

My Toshiba A75 laptop previously had a problem with suspend and switch-user. Before I clean-installed Maverick, the problem was likely due to confusion in configuration due to dist-upgrades.

The system was a lot cleaner and more stable after the Maverick fresh install, but there was one last niggling bug. Most of the time switch-user would work, and often suspend and restore would work, but when they'd fail they'd show "atiixp: codec reset timeout" and other dmesg errors. When switch-user or restore from suspend wouldn't work, they'd show that or another atiixp error and the laptop would then hang. I'd have to turn it off and on (I didn't try the magic sysreq keys since I'd never used them and just plain didn't know how to use them :-).

I finally got around to trying noacpi (edit /etc/defaults/grub and set GRUB_CMDLINE_LINUX=" noacpi ") and from testing tonight it looks like it's very stable. I've restored from suspend several times and switched users a lot more time.

Previously I thought it was failing because I was doing something with video or audio, so I viewed a video, switched to another user and suspended while that other user. Restore worked fine.

Over a week or two of use we'll know if noacpi is a good fix or if it working now is just a fluke :-).

Monday, November 08, 2010

Installing XPI from downloaded file

I was at a client site the other week and I was stumped. They have a locked down corporate environment and I couldn't get a newly installed firefox to download the Selenium IDE from the download site.

It was possible to get the files on another machine (that had network access), but not from firefox itself.

The weekend passed and on Monday I realized how simple the solution was. Just copy the xpi files on the other machine. Copy them to a USB drive or over the network to the locked down machine, and then load them via the file:// URL.

Tested on Linux and got that working. Didn't get to test on the actual Windows target since, in the meantime, the sysadmins gave us enough information to allow firefox to browse outward. But file:// is an easy way to install xpi files, if the browser can't get out to the world to download them directly.

Saturday, November 06, 2010

Why You should be using virtualisation

Why You should be using virtualisation resonates with me since, even though I run Ubuntu (a debian based linux) and the staging and production servers are Debian, there are still compatibility issues (if only that debian packages move slowly so the Ubuntu packages are much newer than on the deployment servers).

Fortunately, since I only work on Linux servers, I can run vservers, even different versions of Debian [but using the same vserver kernel as the host]. That's a lot less memory intensive than running full virtualization environments (my preference is VirtualBox, but that's just because I haven't gotten around to testing Xen. I may test LXC on my home computers, but I'll stick with Vservers on my work dev machine since I already have a procedure for building the classes of vservers that we use at work.