Archive for the ‘Geek’ Category

How multiarch adds new RC bugs…

Sunday, June 3rd, 2012


# dpkg --add-architecture kfreebsd-amd64
# dpkg -i libc0.1-dev_2.13-32_kfreebsd-amd64.deb
Selecting previously unselected package libc0.1-dev.
(Reading database ... 446113 files and directories currently installed.)
Unpacking libc0.1-dev (from libc0.1-dev_2.13-32_kfreebsd-amd64.deb) ...
dpkg: error processing libc0.1-dev_2.13-32_kfreebsd-amd64.deb (--install):
trying to overwrite '/usr/include/_G_config.h', which is also in package libc6-dev 2.13-32
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
libc0.1-dev_2.13-32_kfreebsd-amd64.deb

Before multiarch the bug was not existing, and of course none of libc6-dev and libc0.1-dev are marked as Multi-Arch: something. People wanting to delay the release of Wheezy, I am sure you can find much more RC bugs like that.

Performances of open-source Radeon driver

Friday, January 6th, 2012

I am the happy owner of a new netbook with an AMD Fusion E-450 APU, which includes a Radeon graphics card. I am using the open-source driver on it, that is a 3.2-rc7 kernel for KMS, and xserver-xorg-video-radeon package from sid. I have to say I am not really happy about the performances.

No I don’t speak about the graphical performances that are pretty good (especially compared to my Intel Atom N450 based previous netbook) but about the power consumption. With this setup and with the original battery I get 2h30 of autonomy. Switching to UMS and adding some power management options in xorg.conf improves it to 2h40, but breaks suspend to ram/disk (a pity for a netbook) and switch between VT. I then tried the non-free fglrx driver, it also suffers from the suspend to ram/disk issue, in addition to crashing xorg when playing videos… On the other hand I get an impressive 3h30 of autonomy, and additionally a silent netbook (contrary to the open-source driver, the fan doesn’t spin at idle).

I have tried plenty of options, ranging from adding some power management options to xorg.conf, to passing dynclks=1 to the radeon module, including setting /sys/class/drm/card0/device/power_method to dynpm. Right now I have worked around the issue by buying a bigger battery which brings me 5h30 of autonomy, but I would really appreciate any software way to improve it with the open-source driver.

Debian s390x port (aka 31 bits is not enough)

Tuesday, August 9th, 2011

During Debconf 11, I got access to a fast s390 machine, and I have started to work on a Debian s390x port, the 64-bit version of the s390 port. One of my goal was to help the SPARC64 port, as some of the issues are the same: both are 64-bit big-endian, don’t support unaligned access and behave differently between -fpic and -fPIC.

Why such a port?

When talking about 64-bit ports, we usually hear: “4GB is enough, handling 64-bit takes more memory”. This really sounds like “640K ought to be enough for anybody”. The s390 port is actually 31-bit from the address point of view (one bit is reserved for address space extension from 24 to 31 bits), so each process is limited to 2GB only. Nowadays applications which need more than 2GB are not that uncommon, especially on mainframes. Actually the 2GB limit already causes some problem in Debian: in some cases it’s not possible to build haskell applications or even C applications using GCC. On the other hand, we already require a 64-bit kernel on the s390 port (only the userland is 32-bit), and applications are handling more and more 64-bit or greater values (files offset, time counters, uid, etc.).

What is the status?

Bootstrapping the architecture was not really easy (as for any other new architectures), due to a huge amount of dependencies and build-dependencies loops, as explained by Wookey during Debconf11. Now that this part is mostly done, an autobuilder has been started and currently more than 65% of the packages are built. The s390x port is hosted on debian-ports.org. Unfortunately it is not yet deboostrapable, though that should happen in the next few days (only a few packages are missing).

The main issues are currently packages which fail to build from source due to linker, gcc-4.6 and curl changes, or due to the libjpeg and multiarch transitions, and thus are not directly related to s390x. If your package is in this case, it would be a good idea to fix it. Otherwise if it has a lot of reverse dependencies and the bug is opened for a while, just expect an NMU (as allowed by the 0-day NMU policy). Of course for a few packages s390x specific fixes are needed, some of them are already in the BTS.

How you can help?

The list of bugs blocking the s390x port is available through the s390x usertag, fixing these bugs (a lot of them are general FTBFS) would help a lot. Alternatively if you have access to an s390x machine you can take a look at the packages failing to build.

Update: Fixed the explanation about the 32th bit, thanks to Bastian Blank for the comment.

Debian and the ARM hype

Monday, June 28th, 2010

Thanks to the versatility of the Linux kernel, Debian has always been known for supporting a large number of architectures. It has also often been criticized for that as it is said to slow down the development of Debian.

Among these architectures, the ARM one was considered dead a few years ago, and some people wanted to get rid of it. Today all major distributions now have an ARM port, one of those distributions being even based on Debian. It seems Debian was right.

Now that Android has been ported to MIPS, we may see more and more MIPS based devices. Will the same scenario happen again?

bindv6only=1 and GNU/kFreeBSD

Sunday, June 13th, 2010

