And now what?

Having no time, at the moment, to sit through comprehensive writing on any subject (be it of professional, or personal interest), I would point out that I am trying to keep up with the dynamics of communications, in my area of interest, via micro-blogging, instead. So – if interested – please follow me (and I’ll follow you) on twitter – last 10 comments should be available on the right side of this posting (when the widget actually works)
I’ll try to come back here, once having something of more substance (and time) to document …

VMWare tools installation for Mandriva

I meant to write this post for a long time, but today my level of frustration having to carry out the process below, all over again (upgrade of vmware workstation to version 6.0.5 meant another version of tools to be installed to run my mandriva inside Vista) reached a point where I saved it – and here it is (your mileage in regards to version of either vmware, or mandriva kernel, or both, may vary, but the problem is there):

# vmware-config-tools.pl

… — eventually the following comes up

What is the location of the directory of C header files that match your running
kernel? [/usr/src/linux/include]

The directory of kernel headers (version 2.6.24.7-1mnbcustom) does not match
your running kernel (version 2.6.24.7-desktop-1mnb).  Even if the module were
to compile successfully, it would not load into the running kernel.

PROBLEM: different names used by mandriva in different places. Here is what we have, in the scenario above:

# ls -l /usr/src/linux

lrwxrwxrwx 1 root root 19 2008-08-19 08:55 /usr/src/linux -> linux-2.6.24.7-1mnb

NOTE the -1mnb

Now let’s do this:

# grep -r 1mnb /usr/src/linux

/usr/src/linux/fs/proc/proc_misc.c:     printk(KERN_INFO “Hook version: 2.6.24.7-1.uc1mnb1 2008/07/11\n”);
/usr/src/linux/include/config/kernel.release:2.6.24.7-1mnbcustom
/usr/src/linux/include/config/auto.conf:# Linux kernel version: 2.6.24.7-1mnbcustom
/usr/src/linux/include/config/auto.conf:CONFIG_KERNELVERSION=”2.6.24.7-1mnbcustom”
/usr/src/linux/include/linux/utsrelease.h:#define UTS_RELEASE “2.6.24.7-1mnbcustom”
/usr/src/linux/include/linux/autoconf.h: * Linux kernel version: 2.6.24.7-1mnbcustom
/usr/src/linux/include/linux/autoconf.h:#define CONFIG_KERNELVERSION “2.6.24.7-1mnbcustom”
/usr/src/linux/Makefile:EXTRAVERSION = .7-1mnbcustom
/usr/src/linux/.config:# Linux kernel version: 2.6.24.7-1mnbcustom

It looks like we’ll have to change ALL occurences of the string “2.6.24.7-1mnbcustom” in the files above, with what the info about the running kernel is, i.e. “2.6.24.7-desktop-1mnb”. So:

# grep -rl 1mnbcustom . |xargs sed -i -e ’s/1mnbcustom/desktop-1mnb/g’

and

# vmware-config-tools.pl

runs to completion!

VMWare Fusion & shared folder with Linux guest

Under guest (Linux) identify uid and gid:

guest$ id
uid=500(username) gid=500(groupname) groups=500

then adjust the /etc/fstab file accordingly, in the block added by VMWare software:
old: .host:/ /mnt/hgfs vmhgfs defaults,ttl=5 0 0
new: .host:/ /mnt/hgfs vmhgfs defaults,ttl=5,uid=500,gid=500 0 0

lastly umount and remount hgfs:

guest$ sudo umount /mnt/hgfs
guest$ sudo mount /mnt/hgfs

securely saving kmail critical info to an USB key

This is what I have done on my macosx system for this:

1. created a directory for what I deem to be critical files (emails and configuration) on my system:

~$ md /<path-to-mail-backup-dir>/mail-backup

2. created a script able to update the backup directory, from the major ~/.kde place, tar and encrypt (using openssl and a password file to be passed to the encryption process) the tar file, then moved the encrypted file to the mounted USB volume (generically named “NO NAME” in the example). The script file is:


#!/bin/sh

cd ~/.kde/share/apps/
rsync -avz ./kmail –delete /<path-to-mail-backup-dir>/mail-backup/
rsync -avz ./kabc –delete /<path-to-mail-backup-dir>/mail-backup/
cd ../config/
rsync -avz ./kmailrc* –delete /<path-to-mail-backup-dir>/mail-backup/
rsync -avz ./emailidenti* –delete /<path-to-mail-backup-dir>/mail-backup/
cd /<path-to-mail-backup-dir>/mail-backup
tar -cf mail-backup.tar /<path-to-mail-backup-dir>/mail-backup/
openssl des3 -salt -in mail-backup.tar -out mail-backup.tar.des3 -pass file:/<path-to-password-file>/password.txt
mv -f mail-backup.tar.des3 /Volumes/NO\ NAME/
rm -f mail-backup.tar*

kmail, firefox and macosx

Need to document how to configure firefox launching from within kmail, as none of the “obvious” (googled) options worked:

X11 –> terminal –> kcontrol –> KDE components –> Component chooser –> Web browser –> enable “in the following browser” and add this line:

open /Applications/Firefox.app

The problem is that the only answer having come up close to the above was indicating the line to be:

/Applications/Firefox.app/Contents/MacOS/firefox

recommendation from an old posting on the subject, but which option leads to a “complaint”, if firefox is already running: “A copy of firefox is already open …”

beyond belief – 2007

Recordings from the second edition of this conferenceEnlightenment 2.0 – are now available online.

migrating kmail between systems

On some systems mail is found under $HOME/.Mail, on some others under $HOME/Mail and – yet on others – I’ve found it even under $HOME/.kde/share/apps/kmail. Regardless of where the source (to be copied from) directory of email is, the important thing is to have the variable “folders”, from $HOME/.kde/share/config/kmailrc point to the target directory.

The only method I have found reliable to migrate directories and files has been by using rsync w/ssh & tar, combined. Assuming that in our case the <source> email directory is /home/user/.Mail, and that the <target> directory we choose is /home/user/.kde/share/apps/kmail the followings are necessary steps to produce a functional kmail <target> system:

<target>/home/user/.kde/share$ rsync -avze ssh user@<source>:/home/user/.Mail/ ./apps/kmail

NOTE: it is important to have the <source> directory ending with a trailing “/”, to be able to copy just the content of it on the <target> one. For the <target> directory having a trailing “/”, or not, makes no difference!

<target>/home/user/.kde/share$ rsync -avze ssh user@<source>:/home/user/.kde/share/apps/kmail/ ./apps/kmail

NOTE: the above needs to be done, because the <…>kmail directory always contains info, even if the mail was not residing there (such as account:@host:port for various pop accounts, autosave info, etc.)

<target>/home/user/.kde/share$ rsync -avze ssh user@<source>:/home/user/.kde/share/config/kmailrc* ./config/

NOTE: the above copies all versions of configuration files, but the really important one is kmailrc, so the command above may be used w/out the wildcard (*)

<target>/home/user/.kde/share$ rsync -avze ssh user@<source>:/home/user/.kde/share/apps/kabc/ ./apps/kabc

NOTE: the above copies the address-book(s) (std.vcf + associated files)

<target>/home/user/.kde/share$ rsync -avze ssh user@<source>:/home/user/.kde/share/config/emailidentities ./config/

NOTE: the above copies all email identities you (may) have configured to use with kmail (usually associated with multiple accounts, of course)

<target>/home/user/.kde/share$ vi ./config/kmailrc ==> make sure you have the line:

folders = $HOME/.kde/share/apps/kmail

That’s it!

P.S. If deciding to use the above method to continuously backup kmail, instead of just migrating it from one system to another, then add a –delete option to the rsync command

Nokia E61 and video creation with MacOSX

The [set of] tool[s] needed to produce a properly encoded movie for the Nokia E61 [fantastic!] smartphone is called ffmpegX.

The most successful outcome of movie encoding for this platform (video and audio) I was able to obtain was by using the following configuration:

* Quick preset (pull down list): 3gp (this one doesn’t really matter that much, as I had to modify both the Video and Audio codecs, as described below, but found it to be delivering the closest defaults … or at least I think so :) )

* Video Codec (video tab): MPEG4[.MP4] (ffmpeg) with Video Bitrate = 720 & Video Size = 320×240 (or 320 + autosize 4:3) & Framerate = 12.5

* Audio Codec (audio tab): AAC (MOV/MP4/3GP) with Audio Bitrate = 160 & Sampling = 44100 & Channels: Stereo

network tools #1

Yet another place-holder for (less popular than the likes of Wireshark – no need to repeat those) tools I have found useful in my years of toying with networking and security:

* a set of of tools, all packaged very nicely (merci, Laurent!), working on either Linux, *BSD, MacOSX (have I ever mentioned that this is my platform of choice ? – having switched from Linux a few years ago) or even Windows: Netwib/ox/ag. Could be used either via a friendly GUI (NetwAG), or simply from the command line (NetwOX). The content of this toolbox is simply amazing!

* one of my all-time favorite set of tools: ntop and nProbe. The first one – an amazing web-based network traffic analyzer, capable of working on either captured traffic mode, and/or in combination with netflow or sflow. The second one is a software probe that could capture traffic and process it in netflow format, to be sent – then – to analyzers of such (I use it extensively where Cisco netflow is not available).

* OpenNMS is a full-blown, open source Network Management solution. Its authors compare it with an enterprise-grade tool like HP OpenView. I personally consider it – alongside Nagios – a fantastic solution for centralized monitoring (a sort of informational portal)

* somehow related to the above, in the category of portal-like monitoring tool, with RRD-based graph trending capabilities is Cacti – another favorite of mine.

* “sitting” in between Cacti and the previous two NMS tools is the ‘Just For Fun’ NMS – which is an SNMP + syslog capable NMS. I have not used it in a long time, but its updated info may convince me to give it another swirl one of these days

google usage … nice

Very nice (and useful!) usage of Google search capabilities for real scientific info.