Tag search
Moving LVM volumes to a different volume group
by Sander MarechalI recently ordered a brand new PowerEdge T105 server from Dell because my current home server, a HP ProLiant G3, is much too power hungry for my liking. It consumes about 300 Watt round the clock, increasing my power bill by nearly € 50 a month. The T105 consumer about a third of that, usually less. The new server came with an 80 GB hard disk. I partitioned it with LVM, installed Debian Lenny and moved over the bulk of my things from the old server to the new server. I did that manually over the course of two weeks because it was a good time to restructure and upgrade many other things in the process.
When I was done only one thing remained: my media collection, which is stored on a 500 GB RAID1 array on the old server. That RAID1 array is also partitioned using LVM in a single 500 GB volume group. I took the two drives out of the old server, put them in the new server, copied over /etc/mdadm/mdadm.conf from the old server and all was well. Nearly. My media collection only uses a small part of the 500 GB volume group, so I wanted to move the OS volumes from the 80 GB volume group to the 500 GB volume group. That way I could take out the 80 GB disk and save some power. Problem: There is no obvious way to move a logical volume from one volume group to another. Additional problem: I can’t run the OS from the 80 GB volume group when I am migrating them. Cue SytemRescueCD.
Package Management Sudoku
Russell Coker recently wrote a post entitled “Ownership of the Local SE Linux Policy”. This post has nothing to do with the substance of his post, which is a discussion of how distributions should configure SELinux by default. I know nothing about SELinux, but something that Russell said in passing caught my attention:
I am not aware of the Debian package dependencies (or those of any other distribution) being about to represent that the postfix package depends on selinux-policy-default-postfix if and only if the selinux-policy-default package is installed. Please note that I am not suggesting that we add support for such things, a package management system that can solve Sudoku based on package dependency rules is not something that I think would be useful or worth having.
As it happens, a little-known fact about the Debian packaging system is that you can, in fact, describe Sudoku puzzles in it!
From: Daniel Burrows’ Blog.
Howto: build and install the intl PECL extension for PHP5 in Debian
by Sander MarechalFor the past few days I have been looking for a proper i18n (internationalisation) and l10n (localisation) method for PHP. PHP has quite a few locale aware functions such as strftime and sprintf. In combination with gettext this can work quite well. The major downside is that you need to install all the locales that you want to support on your server. Want to serve your websites in Russian? Then you need to generate a Russian locale system-wide. That won’t work when you’re on a shared hosting account somewhere.
PHP6 is promising to solve that problem with the intl functions. Even better, the intl functions are also available as a PECL extension and works on PHP 5.2.4 and newer. Debian Etch currently packages PHP 5.2.0 which is too old, but Lenny—Debian’s upcoming version—is up to PHP 5.2.6. There is no package (yet) for php5-intl in Debian Lenny but building and installing the extension yourself is really easy. Here’s a short tutorial.
Automatically mounting and unmounting Samba/Windows shares with CIFS
by Sander MarechalLast updated on 2007-12-03@23:55. At my work the employees are in the fortunate position that they are free to choose whatever OS they want to work with. At the moment the default is still Windows XP but you are free to wipe the drive and install whatever you feel—as long as you can do your job properly. And there is work underway to roll our own distribution for internal use. You're even free to bring in your Mac (but we won't supply you with one). The only thing that's banned (unofficially) so far is Windows Vista. Server-side we run a mixture of Linux and Windows, and the thend is to replace broken Windows machines by Linux machines if possible. In such a heterogeneous environment it makes sense to share our files through Samba. It's one of the few protocols that any OS can speak.
If you're running Windows Server 2003 then you can't use the smbfs driver that most Linux distributions ship by default. Sorry, no "Places » Connect to server" for you GNOME folk. You'll need to use the CIFS filesystem driver and you'll need to edit /etc/fstab. Adding the required fstab entries is actually quite easy as I will show below, but on Debian and it's derivative distributions you get a nasty error when you subsequently try to reboot or shutdown your machine, which hangs for about 30 seconds waiting for a timeout:
CIFS VFS: No Response for Cmd <number> mid <number>
It took me quite a bit of time to properly solve that one, but in the end it turned out to be quite simple. I will show you later in the article, but let's start mounting first.
Using Lightning 0.5 with Debian's IceDove
This is just a quick heads-up for those who want to use Mozilla's Lighting calendar plugin in combination with Debian's IceDove Thunderbird spin-off. You need to install libstdc++5 for it to work. If you don't, you get the Lightning user interface showing in IceDove but you cannot create new calendars.
Configuring Debian/etch on a Dell Latitude D520
by Sander MarechalA new job brings new toys :-) My new employer has supplied me with a Dell Latitude D520 laptop for programming. It came loaded with Windows XP professional which—ofcourse—had to go. Nothing inhibits productivity quite like Windows—except perhaps for the pool table and game consoles in the lunch room. Basic installation of Debian/etch went without a hitch as expected. I used the official 4.0 netinstall ISO using a cable instead of relying on wireless. After the reboot I did find a few small problems though. I'll describe them here, and what I did to fix it, so I can hopefully save other people the headaches.
Debian/etch Xen: Nice, but not quite ready for me
by Sander MarechalIn my previous post I explained how I set up my new server as a Xen server in order to maximize my flexibility. It's been little over a week now and I am saddened to say that Xen has gone out the Window. While I love the flexibility, it's just not ready for me yet.
A test drive of Debian/etch Xen
by Sander MarechalDaddy's got a brand new toy to play with :-) A few months ago swbrown posted a fantastic tutorial on the LXer forums that gave a short overview of setting up RAID with LVM, Xen and LUKS. Around that same time I noticed a decommissioned HP server at my job. I decided to buy it off my boss and see if I could get to swbrown's nice setup. Here is an overview of the machine:
HP ProLiant ML370 G3
Dual Xeon 3.2 Ghz CPU
1024 Mb RAM
4 x 36.4 Gb + 2 x 18.2 Gb hardware RAID array
Here's how I fared in making this new toy into a flexible Xen server.
Gnome Hearts 0.1.3 Release Announcement
by Sander MarechalWe are happy to announce the immediate release of gnome-hearts version 0.1.3. This release fixes some crashing behavior related to card styles on Debian and Debian-based systems [1][2][3][4] and fixes a similar potential crash regarding background images on any system. It also adds Polish documentation and updates all other in-game translations. You can download the latest version from our downloads page [5] or our APT repository [6].
[1]http://bugzilla.jejik.com/show_bug.cgi?id=11
[2]http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=395551
[3]http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=396043
[4]https://launchpad.net/distros/ubuntu/+source/gnome-hearts/+bug/65274
[5]http://www.gnome-hearts.org/download/
[6]http://www.jejik.com/pages/repositories/
About Gnome Hearts
Gnome Hearts is an implementation of the classic hearts card game for the GNOME desktop, featuring configurable rule sets and editable computer opponents to satisfy widely diverging playing styles. Gnome Hearts is Free Software, released under the GNU General Public License and should be able to run on any computer that can run the GNOME desktop.
Enjoy,
Setting up and managing an APT repository with reprepro
by Sander MarechalIf you are writing software for Debian GNU/Linux or deratives like Ubuntu then setting up an APT repository is a very useful thing to do. Setting up an APT repository for your users makes it very easy for them to keep up-to-date with the latest version of your software, far easier than providing .deb's as downloads on your website.
This tutorial will show you how to do just that with reprepro. Reprepro makes it very easy to set up APT repositories that use a common /pool directory to store all the package files. In this regard, reprepro is superior to APT tools such as apt-ftparchive. I am going to assume that you are already familliar with the basic workings of an APT repository.
Gnome-hearts 0.1.2. binaries available
by Sander MarechalI have created binaries for gnome-hearts-0.1.2 for Ubuntu Dapper Drake i386 and amd64 architectures. You can download the from our download page and from our APT repositories.
Binaries for Debian unstable/testing and Ubuntu Edgy Eft should be available as soon as they have been accepted in their main repositories.