A few months ago the netbase package started to install the /etc/sysctl.d/bindv6only.conf file to switch the default bindv6only value from 0 to 1.

A lot of people are not happy with this change, but it is not my goal to give my opinion here. On the other hand, people have propagated the rumour that it has been done as the FreeBSD kernel, used in the kfreebsd-amd64 and kfreebsd-i386 ports of Debian, only supports the mode corresponding to 1.

Let’s give the truth:

  • GNU/kFreeBSD people haven’t been contacted about this decision;
  • The FreeBSD kernel can support both modes through the net.inet6.ip6.v6only sysctl. However contrary to the Linux kernel it defaults to 1;
  • This option is available in the FreeBSD kernel since 2001, and in the Linux kernel since 2003.

EGLIBC and PowerPCSPE port

Tuesday, May 25th, 2010

This has been roughly one year since Debian switched from GLIBC to EGLIBC, so it’s probably the time to make a small report about this change.

First of all, on the GLIBC upstream side, things has improved a bit since we now have regular stable release, thanks to Petr Baudis aka Pasky. The good point is that the stable releases are imported into the EGLIBC stable repositories.

On the EGLIBC side the switch has helped to reduce the number of patches in the Debian package (for example, resolv.conf is automatically reloaded if needed), and has brought some bug fixes and improvements, especially for the arm, mips and powerpc targets.

It should be noted that the newly created PowerPCSPE port for PowerPC e500 series CPU also benefits from EGLIBC, as it is not natively supported by GLIBC.

Debian SH4 QEMU image available

Friday, April 9th, 2010

Thanks to the great work of Nobuhiro Iwamatsu and others, Debian has an unofficial SH4 port which is close to complete (> 90% of the packages built).

In order to help developers to fix bugs on this architecture, I have produced an SH4 QEMU image which is available at the same location as my other QEMU images.

You will need a recent GIT HEAD QEMU to use it. Previous versions suffer from bugs in the MMU, causing segfaults and gratuitous TLB flushing. The MMU emulation is now hopefully correct, but still a bit slow. Also the emulated board is limited to 64 MB of memory, and this value can’t be changed as memory extension would overlap the addresses used for peripherals.

Update: I have backported the necessary SH4 patches into the QEMU Debian package version 0.12.3+dfsg-4.

Squeeze will be released with eglibc 2.11

Sunday, March 7th, 2010

Contrary to what lucas announced (I don’t know where he got this info), we plan to release Squeeze with eglibc 2.11. It is already packaged in experimental and is ready on all architectures except hppa where there are a few major regressions in the testsuite to fix. This is what prevent us to upload it to unstable.

Working on the eglibc package

Thursday, January 28th, 2010

In the last weeks, I stopped being motivated to work on the eglibc package, it’s not fun as it was before. Maintaining this package is taking a lot of my (free) time, and I am not anymore able to follow the bug rate, especially for RC bugs or bugs that I consider high priority. In turn it does not give me time to integrate eglibc 2.11 or other wishlist features I would have liked to see (rework of the locales* packages, using multiarch paths, etc.).

I hope it’s only a bad moment and that things will change soon, so I can find time to work on GNU/kFreeBSD, QEMU or to do electronics. In any case you can help by handling bug reports or writing patches. Everything is in the BTS!

Thought of the day

Thursday, November 12th, 2009

New features usually come with new versions. Before reporting a bug for a new feature, it may be a good idea to make sure you are using the latest version. apt-get can be really useful for that.

Learning IA-64 assembly

Sunday, August 2nd, 2009

While testing EGLIBC 2.10.1 on all Debian architectures, I have discovered that the testsuite on IA-64 fails for the new POSIX 2008 math tests. I have reported the problem both upstream and on debian-ia64@lists.debian.org, but without success.

IA-64 being one of the last architecture (with HPPA) on which EGLIBC 2.10.1 fails to build from sources, I have decided to spend my day fixing the problem and digging into the corresponding IA-64 assembly code. The mathematical functions on this architecture are based on the Highly Optimized Mathematical Functions for the Intel® Itanium™ Architecture. Using the Intel® Itanium® Architecture Software Developer’s Manual and after a lot of tries, I have been able to add the missing code paths needed for POSIX 2008 compliance, and also fixed a few bugs on the stack frame allocation (arguments of the alloc instruction).

The resulting patch is now in the pkg-glibc SVN and in the upstream bugzilla.

And more important, I have learned the basic about IA-64 assembly!

Countries from where I have done a (E)GLIBC upload

Monday, July 13th, 2009

If you want to see your country coloured on the map, you can invite me for my next holidays ;-) .

New GPG key

Sunday, May 10th, 2009
pub   4096R/1DDD8C9B 2009-05-09
      Key fingerprint = 7746 2642 A9EF 94FD 0F77  196D BA9C 7806 1DDD 8C9B
uid                  Aurelien Jarno <aurel32@debian.org>
uid                  Aurelien Jarno <aurelien@aurel32.net>
uid                  Aurelien Jarno <aurelien@jarno.fr>
sub   4096R/C3FCA1A8 2009-05-09

