How can I copy from files from one Linux (or generally, any Unix based OS) device to another? Assuming both have some kind of network connection, I usually go and install my SSH key on the target device and then simply run scp or rsync, the latter being especially useful if I need to update the remote file tree. If for some reason there was no SSH, I might resort to FTP, SFTP even, SMB, NFS.

The only option Android leaves - at least if you don't want to void the warranty by rooting the device - is this: Connect the device with a cable (remember this being on the same network) and use the worst protocol you can think of to copy files to the device. Even in the latest Ubuntu the version of the library needed for that is to old, so you will have to painfully upgrade it. Rage ensued!!

I'm not even sure whether Google or Samsung, which manufactured the device in question, are to blame for this. One of them however broke the whole concept of networked devices just to force everyone to either rebreak the jailed concept alltogether or ressort to a crippled, restricted Microsoft developed protocol like MTP. What where they thinking a user would need to copy files?

Dear Google, please fix that. Give the users some way to copy files to their device from native Linux environments. Create an app to run an SFTP server, be it jailed to parts of the file system and let me copy files over there as I usually do. I will now have to head to the Market and look for some third party app to copy files. The heck!

Here is a list of very cool, useful projects enhancing the already great Twitter Bootstrap:

  • Lavish creates a Bootstrap colorscheme (CSS and LESS) out of any image you supply. This link will launch a colorscheme for the website of the JDAV Baden-Württemberg.

  • StyleBootstrap will give you a finer grained control over the color choices. It allows you to format fonts and colors of elements of the Bootstrap layout like the Navbar, the text body, buttons and forms.

  • Boilerstrap combines Bootstrap with lots of useful tools you almost certainly want to have like the HTML5 Boilerplate tweaks, Modernizr loading, javascript compression and other useful things.

  • WrapBootstrap has a list of commercial Bootstrap template with an option to buy one if you like it.

Today I tried to copy files to a Samsung Galaxy Tab 10.1. After figuring out, that it will only talk MTP via the USB port, I installed the mtp-tools package and happily ran mtp-detect in a shell.

pimp@eekkater:~$ mtp-detect 
libmtp version: 1.1.0

Listing raw device(s)
Device 0 (VID=04e8 and PID=6860) is a Samsung GT-P7510/Galaxy Tab 10.1.
   Found 1 device(s):
   Samsung: GT-P7510/Galaxy Tab 10.1 (04e8:6860) @ bus 1, dev 17
Attempting to connect device(s)
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
inep: usb_get_endpoint_status(): No such device
outep: usb_get_endpoint_status(): No such device
usb_clear_halt() on IN endpoint: No such device
usb_clear_halt() on OUT endpoint: No such device
usb_clear_halt() on INTERRUPT endpoint: No such device
ignoring usb_claim_interface = -9ignoring usb_claim_interface = -22LIBMTP PANIC: failed to open session on second attempt
Unable to open raw device 0

Truly, the best part is the last line. However, nothing was OKok and some ducking later I figured I had to upgrade libmtp to the latest version by hand. As I'd like future Ubuntu package upgrades not to break my upgraded version and hoping that the maintainers will sooner or later catch up, I decided to build the packages with the new source. Thanks to the package using some modern design paradigms, there was little effort needed to get the whole thing going. Most of the basic steps are similar for other packages and are – among others – documented in the Debian New Maintainer Guide in the chapter on new upstream releases.

The Upgrade Process

First you have to install the build requirements by running:

sudo aptitude build-depends libmtp

Then you can download the old version's source package from the Ubuntu repositories:

apt-get source libmtp

This will automatically download and extract everything for you, so you theoretically could rebuild the old version without any further steps.

Now to the actual upgrade. The libmtp package comes with a watch file, which contains the URL to look at for new versions. Thus you only need to run uscan from inside the package directory:

cd libmtp-1.1.0/; uscan

which – if successful – will output:

libmtp: Newer version (1.1.2) available on remote site:
  (local version is 1.1.0)
libmtp: Successfully downloaded updated package libmtp-1.1.2.tar.gz
    and symlinked libmtp_1.1.2.orig.tar.gz to it

Hooray! That's the version we want. Next you need to unpack the new source and copy all Debian build specific stuff over there. This action being quite common among the build processes, there's a helper for that as well. Run

uupdate -v 1.1.2 ../libmtp_1.1.2.orig.tar.gz

which – if successful – will output:

New Release will be 1.1.2-0ubuntu1.
-- Untarring the new sourcecode archive ../libmtp_1.1.2.orig.tar.gz
Unpacking the debian/ directory from version 1.1.0-3ubuntu1 worked fine.
Remember: Your current directory is the OLD sourcearchive!
Do a "cd ../libmtp-1.1.2" to see the new package

Do as it says to change to the new package.

cd ../libtmp-1.1.2

There we will apply patches to the source tree, which are included in Ubuntus version of the package and adapt it's behaviour to the specifics of Ubuntu. As most of the patches failed, I figured I'd only keep the one which worked and looked like it did more than add support for some devices. The file debian/patches/series contains all patches that will be applied. Edit it and remove all patches except for 1002-udev_rules.patch.

echo 1002-udev_rules.patch > debian/patches/series

Now we will apply all (that single) patches to the sources by running:

while dquilt push; do dquilt refresh; done

Next you have to update the changelog file to reflect the new version of the package. There is a helper for that as well which will fill out almost everything you need. Run:


and add any comment as you wish, for example "Fix libmtp support for the Galaxy Tab". There are some rules, which you would have to follow if you were to distribute the package through the official Debian/Ubuntu channels, but let's just assume you won't.

One more thing to do before you can start the build. One filename in the upstream release is different, so you will have to run

sed -i -e 's/39/69/' debian/libmtp-common.install

and point the build system to the right path. After that you're ready. Fire up


and watch the whole thing build – it will output quite some lines during the process. After it has finished, you should have (among others) the following files

