Kubuntu 10.10 with KDE 4.6 and full screen flash video

After upgrading to KDE 4.6 on Kubuntu 10.10 I started to have some problems on startup, namely some Dbus errors, unable to logout, systray applets not starting, and so on. For clearing it up, I erased my profile (mv .kde .kde_old EDIT:  DO THIS ONLY IF you don NOT care about your  KDE data. DO NOT DELETE if you want to revert the operation) and rebooted.

So at logon time a new profile was created, and the errors that I had where gone. The only issue was that I had to configure my workspace again.

Trouble hits when I tried to see a full screen flash video, namely 1080p or 720p and it stutters badly. Previously I had no such problem. Logging out and logging in with my wife’s profile, the issue was gone… Strange indeed… Did a lot of install/remove/install of flash plug-in, but nothing that I did solved the issue. But installing a version of Flash Plugin that I did KNOW for sure that it worked full screen didn’t also solved the issue, I know that my problem was something else..

To keep the story short, as I’m not a great writer or blogger, there is one setting that needs to be changed on KDE to allow full screen flash to work fine (at least for me):

1) Goto System Settings

2) Select Desktop Effects

3) Select Advanced

4) Unselect (! yes unselect) Suspend Desktop effects for full screen windows. Apply and done.

Now it works fine for me. By the way, I’m using an i920 with ATI 4870 proprietary drivers and 64 bit Kubuntu.

Visio alternative for Linux

We really know that Visio for Linux will never be a reality, and so all we have right now is some tools, that from usability point of view or features, are limited: DIA and Kivio 1.6

The new version of Kivio, in the foreseen future on the Calligra suite, is being worked on, and might be a reality, but with unknown stencils/icons.

I’m not the only one, that for work reasons, has this need, as this post on Reddit shows: http://www.reddit.com/r/linux/comments/ewhy5/alternatives_to_dia/

There are here great alternatives, some free, some limited, that can be used to make at least good looking diagrams without resorting to a virtual machine running Windows and Visio:

1) http://www.gliffy.com

2) http://www.lucidchart.com

3) http://www.mxgraph.com/

Private Dokuwiki on multiple computers using Dropbox

Dropbox is a great tool, and due to it’s file sync capabilities it has a lot of possibilities to create “hack” solutions like the one that I’m going to describe here:

If you have a personal Wiki that you want to share between several computers, the usual “normal” way of doing so is to setup a 24/7 Web Server with Apache/Lighttpd and, in my case, installing Dokuwiki. Then the client PC’s to access the Wiki all they have to do is tto point their browser to access this web server. But what this means is that you really need to have a web server available 24/7 even  if not using it… And where to locate this web server? At my home? Pay hosting fees? And if I don’t have connection to it? And so on…

The solution is using Dropbox as your data repository for DokuWiki Content. Content is always available and replicated automatically on all computers, even if you don’t have internet access. You can even share your Wiki privately with your friends/family/colleagues by inviting them to the Wiki folder… and off course setting up Lighttpd on their computers.

How it works:

I’m using Lighttpd as the web server. For personal use is more than enough and it supports PHP5 and Dokuwiki just fine. Lighthttpd is installed in all computers that access the wiki.

The installation steps for Ubuntu/Kubuntu and derivatives are the following:

1) Install Lighttpd, php5 and dokuwiki packages: apt-get install lighttpd php5-cgi dokuwiki.

During installation of dokuwiki, it will be asked what web server should be configured automatically, namely Apache or lighttpd. We must choose the later, lighttpd by pressing space (so that a * should appear) and, if Apache is not installed, deselect Apache.

The following question is if, in case of dokuwiki package removal, should the wiki content ALSO be removed… We should answer NO.

Then, finally, the wiki admin password is asked.

After installation, the lighttpd server should start automatically, and using a browse the local web page http://localhost should show the default web server page.

Then follow these instructions http://redmine.lighttpd.net/wiki/lighttpd/TutorialLighttpdAndPHP#Configuration to enable Lighttpd with PHP5.

Basically is to edit the php.ini file that’slocated in /etc/php5/cgi/php.ini and the lighttpd.conf file located on /etc/lighttpd directory. These changes must be done as the user root (use sudo -s on a command shell).

Make sure that when pasting the fastcgi.server section into the lighttpd.conf file, the “bin-path” entry points to the php5-cgi binary, normally located at /usr/bin/php5-cgi

Save and restart the lighttpd server with the command /etc/init.d/lighttpd restart


