/usr/portage

Recovering a software RAID 0

The scenario: my RAID crashed because I’ve messed around with the partition table of one of the disks in there. This results in a RAID array not being able to assemble itself because the superblock of the messed up device is invalid. The trick is pretty easy: just recreate the whole RAID with mdadm. The existing metadata will not be overwritten, the current information is just replicated. I used to have a simple RAID1, but I’ve now recreated it as an incomplete RAID5 (--level=5, --raid-devices=2) as the missing disk is soon to be bought.

$ mdadm --create /dev/md0 --level=5 --raid-devices=2 /dev/<original> /dev/<crashed>

If you like to stick with a RAID1, and not doing the migration to RAID5 along the way, just use --level=1 instead. I’m not really sure if the order of the disks matter and I’m not brave enough to find it out.

Tomorrow I’m going to buy the next disk for the RAID to make sure the redundancy level is alright. Generally I’m pretty amazed that this kind of setup is so robust. Even me messing around with it can’t bring it down.

Filed on 13-09-2008, 03:03 under , , , & no comments & no trackbacks

Testing PHP 5.3 alpha1 3

Finally Johannes Schlüter baked a first alpha-tarball for PHP 5.3. The new version contains a huge amount of new features, like closures, namespaces and late static binding. Such a huge amount requires thorough testing: if you are using a PHP application you would like to see fully working with our brand new version or you are developing a PHP application, this is your chance to make sure everything will go smoothly. If you are a web hosting provider, do your performance benchmarks now!
If you are, accidentally, using the Gentoo Linux distribution, I have something for you: in my personal PHP overlay you can find an ebuild for PHP 5.3.0_alpha1. A few warnings: currently, ext/fileinfo does not compile because of #45636 and of course I did not test all possible USE-flag combinations. If you experience problems with it, just leave a comment here.

Filed on 03-08-2008, 19:07 under , , & three comments & no trackbacks

Specific env vars for Gentoo packages 0

Since Gentoo Portage introduced the package specific configuration in /etc/portage there was one thing I always missed: specifying environment variables per package. Some environment variables you might want to specify per package are CFLAGS, CXXFLAGS and FEATURES. Especially when you do debugging, some packages should not be stripped, which is the perfect use case for the FEATURES environment variable. While specifying USE-flags and keywords per package, the rest is not that easy. Christian Hoffmann dropped me a link to this mail: the tip there works fine. I’ve played around with it and implemented it slightly differently: first, I would like to be informed which environment files are read and second I changed the resolution order so that the specific configuration inherits from the more generic. So this is what my /etc/portage/bashrc looks like now:
[geshi lang=bash] for conf in ${PN} ${PN}-${PV} ${PN}-${PV}-${PR}; do env=/etc/portage/env/${CATEGORY}/${conf}.env if [[ -f ${env} ]]; then einfo "Reading specific environment from ${env}" . ${env} fi done [/geshi]
For dev-lang/php-5.2.6-r3 I can use three different files to customize the build environment: /etc/portage/env/dev-lang/php.env would apply for all PHP ebuilds, /etc/portage/env/dev-lang/php-5.2.6.env for all revision of the ebuild for 5.2.6 and /etc/portage/env/dev-lang/php-5.2.6-r2.env for the exact ebuild. My /etc/portage/env/dev-lang/php.env file now looks like this to disable stripping the binaries after emerging them and keeping the working directory for better backtraces:
[geshi lang=bash] FEATURES="${FEATURES} nostrip keepwork" [/geshi]

Filed on 02-08-2008, 15:03 under , , , & no comments & no trackbacks

Jabber for portage 0.0.5(.1) 1

portage-mod_jabber is a small elog module for Gentoo’s portage which provides Jabber notification for portage. It basically allows to receive notifications via jabber when elog events occur.

The new version of portage-mod_jabber fixes a deprecation warning with portage 2.2 (but works with older versions too) and introduces a new syntax for the JABBERFROM-variable: both node:pw@host.com/resource and node@host.com/resource:pw are allowed now.

Grab it while it’s hot!

Note: I’ve released 0.0.5.1 to fix an invalid exception catch. Catched LoadError instead of ImportError. That’s what happens when you confuse Python with Ruby.

Filed on 05-07-2008, 11:11 under , , , & one comment & no trackbacks

Sound on a 3rd generation MacBook 2

