Apache 2.4 mod ldap authnz_ldap debian squeeze closed (connection lost)

It does not work out of the box.

You need to open and edit


and add:

# TLS certificates (needed for GnuTLS)
TLS_CACERT /etc/ssl/certs/ca-certificates.crt

Let me know if this helped.

Docker cheat-sheet

Docker is great for development, but also, it gives you the superpower of extremely small images to easily move around docker containers.

I need this for personal stuff, but I think it can be useful to others, so let’s share it.
Continue reading “Docker cheat-sheet”

Letsencrypt is broken on Debian Jessie

You need backports,

so first add the jessie-backports to your favourite apt source.list

# Backport
deb http://http.debian.net/debian jessie-backports main

Then apt-get update, and then install back letsencrypt forcing the use of the backports:

apt-get install -t jessie-backports letsencrypt

That’s it,


Extend Xen guest partition on a live system without restart

No restart of the guest VM is required

on Dom0:

lvextend /dev/lvm/domU.lan-var -L +5G
Extending logical volumedomU.lan-var  to 7.00 GiB
Logical volume domU.com-var successfully resized

Continue reading “Extend Xen guest partition on a live system without restart”

Installing and configuring Bareos (Bacula fork) with web front-end on Debian Wheezy.

And taking nice backups easy to be restored.

The story is quiet simple: some times ago I would have liked to have a kind of 8 months old backup for a friend of mine, but it was too late. So now, I want backups with a decent retention. So I can go “back in time” and recover files. Another choice could have been Subversion, but I’m going to backup images as well so, for this reason I’ll not take Subversion into consideration.
Continue reading “Installing and configuring Bareos (Bacula fork) with web front-end on Debian Wheezy.”

Debian, managing LVM on a live system.

Playing with LVM on Debian Weehzy.

Resizing or deleting  partitions, gaining space and then redistribute it across the partition you need to resize.

Basically the logical operations are pretty simple and straightforward if taken into a ‘logical’ vie. Of course you have to shrink the partition first and then the volume, while, at the opposite if you want to grow a partition you have to resize the volume in order to be able to contain the bigger partition.
Continue reading “Debian, managing LVM on a live system.”

Maven3, Javac & Co. On Debian


Maven3 &the right JDK

I was trying to build Maven3, to build other stuff (hippo cms) and suddenly my system said:

/usr/src/apache-maven-3.0.5/build.xml:223: Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set to "/usr/lib/jvm/java-6-openjdk-amd64/jre"

This means that I’m trying to compile Maven3 without having installed the JAVA SE jdk from Oracle website, but luky you, you can follow this link: [Download Java].

One negative thing is that you have to accept the software license and then you can just download the package within the same browser session, thus you have to SCP the tar.gz archive to your server machine. This is not lazy-sysadmin-friendly indeed. 😛

By the way what i’ve done in order to undertsand where and how this package should have been moved to work fine was to look around for already present java version on my system.
the command:

# which java

gives some info, mine gives:


Then with

# ls -al /usr/bin/java 
lrwxrwxrwx 1 root root 22 Apr 27 10:10 /usr/bin/java -> /etc/alternatives/java

We see a link pointing in /etc/alternatives. Let’s have a look there:

# ls -al /etc/alternatives/java
lrwxrwxrwx 1 root root 46 Apr 27 10:10 /etc/alternatives/java -> /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java

Another link to /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java, and that is the place where to extract our downloaded archive, so

# mv /usr/src/jdk1.7.0_21 /usr/lib/jvm/
# cd /usr/lib/jvm/
# ls -al
total 32
drwxr-xr-x  5 root root  4096 May  4 08:44 .
drwxr-xr-x 46 root root 12288 Apr 27 14:24 ..
lrwxrwxrwx  1 root root    20 Mar  5 10:16 java-1.6.0-openjdk-amd64 -> java-6-openjdk-amd64
-rw-r--r--  1 root root  2387 Mar  5 10:16 .java-1.6.0-openjdk-amd64.jinfo
drwxr-xr-x  5 root root  4096 Apr 27 10:05 java-6-openjdk-amd64
drwxr-xr-x  3 root root  4096 Apr 27 10:05 java-6-openjdk-common
drwxr-xr-x  8 uucp  143  4096 Apr  4 11:32 jdk1.7.0_21

Here we are!. You can see in red (last line of previous code snippet) our jdk dir. The one in blue is the one in use (I don’t know why it is linking somenthing in the same directory…) So,

# cd /etc/alternatives
# ls -al java
lrwxrwxrwx 1 root root 46 Apr 27 10:10 java -> /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java
# rm java
ln -s /usr/lib/jvm/jdk1.7.0_21/jre/bin/java java

Then finally, I could go back into the maven3 source directory and build it with ant… After tons of output and after having downloaded the internet, it builds.


Total time: 6 minutes 8 seconds

Bash Script: one tar gz archive from each subfolder.

my treasure, missing link between dogs and unicorns, i'll never get used to such a beauty. My actual best friend. Her nose stinks of a mixture of out-of-date parmigiano and various other cheeses.
my Filippa

Hi all, this is a backup tool to be used in for automated or manual backup. What this small script does is creating one tar.gz archive for each subdirectory found starting from a given directory.

It takes just two arguments: where to start from, where to save the new created archives.

The goal is “KEEP IT SIMPLE”, so you can easily adapt this t your systems. You can for instance, hardcode the two args so you can use it for a specific duty (web folders backup /var/www or whatever).

Here you are:

cd $1
for dir in */
base=$(basename "$dir")
tar -czf "$2/${base}.tar.gz" "$dir"
echo "compressing $2/${base}.tar.gz $dir";

Example. let’s say that you have a webserver whit an usual directory structure for clients, for example:
and so.
If you wanted a separated tar gz archive for each client subfolder you should use this script this way:
./multitar /var/www /backups


Have a nice weekend


Raspberry Wifi Static Ip Config

This image shows my raspberry pi with attached an usb wireless lan adapter.

As title says, here i store how i managed to get a fixed ip address on the wireless lan network interface from shell or command line.
It’s very easy and usefull in a number of situations. For example this makes part of another my projects about remoting audio of my laptop using air-whatever and the raspberry as server, but i will describe this soon, in my next posts.

Raspberry Wifi Static Ip Config

Ingredients: Continue reading “Raspberry Wifi Static Ip Config”

Constantly Under attack, inquiring discovered huge URSS dns poison

russian dns poison attackWell it turned out it was a mobile application “classmates” produced and distribuited for free by mail.ru the reason for the unusual considereable amount of traffic on one if my ip addresses

what? Continue reading “Constantly Under attack, inquiring discovered huge URSS dns poison”