OxDEAD Unicornz

Have you ever seen so many?

Debian 8 Xfce4 Xscreensaver Lock Problem

Long blah-blah-blah, you may skip to the problem description

Long story short – after a system upgrade on my old EEEPC1005PE netbook awesome tile manager stopped to work with my config. I’m using some shifty library features and it looks like library from Debian package awesome-extra version 2012061101 does not keep up with awesome 3.5.6-1.

I don’t think it’s something unrecoverable but decided to try some new (for me) window manager. Since the netbook is not very powerful quite obviously I didn’t even consider fancy ones. My two options are xfce4 and xmonad.

Python. Threading. Function() Takes Exactly X Arguments (Y Given)

Was playing around running multiple threads in Python. Here is a part of script launching docker_cleanup(controller_name) function in a separate thread.

1
2
3
4
5
6
7
8
9
10
11
from threading import Thread
...
    threads = []
    for controller_name in controllers:
        # Remove container if it already exists
        t = Thread(target=docker_cleanup, args=(controller_name))
        threads.append(t)
        t.start()
    for t in threads:
        t.join()  # Block main thread while childs executed
...

Ubuntu 14.04 Problem With Vmbuilder

Recently hit quite an annoying bug in vmbuilder, tool that allows to build Ubuntu based virtual machines.

Was trying to build a VM using the following command:

1
vmbuilder kvm ubuntu --suite trusty --flavour virtual --arch amd64 --mem 8192 --rootsize 8000 --dest /var/lib/libvirt/images --libvirt qemu:///system --hostname new-host --user jenkins --name jenkins --pass <jenkins_user_password> --addpkg openssh-server --addpkg git --addpkg acpid

but kernel installation failed with the following error:

1
2
3
Unpacking linux-image-virtual (3.13.0.53.60) ...
, stderr: grep: /proc/cpuinfo: No such file or directory
This kernel does not support a non-PAE CPU.

Some Notes on Find Exec Output Redirect

Discovered an interesting thing today playing around find linux command.

The idea was to process several files in a directory using some utility that directs output to stdout. In order to keep tracking it’s useful to have a status file with a list of already processed files.

Ubuntu 14.04 Ssh init.d Script Broken

Wasted lot of time today trying to figure out why ssh on some server still allows to log in with password despite the fact that in /etc/ssh/sshd_config password based log in is disabled:

1
PasswordAuthentication no

Ubuntu 14.04 Desktop No LUKS + LVM in Installer

Was choosing a Linux distro for new workstation. Decided to try Ubuntu 14.04.2 desktop on virtual server first and I think I’ll use Fedora 21.

I was unable to configure encrypted volumes in conjunction with LVM using Ubuntu 14.04 desktop installer. Here is an instruction how to configure it manually but, hey, I’ve heard Ubuntu is a user-friendly distro. Pity if this actually means all sharp toys are locked in a drawer. Furthermore when I tried to revert changes and remove encrypted volumes I’ve created installer just got stuck.

I thought the problem was somehow related to the fact that I’m trying to install to virtual server. Downloaded Fedora 21, gave it a try and everything worked like a charm on a VM.

Probably I’m trying to use it in a weird way but to me it does not look like Ubuntu is ready for desktop yet/already.

Chef-zero Is Broken in Ubuntu 14.04

I was playing a bit with applying chef cookbooks locally, without a chef server and found that version of Chef from Ubuntu repo is way too low for normal operation in local mode.

1
2
3
4
5
6
7
# apt-cache policy chef
chef:
  Installed: 11.8.2-2
  Candidate: 11.8.2-2
  Version table:
 *** 11.8.2-2 0
        500 http://us.archive.ubuntu.com/ubuntu/ trusty/universe amd64 Packages

There is a bug resolved in recent versions of Chef related to the way in which chef-zero parses json files. If there is metadata.json file instead of metadata.rb in a cookbook chef-zero fails to parse this file expecting just a filename instead of full file content.