Thanks to the heros on the Mactel list I have sound again. If you use Linux on a MacBook of the third generation and your soundcard has been detected but just no sound will come out, putting the following in /etc/modprobe.conf (on Gentoo: /etc/modprobe.d/alsa and modules-update afterwards) should fix the problem. Please reboot or reload snd-hda-intel after changing the configuration. NOTE: it has been reported to work fine on MacBook Pro’s too.

options snd-hda-intel index=0 model=mbp3

Filed on 10-06-2008, 08:08 under , , , , , , & two comments & no trackbacks

Jabber for portage 0.0.3 3

portage-mod_jabber is a small elog module for Gentoo’s portage which provides Jabber notification for portage. It basically allows to receive notifications via jabber when elog events occur. A few days ago #204125 was opened in the Gentoo bugtracker, which is obviously the wrong place to request features for software which is provided externally. But anyway, I took the idea of allowing the user to specify which Jabber resource to use and added the feature. Another facility in this context which might be helpful is to use hostname as a variable for the current hostname in the resource. So if you deploy a number of systems you can just specifiy “/systems/%hostname%” as the resource and the hostname will be replaced automatically. If you want to use this feature just edit /etc/make.conf and change PORTAGE_ELOG_JABBERFROM to something like user@host.com/resource:password. From now on, the version 0.0.3 is available here.

Hanno, would you mind bumping it?

Filed on 03-01-2008, 17:05 under , , , & three comments & no trackbacks

Mit den Augen eines Kindes 1

Das letzte mal, dass ich von Freier Software so richtig beeindruckt war, ist inzwischen über vier Jahre her. Der simple Grund damals war GNOME 2.0 auf Hannos Laptop, genauer gesagt der Login-Manager GDM mit diesem Theme. Ich hatte mich zur Gänze in den Look dieses Login-Managers verschossen, dass ich alles dafür gab, das Ding auch zu bekommen. Ich war damals SuSE-Nutzer, weil ich nichts anderes kannte und konnte. Leider gab es für SuSE keine Pakete und selbst bauen kam damals nun wirklich nicht in Frage. Jedenfalls nicht ohne passende Distribution. Nach einigem hin und her und dem Umweg über Debian verpasste mir Hanno ein Gentoo Linux. Nicht, dass ich damit hätte umgehen können, aber ich bekam immerhin GNOME 2.0. Seitdem ist einiges passiert. Ich sah Software kommen und gehen, habe ein paar Programmiersprachen gelernt, Elegantes und weniger Elegantes kennen gelernt, habe ziemlich viel Freie Software benutzt und benutze sie weiterhin jeden Tag. Aber dieser kindliche Blick auf einen schön gestalteten Login-Manager habe ich so nicht mehr erlebt. Bis gestern. Seit gestern verwende ich auch (wie Bernd und Jens) AIGLX.

Filed on 03-12-2006, 19:07 under , , , & one comment & no trackbacks

Zeroconf magic with Gentoo 1

With GNOME 2.14 Avahi, the implementation of the Zeroconf-specification from Freedesktop, is shipped with. It brings the convenient feature to autodetect services. As you can see on the screenshot, it detects a lot of services and provides the possibility to use them on »one-click«. This Zeroconf-technology is looking back to a confusing history: there are two implementations before avahi: howl and mDNS, which both have licensing issues. So the Freedesktop-project brings us a good step forward and it works as easy as you can’t imagine. Licensing issues prevents Ubuntu from integrating howl or mDNS, but let us hope, they will integrate it now.


Gentoo-magic:


Build required packages:
Set the USE-flags »avahi«, »bookmarks«, »dbus« and »python« and emerge net-dns/avahi. Now emerge x11-misc/service-discovery-applet. After all, rebuild affected packages to reflect the USE-flag change (emerge -DuN world) and to guarantee full support for avahi.


Start required services on boot
Add avahi:

# rc-update add avahi-daemon default
	
  1. rc-update add avahi-dnsconfd default


Start required services

# /etc/init.d/avahi-daemon start
# /etc/init.d/avahi-dnsconfd start

To be complete, just add the new panel-applet to your panel and employ the new possibilities.

Filed on 08-06-2006, 02:02 under , , , , , & one comment & no trackbacks

Portage-notification for Gentoo via Jabber 3

Getting notified via mail about recent warnings, information messages and error on your Gentoo system is good thing but getting notified via Jabber could be also helpful in some cases. The new notification framework of portage in the current 2.1-serie previews makes it easy and possible to implement somthing like this. To show how easy it is, I did it. You can see the result in the Gentoo Bugzilla. I am utilizing XMPPPY, a friendly Python-library to do so.