I’ll get it signed by other Debian Developers tomorrow, during the Debian France meeting.

Debian is switching to EGLIBC

Tuesday, May 5th, 2009

I have just uploaded Embedded GLIBC (EGLIBC) into the archive (it is currently waiting in the NEW queue), which will soon replace the GNU C Library (GLIBC).

The EGLIBC is a variant of the GLIBC which stays source and binary compatible with the original GLIBC. While primarily targeted for embedded architectures, it has some really nice points:

We do not use some of these features yet, but this upload is a first step. From the user point of view, the package names are unchanged (except the source package and the binary package containing the sources) so no transition is needed.

Debian QEMU images updated

Wednesday, April 15th, 2009

Following the release of Debian Lenny, I have updated my set of Debian QEMU images. The following images are now available:

There is no Debian Lenny SPARC image available, as QEMU does not fully support SPARC64 yet, and Debian Lenny now only supports 64-bit kernels.

Note also that the README.txt files (which among other things contain the md5sums of the images) is now GPG signed. Read carefully these files as they contain details on how to use the images, and especially the minimum QEMU version to use.

Faster wireless access

Saturday, February 7th, 2009

The hotel we are staying in for FOSDEM is providing an expensive wireless access limited to 15kB/s.

For a faster access the solution is to use IP-over-DNS for a rate up to 48kB/s. Moreover it’s free…

Re: emulated buildds

Monday, January 19th, 2009

Wouter, I really doubt that the decision of having a Xen build daemon has been taken in a team, and the fact is that it’s causing problems.

The only goal of my post is to show we have double standards.

Emulated versus paravirtualized build daemons

Monday, January 19th, 2009

There has been a few flam^Wdiscussions about emulated build daemons, each time coming to the conclusion that we should not upload packages built on an emulated machine to the archive.

However Debian has started to use at least one paravirtualized (Xen) build daemon, the i386 experimental one. The result is that one of the tests of the GNU libc testsuite is failing. On the other hand, the GNU libc and the GCC testsuites are giving the same results on a QEMU emulated machine and a real machine, for amd64, arm, armel, i386, mips, mipsel and powerpc. Same for KVM on amd64 and i386.

I wonder if we made the right choice

QEMU PowerPC

Thursday, January 15th, 2009

For a few weeks Laurent Vivier, Blue Swirl and myself have been working on getting QEMU PowerPC working correctly with recent distributions.

QEMU used to rely on OpenHackWare for the OpenFirmware implementation on PowerPC. It is a very limited implementation (for example it as no Forth support), which is unable to boot most 2.6.x kernels with the OldWorld emulation. It is able to boot recent kernels with the PReP emulation, but things like the PCI bus emulation are not working correctly. Moreover the PReP kernels are gone with the removal of the arch/ppc tree.

OpenBIOS was already used for the OpenFirmware implementation of Sparc 32 and Sparc 64 targets. It now supports PowerPC for the OldWorld emulation. As a result it is now possible to use Debian PowerPC under QEMU emulating an OldWorld machine.

What works?

  • Display (partly), keyboard, hard disk, network;
  • Booting from CD-ROM or from disk using Quik;
  • Installation of Debian Etch or Lenny (but due to a bug in debian-installer quik.conf has to be fixed manually);
  • Standard Debian kernels;
  • G3 CPU emulation: the testsuite results of the GNU libc 2.7 and of GCC 4.3 (Debian packages) are the same than on a real machine.
  • virtio devices

What doesn’t work / has to be done?

  • A few devices part of the MacIO chipset are not emulated and/or are replaced by other devices: IDE, SCSI, Ethernet and sound;
  • The red and green colors are reversed, in some modes only (in debian-installer for example);
  • X only outputs some strange images;
  • PCI devices using I/O ports don’t work (like the RTL8029 card, or the RTL8139 card with the 8139too driver).

For those who want to test, an Etch image is available. You will need to compile QEMU by manually given that the version in Debian is too old and that openbios-ppc is still in the NEW queue.

IPsec, MTU & NAT

Monday, June 9th, 2008

Dear lazyweb, I encounter MTU problems with an IPsec setup and NAT.

Here is a simplified version of my setup:

remote host < --- internet ---> (eth0) gateway (eth1) < --- LAN

As you may have guess, the gateway has only one public IP address and thus the hosts on the LAN are connected to the internet through NAT.

The connection between the remote host and the gateway is secured using IPsec (kame tools), and this works as expected as long, as the connection is done between the remote host and the gateway. The problems arise when I try to make a connection between the remote host and one host from the LAN. Due to the use of IPsec, the MTU is reduced by 44 bytes, however “ICMP need to frag” packets are not emitted by the gateway, so the connection just hangs.

I have tried various solution from the web (setting MTU on the various interfaces, clamping MSS with iptables, defining advmss with ip route, etc.), and the only one which actually works is reducing the MTU on the LAN hosts. Not very useable given that they are a lot of hosts on the LAN.

Note that when IPsec is disabled, if I lower the MTU of eth0, the “ICMP need to frag” packets are correctly emitted, and the connection just works.

Suggestions?