$ ls ../*deb

in the parent directory. Go ahead and upgrade your installed packages by running [*]

sudo dpkg -i ../libmtp9_1.1.2-0ubuntu1_amd64.deb ../libmtp-common_1.1.2-0ubuntu1_all.deb ../libmtp-runtime_1.1.2-0ubuntu1_amd64.deb ../mtp-tools_1.1.2-0ubuntu1_amd64.deb

Run mtp-detect again and it will output a long list of specs for your device. Hooray!

[*] Warning: Your file names may differ if you're not on a 64bit machine.

Beim Abwischen der Küchenplatte hab ich das da gesehen und fotografiert:

Im Treppenhaus ist der Steinmetz zugange und schleift gerade zum zweiten Mal die Treppen ab - diesmal wohl recht gründlich. Das sieht dann so aus:

When committing changes to our own installation of the Open Build Service, sometimes the webinterface will not show the rebuilds triggered by the changes. Instead, it shows a yellow triangle on the repo icons and hints "State Needs Recalculations" when hovering over the icon. It seems, that this happens due to outdated information fetched from Memcached. To fix this problem run

rcmemcached restart

which will invalidate the cached information used by the frontend and make it display fresh values.

Automatically Dimming the Backlight on Battery

Since upgrading my Thinkpad to the latest Xubuntu I have noticed that after 10 seconds of inactivity the display backlight automatically dimms down, which makes reading text for more than a couple of seconds pretty annoying. The question had already been asked on but the answer was gnome specific and I could not find the specified dialog on Xubuntu, nor could I find the options in gconf-editor.

Ruling Out the Causes

As changing the auto-dimming level and timeout in xfce4-power-manager-settings did not fix it, I consecutively killed the xfce4-power-manager process, xscreensaver and upowerd, all without any success

gnome-settings-manager it is

Finally I stumbled over this bug report where a gsettings command is given, that will change the timeout. A quick

gsettings set org.gnome.settings-daemon.plugins.power idle-dim-time <seconds>

will fix it.

gconf-editor - dconf-editor

After that, I also found a gui to edit the gsettings database called dconf-editor, which is found in the dconf-tools package. Inside, browse to org.gnome.settings-daemon.plugins.power and you will find more settings and even get to disable the power plugin alltogether.

Alle Radiowecker in der Gemeinde gehen vor

Das kriegt ihr nie raus: hier in der Pfalz bei den Eltern gehen zur Zeit die Radiowecker vor, aber nur tagsüber. Nachts gehen dann alle ganz normal und die Abweichung wird nicht größer. Woran liegt es wohl?

Arbeiten am Stromkabel beeinträchtigen die Wecker

Es wird ein neues Stromkabel in den Ort gelegt. Deshalb wird tagsüber der ganze Ort mit einem Generator versorgt. Der wiederum kommt nicht damit zurecht, dass die Photovoltaik-Anlagen auf den Dächern laufen. Man kann die aber nicht zentral ausschalten. Schon ne Idee, was das mit den Weckern zu tun hat?

Der Solarstrom ist Schuld

Die Photovoltaik-Anlagen schalten sich automatisch ab, sobald die Netzfrequenz über 51.5 Hz steigt. Also wird am Generator die Frequenz auf 52 Hz erhöht und schon hat man Ruhe auf den Dächern. Als Nebeneffekt laufen dafür die Uhren, die das Netz als Takt verwenden, 4 Prozent schneller.

Über das Stromnetz, über das man die Photovoltaik-Anlagen nicht steuern kann, müssen aber die Nachtstrom Geräte und die Straßenbeleuchtung gesteuert werden. Also wird nachts der Generator ausgemacht und die Uhren laufen wieder normal schnell.

The problem

Some time ago, I manually hacked together a working setup to use gnome-keyring-daemon in xubuntu to automatically unlock my ssh key when logging in. This setup broke when I upgraded to Ubuntu Lucid and I have never tried to fix it in Maverick and Natty. With the arrival of Oneiric, I gave the gnome-keyring-daemon another try. Lo and behold - it works!

The fix

To enable the gnome-keyring-daemon, make sure to have GNOME services enabled in the XFCE session settings. Then add an entry to the xfconf database with the following command: xfconf-query -v -c xfce4-session -p /startup/ssh-agent/enabled -n -t bool -s false

That should do the trick. You can manage your keys using the seahorse GUI.

Das Problem

Gerade bin ich mittem im Seich von der Kletterhalle heimgeradelt und hab folgendes beobachtet: Bäume dienen eine Zeit lang als Regenschutz. Irgendwann sind sie dann aber „voll“ und man wird genauso nass, wenn man drunter durchfährt.

Die Lösung

Deshalb folgende Idee: Jeder Baum bekommt einen solarbetriebenen, elektrischen Rüttler an den Stamm. Den puffert man mit einer Batterie (wenn's regnet scheint ja selten die Sonne) und macht ihn so hoch, dass ihn keiner klaut. Außerdem braucht der Rüttler noch einen Sensor, mit dem er erkennen kann, ob jemand unter dem Baum fährt, läuft oder steht. Wenn es dann regnet und gerade kein Radler oder Fußgänger in der Gefahrenzone ist, rüttelt der Rüttler das Wasser vom Baum. Danach kann man wieder eine Zeit lang trocken drunter durchfahren.

Der Rüttler könnte zum Beispiel aus einer Seilwinde zwischen zwei Bäumen bestehen. Dann spannt man das Seil, bis sich beide Bäume ganz leicht zueinander hin gebogen haben. Wenn das Seil gut gespannt ist, löst ein Haken aus und die Bäume schnellen zurück in ihren ursprünglichen Zustand. Dabei wird das Wasser abgeschüttelt.

« Previous Page -- Next Page »