This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Automatically enable/disable akonadi

Tags: None
(comma "," separated)
Shark82
Registered Member
Posts
60
Karma
0
OS
Hi

I am wondering if there is any way to automatically enable/disable akonadi. So if i close all PIM applications akonadi will automatically disable. I know i could write a script but i am wondering if there is any built-in option in akonadi. I haven't found yet.

Thanks!
Minio
Registered Member
Posts
177
Karma
1
OS
Calendar widget populates dates with events from akonadi calendar resource (since 4.7 or something). It will work without Akonadi, but from that point of view, Akonadi is needed as long as you use calendar widget. This is virtually every second you are using KDE Plasma.
To clarify things: I am talking about calendar that shows up when you click on default clock widget. There are bunch of clock widgets, so maybe other behave different.

I think writing a script that would stop Akonadi when none of certain processes is running will be much easier. I believe that KDE PIM apps will automatically start Akonadi if it is stopped, so you only have to worry about stopping it.


Best regards
Mirosław Zalewski
Shark82
Registered Member
Posts
60
Karma
0
OS
Thanks for info.
I have written a script and so far is working. For now i use script only for kmail and kalarm. I am annoyed by akonadi running when i don't use kmail or kalarm (these are only PIM apps i use) - akonadi uses 100 MB od RAM. If anyone interested, my script:
Code: Select all
while true; do
[[ $(ps -e | grep kmail) || $(ps -e | grep kalarm) ]]
if [[ "$?" != 0 ]]
then akonadictl stop
fi
sleep 60s
done

Last edited by Shark82 on Fri Jul 13, 2012 10:40 am, edited 1 time in total.
User avatar
einar
Administrator
Posts
3402
Karma
7
OS
Minio wrote:Calendar widget populates dates with events from akonadi calendar resource (since 4.7 or something). It will work without Akonadi, but from that point of view, Akonadi is needed as long as you use calendar widget. This is virtually every second you are using KDE Plasma..


That's not correct. Uncheck "show events" in the calendar widget's configuration and it won't use Akonadi.


"Violence is the last refuge of the incompetent."
Image
Plasma FAQ maintainer - Plasma programming with Python
Minio
Registered Member
Posts
177
Karma
1
OS
einar: yes. I forgot "default" part - it by default populates events from Akonadi calendar resource (if it exists, of course). You can turn it off. And, as I noted, it will work perfectly fine when Akonadi is stopped.
But anyway, thanks for correcting my mistake.


Best regards
Mirosław Zalewski
User avatar
einar
Administrator
Posts
3402
Karma
7
OS
Actually the "default" is what upstream KDE supplies, some distros (openSUSE but likely others) put it to disabled by default (especially on live CDs).


"Violence is the last refuge of the incompetent."
Image
Plasma FAQ maintainer - Plasma programming with Python


Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], Google [Bot]