OpenWrt

French ISP SFR publishes OpenWrt sources of its DSL modem

Logo EfixoThe neufbox 4 is a BRCM63xx based DSL router the french ISP SFR provides to its customers, and more than 3 million units are currently in use. The device is developed by Efixo and the OpenWrt based sources are available through a subversion repository and documentation is placed in a Trac wiki.

Efixo has shown a commitment for openness and have in the past been providing development sources.neufbox 4

Some sources are not directly available, but proprietary binary drivers are downloaded and integrated in the firmware during the default build process. Now, everyone can checkout the OpenWrt based sources, compile and install a firmware version which includes complete services, such as VoIP and television.


~$ svn co http://svn.efixo.net/trunk/ neufbox
~$ cd neufbox/
~$ make nb4-main

Further details (mainly in french) can be found in the unofficial neufbox 4 community, which offers information on how to build a serial JTAG, how to reflash the neufbox 4 and more.

Debian

Blank screen fixed in grub-pc 1.98~20100128-1.2

The bug I’ve talked about in my last post, and described in Debian ticket #567245 has been fixed in grub-pc 1.98~20100128-1.2. From the changelog:

grub2 (1.98~20100128-1.2) unstable; urgency=low

* Non-maintainer upload.
* Stop setting gfxpayload=keep (closes: #567245).
– Julien Cristau <jcristau@debian.org>  Sun, 14 Feb 2010 20:37:51 +0100

There is also an interesting message in the discussion concerning the related Debian ticket #567393:

Previously grub2 defaulted to start linux in text mode unless VESA graphics mode was explicitly requested. Recently we changed to defaulting to generic framebuffer when its support is enabled in linux.
I found 3 problems:
1) At least some KMS modules expect graphics card to be in text mode. It would be kernel-side problem since on some firmware types this mode isn’t easily or sometimes isn’t at all available. On the other hand it’s useful to be able to tell grub2 to start in text mode even if generic framebuffer is supported by kernel. I added this ability to mainstream grub. To use it add:
GRUB_GFXPAYLOAD_LINUX=text
to /etc/default/grub
2) generic framebuffer expects size in bytes and not 64KiB blocks. I fixed it in mainstream
3) intelfb expects handover only from vesa. Attached patch to linux may help.

None of 3 changes I mentioned is packaged in debian yet.

Debian

Blank screen after upgrading to grub-pc 1.98~20100126-1

As I always shut down my laptop at work during the weekends, but never reboot it during the week, monday is the day I discover that the updates of the previous week have broken my Debian unstable system.

This monday, it didn’t go very far. After displaying the menu in grub-pc, and showing:
Loading initial ramdisk ...
the screen turns blank. But the computer still boots fine, and I was able to ssh into it in order to fix the problem.

It turns out to be a problem that occurs when KMS is enabled. Some information is available from Debian bug reports #567245 and #567393.

Now here’s how to fix this problem. In /etc/grub.d/10_linux find this line (line 68 for me):
set gfxpayload=keep
and change it to:
set gfxpayload=text

And then regenerate your /boot/grub/grub.cfg with this command:
$ sudo update-grub

And finally, you can reboot, and everything should be fine!

OpenWrt

OpenWrt packages: the TITLE field

In OpenWrt, the default values for fields concerning a package are defined in /trunk/include/package-defaults.mk.

You can see that for the TITLE field, the default is the empty string:
TITLE:=

So you need to define it in your package Makefile. Let’s take the Makefile of liblzo as an example:

define Package/liblzo
SECTION:=libs
CATEGORY:=Libraries
TITLE:=A real-time data compression library
URL:=http://www.oberhumer.com/opensource/lzo/
endef

After doing a make menuconfig, and navigating to the liblzo package, it will show this:

OpenWrt menuconfig for liblzo package

Okay, pretty simple. Now what is the maximum length possible for this field?

The TITLE field can be up to 65 characters in length:

define Package/liblzo
SECTION:=libs
CATEGORY:=Libraries
TITLE:=abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz012
URL:=http://www.oberhumer.com/opensource/lzo/
endef

This will show:

OpenWrt menuconfig for liblzo package (66 characters TITLE)OpenWrt menuconfig for liblzo package (66 characters TITLE)

But if you add one more character, the TITLE field will now be 66 characters long:

define Package/liblzo
SECTION:=libs
CATEGORY:=Libraries
TITLE:=abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123
URL:=http://www.oberhumer.com/opensource/lzo/
endef

And it will show an empty title:

OpenWrt menuconfig for liblzo package (65 characters TITLE)OpenWrt menuconfig for liblzo package (65 characters TITLE)

AuthFlux, FluxBB, MediaWiki

AuthFlux – MediaWiki and FluxBB integration

AuthFlux is a MediaWiki extension which enables the users registered on your forum to log into your wiki with the same username and password.

It is adapted from Auth_PHPBB 3.0.3 which is made by Nicholas Dunnaway. Check out his website!

I have tested it with MediaWiki 1.13.2 and FluxBB 1.2.20.

Download authflux-3.0.3.tar.gz.

Don’t forget to add this to your LocalSettings.php:

require_once( "$IP/extensions/AuthFlux/AuthFlux.php" );
 
$wgAuth_Config = array();
 