2) Copy /usr/share/dokuwiki to /var/www with the following command:  cp -R /usr/share/dokuwiki /var/www and make sure the permissions are correct: chown -R www-data:www-data /var/www/dokuwiki

Note that the first copy command there are no trailing slashes.

3) You can rename the folder from dokuwiki to other name, like wiki, for example to change the URL. This is optional.

4) Create the Dokuwiki data directory on your Dropbox: mkdir -p ~/Dropbox/wiki/data This should be done in only ONE computer, the others will synchronize automatically.


5) Change the permissions on the directory: sudo chown -R www-data ~/Dropbox/wiki/data This should be done in ALL computers.

6) Edit the Dokuwiki configuration file dokuwiki.php located in /etc/dokuwiki and change the value of the line $conf['savedir'] to the data location on the dropbox folder. In my case I changed the default value from $conf['savedir']=’/var/lib/dokuwiki/data'; to $conf['savedir']=’/home/primalcortex/Dropbox/wiki/data';

You must do this in all computers, only, probably, changing the Dropbox location. If you’re using the same username on all computers, just copy the file between them using Dropbox…

And that’s it. Accessing now the URL http://localhost/dokuwiki uses now the local lighttpd web server with all data synchronized between computers, and it works EVEN when offline. 

You now can invite your work colleagues to this folder, and have all data available at all times to anyone that uses the same scheme.

EDIT: You may find the following error when using the Wiki based on your Dropbox directory: The datadir (‘pages‘) does not exist, isn’t accessible or writable. You should check your config and permission settings.

The problem is file/directory permissions, because the user www-data used by lighttpd can’t access your home directory/Dropbox directory.

There are two solutions, being the easy one to add the www-data user to your own group, in my case the group named primalcortex.

The other solution is to add the following permissions: chmod o+x /home/username and chmod o+x/home/Dropbox

The first solution will be better because Dropbox software can or might change the Dropbox directory permissions. Just make sure that your home directory permissions are 750.

Kubuntu – Install ATI drivers

The complete instructions are here: http://wiki.cchtml.com/index.php/Ubuntu_Lucid_Installation_Guide

For Kubuntu just make sure that:

1) The proprietary driver is enabled/installed: alt-f2 and run jockey-kde (Additional drivers)

2) Add the X team PPA:

$ sudo add-apt-repository ppa:ubuntu-x-swat/x-updates
$ sudo apt-get update

3) Install the fglrx driver: sudo apt-get install fglrx

4) Initialize the ATI configuration:

sudo aticonfig –initial -f

In my case I’m using a dual monitor setup, and I did the above configuration and used the amdcccle configuration tool to setup the dual monitor. Please note that using Xinerama disables Desktop effects. If you want one large desktop choose the Multi-display Desktops. With this the desktop spawns the monitors and it’s possible to move windows between them.

5) Reboot.

If it fails to boot into graphical mode and/or it boots to VESA mode , go to safe mode and using the command jockey-text, make sure that the driver is enabled.

$ jockey-text -l
xorg:fglrx – ATI/AMD proprietary FGLRX graphics driver (Proprietary, Enabled, In use)

If the driver is disabled, enable it with the command: jockey-text -e xorg:fglrx

Kubuntu 10.04 to 10.10 upgrade

Since Kubuntu 8.04 that I’ve chosen to upgrade my installation instead of re-installing everything by scratch. One of the main reason is that I was to lazy to create a separated /home partition, and I really don’t want also to re-install all applications from scratch.

Most of the people that choose the upgrade path hit some issues that do not happen when doing a fresh install, and, yes, I hit some problems. Some problems are Kubuntu related and do not happen when using Ubuntu…

So the story:

Because my home machine has an ATI 4870 and I’m using the ATI proprietary driver, I wanted to make sure that my driver was up to date because Kubuntu 10.10 uses the latest Xorg…

So while still using 10.04 and the latest kernel available, I downloaded ATI driver 10.12 and it failed to install with the latest kernel.

This was problem number one: To cut a long story short the solution for this issue is here: http://primalcortex.wordpress.com/2010/12/29/kubuntu-install-ati-drivers

Anyway, for upgrading I went to Adept Installer, and on Sources->Edit Software Sources -> Updates changed the Release Upgrade to Normal Releases.

Sure enough, the 10.10 upgrade was offered.

