Akonadi/da: Difference between revisions

From KDE UserBase Wiki
(Created page with "Hver datakilde-handler (kaldet en ressource) og hjælpeprogram (kaldet en agent) kan have sin egen konfiguration, selvom nogle agenter og ressourcer ikke behøver at konfigureres. Den generelle regel er, at for ethvert emne i ''$XDG_CONFIG_HOME/akonadi/agentsrc'' er der en tilsvarende konfigurationsfil i ''$XDG_CONFIG_HOME''. Hvis for eksempel afsnittet ''[Instances]'' i ''agentrc'' indeholder emnet ''akonadi_ical_resource_2'', så er der en konfigurationsfil ved navn ''...")
No edit summary
Line 4: Line 4:
==Introduktion==
==Introduktion==


<div class="mw-translate-fuzzy">
'''Akonadi''' giver programmer en centraliseret database til at gemme, indeksere og genfinde brugerens personlige information. Dette inkluderer emails, kontakter, kalendere, begivenheder, journaler, alarmer, noter osv.
'''Akonadi''' giver programmer en centraliseret database til at gemme, indeksere og genfinde brugerens personlige information. Dette inkluderer emails, kontakter, kalendere, begivenheder, journaler, alarmer, noter osv. I KDE SC 4.4 blev '''KAddressBook''' det første program, som anvendte '''Akonadi'''. I SC 4.7 er [[Special:myLanguage/KMail|KMail]], [[Special:myLanguage/KOrganizer|KOrganizer]], [[Special:myLanguage/KJots|KJots]] med flere også blevet opdateret til at bruge '''Akonadi'''. Der er også adskillige [[Special:myLanguage/Plasma|Plasma]]-widgets, som bruger '''Akonadi''' til at gemme og hent kalenderbegivenheder, noter etc.
</div>


