Displaying 4 results from an estimated 4 matches for "quota_name_storage".
2006 Jun 20
1
Group-based filesystem quota
Hello. After using Dovecot for over a year, I have just started
experimenting with the filesystem quotas, and I have a suggestion for
improvement. On my mail server, I use group-based quotas, and would
like to have Dovecot be able to report these quotas.
It should be simple to implement, requiring only changes to the
quota-fs.c file of the quota plugin. Simply changing USRQUOTA to
2006 Aug 21
2
Filesystem Quota Enhancement Patch
...dup(name);
root->root.v = quota_backend_fs.v;
root->uid = geteuid();
+ root->gid = getegid();
return &root->root;
}
@@ -177,7 +179,16 @@
static const char *const *
fs_quota_root_get_resources(struct quota_root *root __attr_unused__)
{
- static const char *resources[] = { QUOTA_NAME_STORAGE, NULL };
+ const char *mail;
+ mail = getenv("MAIL");
+ static const char *resources[] = {
+ QUOTA_NAME_STORAGE,
+ NULL,
+ NULL
+ };
+ if (strstr(mail, "maildir") != NULL) {
+ resources[1] = QUOTA_NAME_MESSAGES;
+ }
return resources;
}
@@ -192,82 +203,108 @@
struct qu...
2006 Apr 14
0
Quota again
...(uint64_t)root->mount->blk_size / 1024;
+ (uint64_t)root->mount->blk_size / 1024 / 4;
return 1;
}
--- quota-maildir.c.old 2006-04-14 22:46:17.000000000 +0200
+++ quota-maildir.c 2006-04-14 13:56:02.000000000 +0200
@@ -597,7 +597,7 @@
if (strcmp(name, QUOTA_NAME_STORAGE) == 0) {
*limit_r = root->message_bytes_limit / 1024;
- *value_r = root->total_bytes / 1024;
+ *value_r = root->total_bytes / 10;
} else if (strcmp(name, QUOTA_NAME_MESSAGES) == 0) {
*limit_r = root->message_count_limit...
2006 Feb 03
0
rquotad (NFS) quota plugin
...es[0] = NULL;
+ return root->resources;
+ }
+ /* Out of date is alright, we don't really care about up-to-date
+ * numbers, just whether quotas are active */
+ root->resources = p_new(root->pool, const char *, 3);
+ if (root->kbyte_limit != 0) {
+ root->resources[i++] = QUOTA_NAME_STORAGE;
+ }
+ if (root->inode_limit != 0) {
+ root->resources[i++] = QUOTA_NAME_MESSAGES;
+ }
+ root->resources[i] = NULL;
+
+ return root->resources;
+ }
+
+ static int
+ rquotad_quota_root_create(struct quota *_quota,
+ const char *name __attr_unused__,
+ struct quota_root...