Phase one: Upgrade stopped with error on log “Could not calculate upgrade-Can’t mark ‘kubuntu-desktop’ for upgrade“. It took me a while to find out that this was some meta package leftover from previous upgrades/installs that was not needed. So: apt-get remove kubuntu-desktop and this was the only package removed.

Phase two: Upgrade now stops with another weird error: could not install the upgrades – Couldn’t configure pre-depend x11-common for x11-xkb-utils, probably a dependency cycle

This took some time to solve and the solution is here: https://bugs.launchpad.net/ubuntu/+source/x11-xkb-utils/+bug/639933

Mainly is to do the following as root:

wget http://mirrors.kernel.org/ubuntu/pool/main/x/xorg/x11-common_7.5+6ubuntu3_all.deb
dpkg -i x11-common_7.5+6ubuntu3_all.deb

After this the upgrade ran without any problem.

At the end rebooted and: Despite of running Kubuntu the splash screen was of Ubuntu 10.10… Not nice.This is probably because I was running the command line upgrade tool do-release-upgrade? Not sure. Not important for now…

Boot proceed to fail completely into the text boot login… Oh boy… No graphical desktop no kde desktop no nothing. So I’ve logged in text mode with my credentials and “sudoed” to root (sudo bash)

Ok. Looking at the /var/log/Xorg.0.log file shows that the proprietary fglrx.ko module was not found. Ok, fair enough: The reason was that during the upgrade from 10.04 to 10.10 the kernel version changed, and the previous configuration was lost.

So I edit the /etc/apt/sources.lst and enabled all Kubuntu PPA’s and ubuntu-x-swat PPA. These where disabled during the upgrade, so I need now to enable them to get the latest KDE (4.5.4 at this date) and the ATI proprietary driver. The usual commands apt-get update, and apt-get upgrade and the new KDE and fglrx drivers is downloaded and installed.

Reboot

Still text mode… Xorg.0.log still complains that the fglrx driver is not installed…

Now what? I’ve installed the proprietary driver with jockey-kde which is a graphical utility, but now I don’t have no graphical environment…

The text only tool is jockey-text and running with the -l (that’s an l not an i) reports that the xorg:fglrx driver is DISABLED… ok, So:

jockey-text -e xorg:fglrx

enables the driver and then rebooting it solves the issue. Now I have a graphical KDE environment…

So what’s was broken during the upgrade?

hplip 3.10.2  – doesn’t work anymore: Can’t detect my c309g-m printer. Upgrading to hplip 3.10.9 solves the issue.

Akonadi Google plugins to synchronize calendar and contacts looks like it’s broken. I can’t see my Gcal events… Not sure if it’s related to the upgrade…

What’s new:

I’ve installed bluedevil to replace the old bluetooth software.

Boot times are faster

Fonts look much better.

Upgraded to Digikam 1.7

 

The final problem: At boot instead of having the Kubuntu splash screen, I have the Ubuntu pink/violet one… So I went to synaptic and removed the package plymouth-theme-ubuntu-logo e plymouth-theme-ubuntu-text leaving only the Kubuntu related ones.

Kmail/Korganizer and Nokia phone synchronization

When Nokia bought Trolltech, the makers of QT, one could assume that Nokia PC-Suite for Linux was on the horizon… But so far nothing has happened. So how do I synchronize my phone contacts and agenda with KDE software? Easy…

In my case I’m using KDE and Kmail/Korganizer, so the following post is how to accomplish this syncronization with Kmail address book and Korganizer Calendar using the Opensync syncronization framework. I’m using Opensync version that comes with Kubuntu 9.10, that’s 0.22.

Requirements: Latest KDE SC 4.4 release, a bluetooth dongle (in my case I’ll synchronize using BT), Akonadi and Kmail/Korganizer

1st) Make sure that your phone is detected. In my case it’s an Nokia 6280, and using one of these: http://www.dealextreme.com/details.dx/sku.11866 on my desktop PC, that works on Linux/Kubuntu 9.10 without any issue (and cheaper than this is probably impossible…):

Let’s see if the bluetooth dongle is detected: lsusb

Bus 008 Device 002: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)

Detected and Kbluetooth works, now execute the command: hcitool scan and the detected phones should appear:

Scanning ...
 00:3B:34:91:9A:56       Nokia 6280
 00:75:1F:88:08:AF       VF541

Take note of the hexadecimal address for the phones.

We also need to make sure that the phones do have the SyncML client, using the sdptool command browse: For example: sdptool browse 00:3B:34:91:9A:56

And on the output a section like this:

Service Name: SyncML Client
Service RecHandle: 0x1000e
Service Class ID List:
 UUID 128: 00000002-0000-1000-8000-0002ee000002
Protocol Descriptor List:
 "L2CAP" (0x0100)
 "RFCOMM" (0x0003)
 Channel: 11
 "OBEX" (0x0008)
Language Base Attr List:
 code_ISO639: 0x656e
 encoding:    0x6a
 base_offset: 0x100

should appear. In my case, only the Nokia 6280 has the SyncML client. The Vodafone 541 does not have this client so synchronization will be impossible. I also have a Nokia 2630, and it has BT and the SyncML client.

So you need now to take note of the following information: The phone address and the channel address of the SyncML client, in my example 11 (see above).


2nd) Make sure that you have the following msynctool plugins installed: file-sync and syncml-obex-client.

For that just execute the following command: msynctool –listplugins

If they are not available, install them using: sudo apt-get install opensync-plugin-file opensync-plugin-syncml

3rd) Create a directory on your home directory for storing information related to the synchronization. Please note that you never, EVER, should delete any information on this directory. If you do its the same as deleting data on the phone.

mkdir ~/nokiasync

4rd) Create the opensync syncronization configuration:

     msynctool --addgroup nokiasync
     msynctool --addmember nokiasync file-sync
     msynctool --addmember nokiasync syncml-obex-client

5th) Edit the configuration for each member of the synchronization group:

  • On the file-sync member we need to put the full path to the syn directory
  • On the syncml-obex client we need to put the MAC address of the phone (the hexadecimal numbers that we’ve found above) and the channel number.

So execute the following commands:

Edit the first member file-sync: msynctool –configure nokiasync 1

The text editor will show something like:

<config>
<path>/home/USERNAME/nokiasync</path>
<recursive>FALSE</recursive>
</config>

Make sure that USERNAME is your Linux username, namely bob, alice, whatever. A command like ls -l /home/USERNAME/nokiasync should return NO error.

Just press CTRL-X to exit and Y + ENTER to save.

Let’s configure now the Syncml client: msynctool –configure nokiasync 2

The file shown should look like:

<config>
<bluetooth_address>XX:XX:XX:XX:XX:XX</bluetooth_address>
<bluetooth_channel>YY</bluetooth_channel>
<identifier>PC Suite</identifier>

Just make sure that XX:XX… is EXACTLY your mobile phone address, and YY is the channel shown by the sdptool. In the above case it’s  00:3B:34:91:9A:56  and 11 respectively. So the file should look like:

<config>
<bluetooth_address>00:3B:34:91:9A:56</bluetooth_address>
<bluetooth_channel>11</bluetooth_channel>
<identifier>PC Suite</identifier>

Then CTRL-X, Y and Enter to save, and we are ready.

6th) Now is a good idea to backup your phone address list and agenda. Do it now! If things go wrong you need a backup. Also the first rule of good a good backup is that restores are more important than backups, so backup AND restore first so see IF you have a VALID backup. You’ve been warned… :)

7th) Now we are ready:

msynctool –sync nokiasync

Because I’m using bluetooth I’ll be asked for a PIN by my phone, and I’ll need to provide it to the PIN question dialog on the computer. After the pin, synchronization takes place, the first one is from the phone to the computer.

After this, on the directory nokiasync you should have some files. These files are your contacts and calendar from the mobile phone. DO NOT DELETE THEM.

8th) Akonadi configuration.

We need to configure Akonadi now. It’s quite easy. Just run akonaditray, and right click on the globe icon that appears on the KDE system tray, and select configure.

For the calendar:

  • On the Akonadi resources tab, press ADD and select the KDE Calendar (Traditional) plugin. A wizard will appear. Press next.
  • Then select more or less at the middle: Calendar in Local Directory and press Next
  • Give as the location the nokiasync directory that we’ve created, and where the opensync works for syncing with our mobile phone. Press Next
  • Give it a name, in my case Nokia Calendar, and press Finish.

OPTIONAL: For the Contacts (For reference only, Korganizer will not use this. See below) :

  • On the Akonadi resources tab, press ADD and select the KDE Adress book (Traditional) plugin. A wizard will appear. Press next.
  • Then select the first option: Folder and press Next
  • Give as the location the nokiasync directory that we’ve created, and where the opensync works for syncing with our mobile phone. Keep the format as vcard, and press Next
  • Give it a name, in my case Nokia Contacts, and press Finish.