Currently, all [https://kontact.kde.org/ KDE PIM applications] with the exception of [[Special:myLanguage/Akregator|Akregator]] are using '''Akonadi''' to access user's PIM data.
Currently, all [https://kontact.kde.org/ KDE PIM applications] with the exception of [[Special:myLanguage/Akregator|Akregator]] are using '''Akonadi''' to access user's PIM data.

Revision as of 13:52, 6 December 2023

Introduktion

Akonadi giver programmer en centraliseret database til at gemme, indeksere og genfinde brugerens personlige information. Dette inkluderer emails, kontakter, kalendere, begivenheder, journaler, alarmer, noter osv.

Currently, all KDE PIM applications with the exception of Akregator are using Akonadi to access user's PIM data.

Kontrol af Akonadis server

Akonadi will start automatically in the background when any application using it is started.

To manually start, stop or restart Akonadi, you can use the akonadictl command from the commandline. Using this method, you can get additional useful information on the console.

For at starte Akonadis server,

akonadictl start

For at stoppe Akonadis server,

akonadictl stop

For at genstarte Akonadis server, hvis den allerede kører

akonadictl restart

For at få vist status for Akonadis server,

akonadictl status

Deaktivering af Akonadis undersystem

Akonadi-serveren startes af ethvert program, som kan bruge Akonadi. Hvis du ikke ønsker at starte Akonadi efter indlogning, så skal du sørge for, at intet program som bruger Akonadi startes ved indlogning eller senere. Husk også at tjekke Plasma-widgets — for eksempel bruger Digitalt ur i standardpanelet Akonadi til (valgfrit) at vise kalenderbegivenheder og dette er aktiveret i widgetets indstillinger som standard (tilvalget Vis begivenheder). Du skal fjerne alle de widgets som kan starte Akonadi fra din opstart, hvis du kun vil have Akonadi til at starte op når du starter KMail og lignende programmer.

Husk!

Hvis du ikke ønsker at have Akonadi til at køre på dit system under nogen omstændigheder, så kan du ikke bruge de programmer, som benytter sig af Akonadi. Sådanne programmer fungerer ikke når Akonadi er blevet deaktiveret ved at følge fremgangsmåden herunder. Se listen med programmer, som bruger Akonadi. Bemærk også, at nogle Plasma-widgets, så som Digitalt ur bruger Akonadi.


For at sikre, at Akonadi ikke startes skal du tjekke, at der ikke er nogen programmer, som her brug for den ved indlogning. Specielt skal du åbne indstillingerne for Plasmas ur-applet, gå til Kalender og fravælge Vis begivenheder for at forhindre at Plasma beder om information fra Akonadi og således får startet den.

Nogle definitioner

Egentlige data
Ved egentlige data forstår vi data som kontakter eller begivenheder. Disse data gemmes enten på en groupware-server eller i en lokal fil; præcis hvor afhænger af, hvilken ressource, du bruger. Ressourcen Personal Contacts gemmer fx sine data i $HOME/.local/share/contacts.
Cachede data
De cachede data er kopier af de egentlige data, som gemmes i databasen for hurtigere tilgang og offline opbevaring. Databasen indeholder også metadata, som er administrative data, som Akonadi behøver for at fungere korrekt.
Konfigurationsdata
Ved konfigurationsdata forstås de data, som konfigurerer Akonadi-serveren og de enkelte ressourcer. Serverens konfigurationsdata kan findes under $XDG_CONFIG_HOME/akonadi, mens ressourcernes konfigurationsdata for gemmes i $XDG_CONFIG_HOME/akonadi_xyz_resourcerc# (hvor xyz er ressourcens navn og # er et løbenummer).
The Akonadi server configuration is a couple of files in $XDG_CONFIG_HOME/akonadi. It contains which data sources and helper programs are active and will be started and watched (so they can be restarted on crashes) by one of Akonadi's server processes (akonadi_control).

Hver datakilde-handler (kaldet en ressource) og hjælpeprogram (kaldet en agent) kan have sin egen konfiguration, selvom nogle agenter og ressourcer ikke behøver at konfigureres. Den generelle regel er, at for ethvert emne i $XDG_CONFIG_HOME/akonadi/agentsrc er der en tilsvarende konfigurationsfil i $XDG_CONFIG_HOME. Hvis for eksempel afsnittet [Instances] i agentrc indeholder emnet akonadi_ical_resource_2, så er der en konfigurationsfil ved navn akonadi_ical_resource_2rc-- i mappen $XDG_CONFIG_HOME.

Depending on the type of data, such config files for resources will have filenames or directory names of where the data is stored. Common locations are KDE's legacy default files, e.g. $HOME/.kde/share/apps/korganizer/std.ics. New default locations are files and directories in $XDG_DATA_HOME, e.g. $XDG_DATA_HOME/contacts.

Backup

So now we need to decide what to back up. If you want to backup the "real data", then it depends on the resources you have configured... if you use a groupware server, then the backup should be done there. For contacts, the files under $XDG_DATA_HOME/contacts will normally be what you need.

To back up the entire Akonadi configuration, including which resources are active and their configuration, you can use the pimdataexporter' tool. This, however doesn't back up the Akonadi database containing the cached data and, unfortunately, after restoring the configuration (using the pimdataexporter again), Akonadi will have to re-fetch all data again into its cache. This can cause configuration that points to actual mail folders or calendars to get broken and accidentally point to another folder.

After restoring configuration and syncing all data, it's vital to manually check all folder configuration, especially in KMail identities and make sure the folders are configured properly.

Ofte stillede spørgsmål

Hvor er mine data nu?

Your data are safely stored outside of Akonadi control on your disk (e.g. local maildir folder or iCal calendar), or on a remote server (in case of e.g. email over IMAP or events from a CalDAV calendar). Akonadi will optionally store a copy of this data in its database to allow applications to quickly retrieve and display them. Any modifications done to data in the Akonadi database will be synced to the actual storage. The main advantage of using the database as a cache is that remote PIM data are available even when you are offline, and you can still interact with them (e.g. mark emails as read or move them, create new events, reschedule existing meetings etc.) and all the changes will get synced automatically once you connect to the internet again.

Thus, deleting the Akonadi database will not cause any data to be lost (as long as all pending changes are synced).

Hvordan opgraderer jeg min PostgreSQL-database?

Efter en opdatering af din PostgreSQL-server til et nyt hovedversionsnummer er det undertiden nødvendigt at konvertere din Akonadi-database til brug med den nye udgave. Instruktioner kan findes på denne side.

Problemer med overgang til Akonadi

Akonadis opslag i ordbogen har en kort beskrivelse af dens formål og andre nyttige links. Denne side forklarer hvordan Akonadi og KAddressBook arbejder sammen.

How do I switch from MySQL/PostgreSQL to SQLite?

Currently, the only option is to delete all Akonadi configuration and data, configure Akonadi to use SQLite and then configure all the resources and agents from scratch. This also involves checking all application (KMail, KOrganizer, KAddressbook, etc.) configuration, as all references to folders (like configuration of Trash or Sent folders, default calendar etc.) will most likely be wrong now.

To perform the migration, quit all PIM applications and stop Akonadi from command line:

akonadictl stop

Then, delete all Akonadi-related configuration and data directories and files:

  • Delete Akonadi configuration: $XDG_CONFIG_HOME/akonadi
  • Delete Akonadi database: $XDG_DATA_HOME/akonadi
  • Delete configuration of all Akonadi resources: $XDG_CONFIG_HOME/akonadi*
  • Delete data of all Akonadi resources: $XDG_DATA_HOME/akonadi*

($XDG_CONFIG_HOME defaults to $HOME/.config when not set, $XDG_DATA_HOME defaults to $HOME/.local/share.)

Now, create a new Akonadi Server configuration file called akonadiserverrc in $HOME/.config/akonadi/ with the following contents:

[%General]
Driver=QSQLITE

This will instruct Akonadi to use SQLite instead of the default (usually MySQL). Finally, you can start Akonadi (via akonadictl or simply by starting some Akonadi-enabled application) and update configuration of your PIM application.

This guide can also be used to switch to MySQL or PostgreSQL databases. To switch to MySQL put Driver=QMYSQL into akonadiserverrc. In order to use PostgreSQL, put Driver=QPSQL in there.