$wgAuth_Config['WikiGroupName'] = 'Wiki';       // Name of your FluxBB group
                                                // users need to be a member
                                                // of to use the wiki. (i.e. wiki)
                                                // This can also be set to an array
                                                // of group names to use more then
                                                // one. (ie.
                                                // $wgAuth_Config['WikiGroupName'][] = 'Wiki';
                                                // $wgAuth_Config['WikiGroupName'][] = 'Wiki2';
                                                // or
                                                // $wgAuth_Config['WikiGroupName'] = array('Wiki', 'Wiki2');
                                                // )
 
$wgAuth_Config['UseWikiGroup'] = false;          // This tells the Plugin to require
                                                // a user to be a member of the above
                                                // FluxBB group. (ie. wiki) Setting
                                                // this to false will let any FluxBB
                                                // user edit the wiki.
 
$wgAuth_Config['UseExtDatabase'] = false;       // This tells the plugin that the FluxBB tables
                                                // are in a different database than the wiki.
                                                // The default settings is false.
 
//$wgAuth_Config['MySQL_Host']        = 'localhost';      // FluxBB MySQL Host Name.
//$wgAuth_Config['MySQL_Username']    = 'username';       // FluxBB MySQL Username.
//$wgAuth_Config['MySQL_Password']    = 'password';       // FluxBB MySQL Password.
//$wgAuth_Config['MySQL_Database']    = 'database';       // FluxBB MySQL Database Name.
 
$wgAuth_Config['UserTB']         = 'flx_users';       // Name of your FluxBB user table. (i.e. users)
$wgAuth_Config['GroupsTB']       = 'flx_groups';      // Name of your FluxBB groups table. (i.e. groups)
$wgAuth_Config['PathToFluxBB']    = '../forum/';         // Path from this file to your FluxBB install.
 
// Local
$wgAuth_Config['LoginMessage']   = '<strong>You need a FluxBB account to login.</strong>
<a href="' . $wgAuth_Config['PathToFluxBB'] .
                                   'register.php">Click here to create an account.</a>'; // Localize this message.
$wgAuth_Config['NoWikiError']    = 'You are not a member of the required FluxBB group.'; // Localize this message.
 
$wgAuth = new AuthFlux($wgAuth_Config);     // AuthFlux Plugin.

Debian, XFCE

Activer les boutons “Redémarrer” et “Eteindre” dans XFCE

Avec une installation par défaut de XFCE, les boutons Eteindre et Redémarrer ne sont pas actifs.

Boutons \"Redémarrer\" et \"Eteindre\" grisés dans XFCE

En effet, pour avoir le droit d’éteindre l’ordinateur, l’utilisateur doit être autorisé à exécuter la commande /usr/sbin/xfsm-shutdown-helper en temps que root (valable sous Debian, pour d’autres distributions, le chemin peut être différent).

Pour cela, il faut éditer le fichier /etc/sudoers. Il suffit d’y ajouter les lignes suivantes :

# User alias specification
User_Alias XFCE_SHUTDOWN_USERS = ALL
 
# Cmnd alias specification
Cmnd_Alias XFCE_SHUTDOWN_COMMAND = /usr/sbin/xfsm-shutdown-helper
 
# User privilege specification
XFCE_SHUTDOWN_USERS	ALL = NOPASSWD: XFCE_SHUTDOWN_COMMAND

Voilà, les deux boutons sont maintenant activés !

Debian

Installation de Symfony sous Debian

Nous avons vu dans le billet précédent comment installer lighttpd avec PHP sous Debian.

Cette fois-ci c’est au tour de Symfony.

N’ayant aucune connaissance particulière avec Symfony, nous allons d’abord tester la sandbox afin de suivre le tutorial pour débutant.

Commençons par télécharger l’archive et l’extraire :

# cd /var/www
# wget http://www.symfony-project.org/get/sf_sandbox_1_1.tgz
# tar xpf sf_sandbox_1_1.tgz
# rm sf_sandbox_1_1.tgz

Ne pas oublier l’option p à la commande tar, pour conserver les permissions des fichiers lors de l’extraction.

Il suffit ensuite d’aller sur http://localhost/sf_sandbox/web/ pour admirer la page temporaire de Symfony. Si vous avez suivi le billet précédent, il ne devrait pas y avoir de problème particulier.

On verra la prochaine fois comment démarrer avec Symfony.

Debian

Installation de PHP avec Lighttpd sous Debian

Grâce à Debian, c’est plus facile. C’est parti !

On commence par lighttpd :

# aptitude install lighttpd

Ensuite c’est au tour de php :

# aptitude install php5-cgi

Il faut maintenant activer le module fastcgi :

# lighty-enable-mod fastcgi

Il ne nous reste plus qu’à redémarrer lighttpd pour qu’il prenne en compte les changements :

# /etc/init.d/lighttpd force-reload

Et c’est tout !

Nous allons maintenant tester notre installation pour vérifier que tout marche bien.

Pour cela, nous allons créer le fichier /var/www/info.php contenant tout simplement :

<?php phpinfo(); ?>

Et finalement d’ouvrir dans son navigateur favori l’adresse suivante : http://localhost/info.php.

Une page présentant la version de PHP, ainsi que diverses informations devrait s’afficher. Tout marche bien.