How to use?
1.) Install an ebuild of the 2.1-serie of sys-apps/portage
2.) Install dev-python/xmpppy
3.) Copy this file to /usr/lib/portage/pym/elog_modules/mod_jabber.py
4.) Edit /etc/make.conf and set the following options:
PORTAGE_ELOG_SYSTEM="jabber" PORTAGE_ELOG_JABBERFROM="sender@host.com:password" PORTAGE_ELOG_JABBERTO="jid1@host.com jid2@host.com admin@foo.com"

Update:
As of a request by solar and Jacub Moc I did a proper release which is availiable there and wrote an ebuild. All you have to do now is to install the ebuild and edit you configuration.

Filed on 21-05-2006, 15:03 under , , , , , , , & three comments & no trackbacks

Ejabberd 1.1.1 in BreakMyGentoo 0

I’m proud to provide a new Ejabberd-ebuild to our users. Ejabberd 1.1.1 comes with an important new feature: it supports MySQL natively. I fixed up PostgreSQL-issues in the ebuild and provide now the native drivers for MySQL and PostgreSQL Also I’m happy to mention that NU2M, the company which is involved in Mabber and for which I’m currently working for, is going to release some really interesting Jabber-components, especially for Ejabberd, during the next weeks.

Links

Filed on 07-05-2006, 02:02 under , , , , , , , , & no comments & no trackbacks

Just broken 10

Some months ago I ranted about Gentoo’s Ejabberd-ebuilds and I want to comment another issue: Ejabberd provides support for PostgreSQL via its ODBC-drivers. That’s reflected in the ebuild, there is a postgres USE-flag. That’s generally fine, but helps nothing, ’cause you need the native PostgreSQL-driver from the jungerl-distribution. But: there is no ebuild in portage. Whether you can’t find jungerl nor the native PostgreSQL-driver in portage, which makes the USE-flag buggy one the one hand and completely useless on the other hand. Is it common not to test functionality when adding a USE-flag?

Filed on 01-05-2006, 17:05 under , , , , , , , & ten comments & no trackbacks

Migration allenthalben erledigt 0

Was Hanno und Stefan schon zu berichten wussten, gibt es nun auch hier zu lesen: Schokokeks.org ist umgezogen.


Continue reading "Migration allenthalben erledigt"

Filed on 28-03-2006, 11:11 under , , , , , , , , & no comments & no trackbacks

jabber.breakmygentoo.net 0

I’d put jabber.breakmygentoo.net in the vhosts of our ejabberd, so feel free to register a Jabber-account, if you are a BreakMyGentoo-developer. Otherwise you’ll become virtually tared and feathered, you understand?
Also you can join us in breakmygentoo@conference.jabber.breakmygentoo.net.

Filed on 05-03-2006, 20:08 under , , , , , , & no comments & no trackbacks

New developer: Stelian Ionescu (fenlix) 0

New developer
I’m proud to welcome Stelian Ionescu to the BreakMyGentoo-team. He comes from Romania and is living and studying mathematics in Rome, Italy. He is skilled in C, C++, Shell, Ocaml, CommonLisp whereas CommonLisp is his favourite programming language. Yet another well-skilled developer is joining the BreakMyGentoo-team, so he will help us to push things forward. Let me say good Luck, dude!

Quality assurance, quality assurance, quality assurance
From the good to the bad: there are a lot of QA-issues in our current BreakMyGentoo-tree, we should fix this as soon as possible. Please use repoman for every ebuild you submit. You can ignore warnings about the copyright-header (another issue: please use our BreakMyGentoo-header), about missing arches, and so on). But please fix the other issues, for example include metadata.xml and so on. Thanks.

Splitting beagle
And, at last: beagle will be split into libbeagle and beagle-search to fix #190 properly. Stelian will be responsible to do this change.

Filed on 02-03-2006, 00:12 under , , , , , , & no comments & no trackbacks

About ejabberd, transports, lazy Gentoo-developers and the gloriousness of Schokokeks.org 7

We did it. I’m proud to announce the completed set of transports on Schokokeks.org, including MSN, ICQ, AIM, GaduGadu (just to have the longer cock than Mabber) and Yahoo!.


Continue reading "About ejabberd, transports, lazy Gentoo-developers and the gloriousness of Schokokeks.org"

Filed on 27-02-2006, 19:07 under , , , , , , , , , , , , , , , & seven comments & no trackbacks

Newer Entries ↘