Hello Bruno,

you are asking how to change the Quota database format or how to change
the quota database with any format.

With
https://www.cyrusimap.org/imap/reference/manpages/systemcommands/cyradm.html
it is possible to use the setquota command to set quota and listquota
to get quota.  Cyradm generates IMAP commands.  You can check the
source code to see what command can be sent over IMAP by an
administrator to get or set quotas.

About converting the database to a different(SQL) format, the
imapd.conf file
https://www.cyrusimap.org/3.4/imap/reference/manpages/configs/imapd.conf.html
provides information about:

* the used quota database format in `quota_db`
* the location of the quota database in `quota_db_path`

With cvt_cyrusdb the database format can be changed for the quota
database to something different, like sql.

The workflow is:
* You have a quota database, defined by quota_db and quota_db_path
* You convert with cvt_cyrusdb the available database (fixed in
quota_db and quota_db_path) to something different
• You change in imapd.conf the values of quota_db and quota_db_path to
the new values.

Restarting the processes at the end with SIGHUP shall be sufficient,
the change should be possible on a running system.

Greetings
  Dilyan

On Fri, 2021-12-24 at 05:56 -0500, Bruno Thomas via Devel wrote:
> Hello mailers,
> 
> 
> We are currently migrating our small service (iroco.co) from dovecot
> to cyrus, mostly for efficiency reasons : with this study :
> https://greenlab.di.uminho.pt/wp-content/uploads/2017/10/sleFinal.pdf
> we can see that C is still the most effective language, and cyrus is
> doing a great job gathering IMAP/JMAP/CalDAV/CardDAV... around the
> same data stores (no need to duplicate/proxy or whatever). Thanks for
> all the code, specifications (JMAP), documentations and thoughts. It
> is a great digital common and we hope that we will be able to
> contribute in return.
> 
> We have currently only one server and several domains (there could be
> customs, and we didn't want to "specialize" the servers by domain),
> so we deployed a SNI/TLS proxy termination with HAproxy (that we will
> document). Before, we were using a small Svelte webapp that was
> sharing a postgresql database with dovecot (setting the quota was
> made by the webapp, updating the DB). So we've chosen to use SQL
> backend with cyrus also, thinking that we could "share" information &
> state.
> 
> For example, we wanted to update the quota value for an account, and
> we've seen that the content of the db is encoded. We then thought
> that we could decode and set a new value. But was it the proper way
> of doing so ?
> 
> We tried with cyr_dbtool but we have to provide a file, we tried with
> /dbname/quota_db but it didn't make it.
> 
> Does that architecture make sense or do we twist the cyrus ecosystem
> design? If so how our webapp could interact with cyrus admin tasks ? 
> We've seen this draft for quotas, is it the way of doing quota change
> ? 
> 
> Thanks for your advises and happy Christmas eve.
> 
> Bruno Thomas
> 
> Cyrus / Devel / seediscussions +participants
> +delivery optionsPermalink

------------------------------------------
Cyrus: Devel
Permalink: 
https://cyrus.topicbox.com/groups/devel/T034a11289ee47103-M119ef1a2270e87d40ad97b1e
Delivery options: https://cyrus.topicbox.com/groups/devel/subscription

Reply via email to