That’s it. The akonadi resources are configured.

8th) Korganizer configuration.

For adding the calendar follow these instructions on this post: http://primalcortex.wordpress.com/2010/04/24/korganizer-and-google-calendar-on-kubuntu-9-10/ but instead of adding the Google resources add the Nokia Calendar resource

For the address book, just go to the Contacts section, and on the Address book, select Add Address Book with a right click on the mouse.

  • Select the KDE Adress book (Traditional) plugin. A wizard will appear. Press next.
  • Then select the first option: Folder and press Next
  • Give as the location the nokiasync directory that we’ve created, and where the opensync works for syncing with our mobile phone. Keep the format as vcard, and press Next
  • Give it a name, in my case Nokia Contacts, and press Finish.

And that’s it Nokia<->Korganizer syncronization…

9th) Testing:

Create a contact and a calendar event on Korganizer, but for the Nokia resources. Execute the synchronization command: msynctool –sync nokiasync

Your mobile phone should report that it synchronized 1 or two items. Check your contact list for the new contact. Check your agenda for the new event.

Now repeat the opposite: Create a phone contact and event, and synchronize. It should appear on Korganizer.

Last thoughts:

What happens if the syncronization directory is a sub-directory of your Dropbox folder…???? :-)

Automatic synchronization of all your agenda and contacts on all your computers! This in fact completely implements the purpose of plugins like akunambol and the Funambol server at this level of functionality…

You can now: Create a contact on your mobile phone, sync it, your local computer sees the change, but Dropbox also sees it sync’s it into the cloud, and into your other computers…

The phone synchronization ideas and howto’s where based on this post: http://www.harald-hoyer.de/linux/linux-and-syncml-multisync-with-nokia-6280

Finally, this also just brought to my ancient phone a new lease of life. No new Android phone for me… and by the way, after synchronization, the Nokia 6280 screensaver just fails to start…. and the Vodafone VF541 needed a restart… Nothing is perfect.

Korganizer and Google Calendar on Kubuntu 9.10

These are the simplest instructions for making Kmail/Korganizer to syncronize with Google Calendar.

What we will achieve with this setup: Two things:

  • Events created online on the Goggle Calendar will appear on your Korganizer interface
  • Events that you create on Korganizer associated to the Google Calendar provider will appear online on Google Calendar Web site

Instructions:

I’m running Kubuntu 9.10 with the latest KDE 4.4 release available from the backports.

First, install the akonadi-kde-resources-googledata: sudo apt-get install akonadi-kde-resource-googledata

Then we need start the Akonadi Configuration application:  ALT-F2 to show the run window, and the write akonadi and then the suggested akonadi configuration command  should appear. Another way, is to open a shell session and run akonaditray and a blue globe sould appear on the System Tray. Right click and select configure.

On the configuration Window, select ADD.

You should have the Akonadi Google Calendar Resource and Google Contact Resource. If these resources do not appear, you need to restart Akonadi, just go to the other tab Akonadi Server Configuration and hit the restart button.

Add these sources to your list of  Akonadi Resources, and make sure that you configure your username and password correctly. A green icon next to the resource will show that connection to Google is active. Right after the setting of your username and password, a rapid text message will show the synchronization process is going on.

Next we will need to configure Korganizer.

Open it up and make sure that you can see the window Calendars: The next screenshot already shows the configured calendar sources:

Press the green plus button, and select Akonadi.

On this window you can now add the sources that where configured previously on the akonadi configuration console. Give it a good name. In my case it’s Akonadi Resources, but if the only source is only the Google Calendar data, then a name like Google Calendar is good. This is because it will simplify the context menu for copying and moving, just like Copy -> Google Calendar instead of Copy -> Akonadi Resources like my case.

Add to this Akonadi Resource all the sources that you want to appear on Korganizer, namely the Google Calendar.

Press Ok, and that’s it.

All your Google Calendar Data should appear on your Korganizer.

For making an event from Korganizer  to appear on Gcal, just right click it and  select Copy or Move to the Akonadi Resource. then select the Google Calendar provider.

Thats’ it.

What we can do now:

Two things: Synchronize one way only the MS-Exchange Calendar with Korganizer. A nice solution is here: http://movingparts.net/2007/04/17/syncing-exchange-calendar-1-way-into-korganizerkontact/

Then (!) you can copy these events to Google Calendar… Cool

The other thing is to use OpenSync with akonadi to sync your mobile phone with Korganizer, but so far I haven’t try this.