Re: cyrus 2.5 imap idle/stuck connections (DOS like)
My "man imapd.conf" doesn't list this option at all. I think my Cyrus 2.5.10 is older than it.. But I've added it to the .conf anyway. Won't hurt if it doesn't exist yet, right? lol Atenciosamente, Heiler Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Em 07/03/2019 11:58, Wolfgang Breyha escreveu: Heiler Bemerguy via Info-cyrus wrote on 07/03/2019 15:39: Yes I've read imapd.conf and cyrus.conf and found no options to limit connections per source IP or "idleness".. It means anyone can open a lot of connections to any port (143, 25, 110 etc) and render the server unusable?? You can try to set imapidletimeout: as documented in "man imapd.conf". To keep your server "RFC friendly" this value should not be lower than 30 minutes, because RFC 2177:3. recommends that clients show activity at least every 29 minutes. Greetings, Wolfgang Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: cyrus 2.5 imap idle/stuck connections (DOS like)
Thank you very much, it worked perfectly. Best Regards, Heiler Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Em 07/03/2019 11:55, Ivan Kuznetsov escreveu: Hello iptables -A INPUT -p tcp --syn --dport 143 -m connlimit --connlimit-above 8 -j REJECT This will limit established imap connections to 8 per ip 07.03.2019 17:39, Heiler Bemerguy via Info-cyrus пишет: Yes I've read imapd.conf and cyrus.conf and found no options to limit connections per source IP or "idleness".. It means anyone can open a lot of connections to any port (143, 25, 110 etc) and render the server unusable?? I'm using Debian, so I'll try to figure out how to do that with iptables.. Thanks! Best Regards, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Em 07/03/2019 11:25, Willem Offermans escreveu: Dear Cyrus friends and Heiler Bensimon Bemerguy, You could use your firewall to achieve this. For ipfw: ${fwcmd} add pass tcp from any to ${ip_me} imap setup limit src-addr 10 You have to lookup the right syntax for your firewall. Dit you check man imapd or man cyrus, maybe there is also an option for the daemon itself, but I would prefer the firewall. Wiel Offermans wil...@offermans.rompen.nl <mailto:wil...@offermans.rompen.nl> On 7 Mar 2019, at 14:53, Heiler Bemerguy via Info-cyrus <mailto:info-cyrus@lists.andrew.cmu.edu>> wrote: Hail, I've noticed an user with ~200 open connections to cyrus imap port (143) and, because of him, no one else could login to the server. I've noticed even with a single "telnet ip 143", the connection is accepted and never ever dropped, even while still unauthenticated. How to stop that from happening? cyrus.conf: imap cmd="imapd -U 30" listen="imap" prefork=6 maxchild=200 -- Atenciosamente, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: cyrus 2.5 imap idle/stuck connections (DOS like)
Yes I've read imapd.conf and cyrus.conf and found no options to limit connections per source IP or "idleness".. It means anyone can open a lot of connections to any port (143, 25, 110 etc) and render the server unusable?? I'm using Debian, so I'll try to figure out how to do that with iptables.. Thanks! Best Regards, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Em 07/03/2019 11:25, Willem Offermans escreveu: Dear Cyrus friends and Heiler Bensimon Bemerguy, You could use your firewall to achieve this. For ipfw: ${fwcmd} add pass tcp from any to ${ip_me} imap setup limit src-addr 10 You have to lookup the right syntax for your firewall. Dit you check man imapd or man cyrus, maybe there is also an option for the daemon itself, but I would prefer the firewall. Wiel Offermans wil...@offermans.rompen.nl On 7 Mar 2019, at 14:53, Heiler Bemerguy via Info-cyrus <info-cyrus@lists.andrew.cmu.edu> wrote: Hail, I've noticed an user with ~200 open connections to cyrus imap port (143) and, because of him, no one else could login to the server. I've noticed even with a single "telnet ip 143", the connection is accepted and never ever dropped, even while still unauthenticated. How to stop that from happening? cyrus.conf: imap cmd="imapd -U 30" listen="imap" prefork=6 maxchild=200 -- Atenciosamente, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
HELP: Can't fix quota, it seems renamed-back mailbox doesn't exists at all
Hail, this is a Cyrus 2.5.10-3 on Debian 9 A mailbox was accidentaly deleted, as the log shows: Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque -> DELETED.user.planejamento^funbosque.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque.Drafts -> DELETED.user.planejamento^funbosque.Drafts.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque.Drafts Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque.Junk -> DELETED.user.planejamento^funbosque.Junk.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque.Junk Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque.Sent -> DELETED.user.planejamento^funbosque.Sent.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque.Sent Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque.Spam -> DELETED.user.planejamento^funbosque.Spam.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque.Spam Dec 4 11:56:42 localhost cyrus/imap[27354]: Rename: user.planejamento^funbosque.Trash -> DELETED.user.planejamento^funbosque.Trash.5C0695AA Dec 4 11:56:42 localhost cyrus/imap[27354]: Deleted mailbox user.planejamento^funbosque.Trash I renamed it back to try to recover it, manually with cyradm: Dec 4 12:59:38 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.5C0695AA -> user.planejamento^funbosque Dec 4 12:59:38 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.5C0695AA Dec 4 13:02:03 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.Drafts.5C0695AA -> user.planejamento^funbosque.Drafts Dec 4 13:02:03 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.Drafts.5C0695AA Dec 4 13:02:27 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.Junk.5C0695AA -> user.planejamento^funbosque.Junk Dec 4 13:02:27 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.Junk.5C0695AA Dec 4 13:02:54 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.Sent.5C0695AA -> user.planejamento^funbosque.Sent Dec 4 13:02:54 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.Sent.5C0695AA Dec 4 13:03:20 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.Spam.5C0695AA -> user.planejamento^funbosque.Spam Dec 4 13:03:20 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.Spam.5C0695AA Dec 4 13:04:18 localhost cyrus/imap[39601]: Rename: DELETED.user.planejamento^funbosque.Trash.5C0695AA -> user.planejamento^funbosque.Trash Dec 4 13:04:18 localhost cyrus/imap[39601]: Deleted mailbox DELETED.user.planejamento^funbosque.Trash.5C0695AA All the files are there on the filesystem, but the quota usage isn't right. I've already tried cyrus reconstruct -r -f user/planejamento^funbosque cyrus quota -f user/planejamento^funbosque cyrus quota -f user/planejamento.funbosque And a full "cyrus check" with no luck.. The command LQ simply shows nothing. Like this: 127.0.0.1> lq user/planejamento.funbosque Any ideas?! root@mailer:/var/spool/cyrus/mail/p/user/planejamento^funbosque# cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew 3e5650f459303706 $MDNSent $Forwarded planejamento.funbosque lrswipkxtecdan root@mailer:/var/spool/cyrus/mail/p/user/planejamento^funbosque# du -hs 570M . -- Atenciosamente, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: Moving from single to multi-domain. Mailboxes from default domain not being the same as before
Em 16/07/2018 22:55, ellie timoney escreveu: Or do you want accounts in different domains to be not related to each other? (e.g. "a...@foo.com" and "a...@bar.com" are two totally different accounts) In either case, I would think about having one LDAP attribute (single-value, unique) to represent a user's "primary" email address, and a separate LDAP attribute (multi-value, unique) to represent their "aliases". You would set up Cyrus to only consider the "primary" attribute, and then set up your SMTP server to deliver email destined for "alias" addresses to the "primary" address for the matching account. I believe this is a common enough configuration that it shouldn't be hard to find information online. I have managed (non-Cyrus) systems that worked like this in the past, but it was a long time ago so I can't offer much specific help. humm. so the existing "mail" field on ldap would always contain the @defaultdomain (as setup on cyrus), but another field for aliases where Postfix would look up?! The "mail" attribute wouldn't need to always contain the @defaultdomain, but it would always need to match the account that Cyrus knows about. And then the aliases attribute (I've seen "mailalternateaddress" used for this) would contain any other addresses that need to deliver to the same account. Right now Cyrus is using mailboxes without any domain.. just a plain "/var/spool/cyrus/mail/h/user/heiler^bemerguy".. defaultdomain is just for telling Cyrus what to assume when no domain is specified, none of your accounts need to actually use it, and in fact this domain doesn't even need to exist (unless accounts use it). At FastMail, I believe our defaultdomain is set to some nonsense value like "internal" or "invalid" or something, which none of our accounts use, and the side effect of this is that every account must always have a (real) domain explicitly specified. I'd recommend doing something similar, just to avoid confusion from Cyrus making assumptions. Basically what I'm saying here is, if you: * set it up in LDAP so that each account has exactly one "mail" attribute which matches their Cyrus account, and as many aliases as they need, and I think this will be the problem. Our ldap's "mail" attribute is mixed with @cinbesa.com.br or @belem.pa.gov.br.. but as our saslauth ldap_filter uses UID instead of MAIL for searching accounts they all use the same mailbox! If I change that to use the "mail" attribute instead, and the "mail" attribute is @defaultdomain, it will work, but if it's not, it will create another mailbox.. I don't know how can I write a ldap_filter to return only uid in that case. Or should I rewrite all users' "mail" attribute that are using domain aliases? * set up Postfix to handle the alias rewriting on delivery, and * set up Cyrus to look up the "mail" attribute (only) for authentication (as you have already done), and if necessary, instruct your users to use their full "mail" address as their login name then: * your defaultdomain doesn't really matter, because everything in Cyrus will use the full "mail" address, and * Cyrus won't autocreate multiple inboxes for people, because it never sees their aliases If you provide a webmail interface to your users, it will also need to know about their LDAP attributes so that they can send mail "from" an alias if they need to. But if your users just use IMAP, they can just be set up in the client. We use a roundcube Webmail, which uses smtp to send emails.. As for autocreate, it is not compiled in by default, it needs to be turned on at build time with the --enable-autocreate argument to configure. If you installed Cyrus from a distribution, your distribution may have done this for you. If you don't want to recompile to remove the feature, you can control it using the autocreate_* options in imapd.conf (see man
Re: Moving from single to multi-domain. Mailboxes from default domain not being the same as before
Em 06/07/2018 00:10, ellie timoney escreveu: Hi, The "defaultdomain" is the domain that's assumed by Cyrus for users that are uid only. Any other domain needs to be explicitly specified in the user (this applies to login, delivery, etc). So, if you have: defaultdomain: foo.com then "user" and "u...@foo.com" are the same account (and can login using either variation), but "u...@bar.com" is some other account and can only login as "u...@bar.com". It's not clear to me how you wish to use the extra domains. Do you want your existing users to be able to send/receive from multiple different domains? (e.g. user "anne" has both email addresses "a...@foo.com", "a...@bar.com"). We used to have some domains that represented the same mailbox. Like @cinbesa.com.br being the same as @belem.pa.gov.br.. but now we want to create some other domains (while *maintaining* those we already had), which will point to totally different mailboxes, like @semad.belem.pa.gov.br and @sesma.belem.pa.gov.br :) Or do you want accounts in different domains to be not related to each other? (e.g. "a...@foo.com" and "a...@bar.com" are two totally different accounts) In either case, I would think about having one LDAP attribute (single-value, unique) to represent a user's "primary" email address, and a separate LDAP attribute (multi-value, unique) to represent their "aliases". You would set up Cyrus to only consider the "primary" attribute, and then set up your SMTP server to deliver email destined for "alias" addresses to the "primary" address for the matching account. I believe this is a common enough configuration that it shouldn't be hard to find information online. I have managed (non-Cyrus) systems that worked like this in the past, but it was a long time ago so I can't offer much specific help. humm. so the existing "mail" field on ldap would always contain the @defaultdomain (as setup on cyrus), but another field for aliases where Postfix would look up?! As for autocreate, it is not compiled in by default, it needs to be turned on at build time with the --enable-autocreate argument to configure. If you installed Cyrus from a distribution, your distribution may have done this for you. If you don't want to recompile to remove the feature, you can control it using the autocreate_* options in imapd.conf (see man imapd.conf.5). For example you should be able to use "autocreate_users" to limit it only to certain LDAP groups rather than every valid login (if that is useful to you). But if you set up your LDAP directory and Cyrus such that each user only has a single "primary" email address that they can use in Cyrus, and map delivery to aliases outside of Cyrus, then people won't be able to login with the "wrong" alias, and therefore autocreate won't accidentally make new accounts for them. :) Right now I think they can login with the "uid" only OR with the complete mail ("mail" field) -- Atenciosamente, Heiler Bensimon Bemerguy - CINBESA Analista de Redes, Wi-Fi, Virtualização e Serviços Internet (55) 91 98151-4894 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: Moving from single to multi-domain. Mailboxes from default domain not being the same as before
Hi, Yeah "virtdomains" is set to "userid". The "defaultdomain" was commented out. By setting it to "ourcompany.com.br", it prevented the creation of another mailbox inside "domain/o/ourcompany.com.br" sucessfully, thanks. But now I got another problem. We used to have other "default" domains like that. Like "companyalias.com.br", "companyalias2.com.br"... So is there a way to use more than one "defaultdomain", to block the creation of redundant mailboxes..? Em 04/07/2018 11:48, Vladislav Kurz escreveu: On 07/04/18 16:37, Heiler Bemerguy via Info-cyrus wrote: *The problem is:* When I authenticate with @ourcompany.com.br, it auto-creates *another *mailbox (//var/spool/cyrus/mail/domain/o/ourcompany.com.br/h/user/heiler^bemerguy//). As the "ourcompany.com.br" is the default domain, it would be better (and a lot less troublesome) if it continued to use the old "//var/spool/cyrus/mail/h/user/heiler^bemerguy" /mailbox/./ *Is it possible*? Did you set imapd.conf properly? Try this: virtdomains: userid defaultdomain: ourcompany.com.br We used that when moving to multidomain system, but we used SASLDB as backend (not LDAP). Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: please HELP
I'm trying to fix the mailboxes with something like this: imap_setacl ($mbox, "user/".$argv[1]."/*", $wrongname."todelete", ""); imap_setacl ($mbox, "user/".$argv[1]."/*", $argv[1], "lrswipkxtea"); But it seems imap_setacl can't use wildcards. And I can't write one by one by hand. Anyone can help me with that? The full php script is below: exit( "Usage: ./rename.php LOGIN (without TODELETE)\nUse ^ instead of DOTS\n\n" ); } $mbox = imap_open("{localhost:143/novalidate-cert}", "admin", "", OP_HALFOPEN) or die("can't connect: " . imap_last_error()); imap_renamemailbox($mbox, "{localhost:143}user/".$argv[1]."TODELETE", "{localhost:143}user/".$argv[1]) or die("can't rename, already exists?: " . imap_last_error()); $wrongname = str_replace("^", ".", $argv[1]); imap_setacl ($mbox, "user/".$argv[1], $wrongname."todelete", "") or print("can't remove $wrongname todelete of $argv[1]\n"); imap_setacl ($mbox, "user/".$argv[1]."/*", $wrongname."todelete", "") or print("can't remove $wrongname todelete of $argv[1]/*\n"); imap_setacl ($mbox, "user/".$argv[1], $argv[1], "lrswipkxtea") or print("can't set $argv[1] with lrswipkxtea into $argv[1]\n"); imap_setacl ($mbox, "user/".$argv[1]."/*", $argv[1], "lrswipkxtea") or print("can't set $argv[1] with lrswipkxtea into $argv[1]/*\n"); imap_close($mbox); shell_exec("cyrus reconstruct -x -r -f user/".$argv[1]); ?> -- Atenciosamente / Best Regards, Heiler Bemerguy Network Manager - CINBESA 55 91 98151-4894/3184-1751 Em 22/01/2018 22:09, Patrick Boutilier escreveu: On 01/22/2018 07:55 PM, Heiler Bemerguy via Info-cyrus wrote: The way I interpret it is that the / means unixhierarchysep is on. Just tested this on 2.4.18 and the same thing happens. When you rename back no messages are listed and reconstruct does nothing. Ah. As suspected the rights are wrong. You just need to set the rights back to the real user. You probably need to use / instead of . localhost> lam user.test testtodelete lrswipkxtecda localhost> sam user.test test lrswipkxtecda localhost> lam user.test testtodelete lrswipkxtecda test lrswipkxtecda localhost> sam user.test testtodelete '' localhost> lam user.test test lrswipkxtecda localhost> lam user/asaude asaudetodelete lrswipkxtecda localhost> lam user/ana^claudia ana.claudiatodelete lrswipkxtecda localhost> OMG it's completely borked. Why did it happen? How it changed to "TODELETE" but didn't change back hours later?!? Just looks like a bug. Maybe was the capital letters?! Yup. I tested and using capital letters causes this behaviour. Then I'll have to change one by one? with "sam"? Could you please explain what you did? I understood the LAMs but didn't the SAMs lol it seems in your case you had two acls?! a right and a wrong? You will have to change the rights somehow. Should be able to do it with a PHP or perl script. Correct, need to remove the wrong ACL and put the correct one on. For example: sam user/asaude asaudetodelete '' sam user/asaude asaude lrswipkxtecda First sam deletes the wrong ACL, second sam adds the correct one. Of course those only get the InBox. For folders you will have to also do something like: sam user/asaude/* asaudetodelete '' sam user/asaude/* asaude lrswipkxtecda Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: please HELP
The way I interpret it is that the / means unixhierarchysep is on. Just tested this on 2.4.18 and the same thing happens. When you rename back no messages are listed and reconstruct does nothing. Ah. As suspected the rights are wrong. You just need to set the rights back to the real user. You probably need to use / instead of . localhost> lam user.test testtodelete lrswipkxtecda localhost> sam user.test test lrswipkxtecda localhost> lam user.test testtodelete lrswipkxtecda test lrswipkxtecda localhost> sam user.test testtodelete '' localhost> lam user.test test lrswipkxtecda localhost> lam user/asaude asaudetodelete lrswipkxtecda localhost> lam user/ana^claudia ana.claudiatodelete lrswipkxtecda localhost> OMG it's completely borked. Why did it happen? How it changed to "TODELETE" but didn't change back hours later?!? Maybe was the capital letters?! Then I'll have to change one by one? with "sam"? Could you please explain what you did? I understood the LAMs but didn't the SAMs lol it seems in your case you had two acls?! a right and a wrong? -- Atenciosamente / Best Regards, Heiler Bemerguy Network Manager - CINBESA 55 91 98151-4894/3184-1751 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: please HELP
Em 22/01/2018 19:47, Dan White escreveu: On 01/22/18 19:02 -0300, Heiler Bemerguy via Info-cyrus wrote: Em 22/01/2018 18:46, Dan White escreveu: On 01/22/18 17:44 -0300, Heiler Bemerguy via Info-cyrus wrote: imap_renamemailbox($mbox, "$mailbox", "$mailbox"."TODELETE") Was this performed as an admin? Yes. In a huge list of imap accounts I THOUGHT were unused What is an example of "$mailbox"? "{localhost:143}user/acom" would be an example I just renamed another imap account from "loginTODELETE" to "login" and even after Reconstruct, it shows on cyrus.header: root@mailer:/var/spool/cyrus/mail/a/user/ana^claudia# cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew user.ana^claudia 2696fec95963d41f $MDNSent $Forwarded ana.claudiatodelete lrswipkxtecda On a similar version of Cyrus, with the same altnamespace/unixhierarchysep config: cyradm --user=cyrus host> cm user/first.last Contents of cyrus.header: host# cat /var/spool/cyrus/mail/f/user/first^last/cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew 55eee0815a6664c2 first.last lrswipkxtecdan host> lm user/f* user/first.last (\HasNoChildren) host> setacl user/first.last cyrus all host> rename user/first.last user/first.last.TODELETE host> lm user/f* user/first.last.TODELETE (\HasNoChildren) Contents of cyrus.header: host# cat /var/spool/cyrus/mail/f/user/first^last^TODELETE/cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew 55eee0815a6664c2 cyrus lrswipkxtecdan first.last.todelete lrswipkxtecdan host> rename user/first.last.TODELETE user/first.last host> lm user/f* user/first.last (\HasNoChildren) The cyrus.header may not be directly related to your problem. Verify your mailboxes list, with cyradm, and use use it to perform your renames, as an admin user. A wrong cyrus.header content wouldn't show the mailbox as empty? At least while renaming via PHP's "imap_renamemailbox", the last line of it is not matching the mailbox name. I just checked again: root@mailer:/var/spool/cyrus/mail/a/user/ana^claudia# cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew user.ana^claudia 2696fec95963d41f $MDNSent $Forwarded ana.claudiatodelete lrswipkxtecda I don't even know exactly what it means. But it's clear that it shoudn't be that way. If I'm not wrong, I've already deleted it, but Reconstruct writes it again with "ana.claudiatodelete". Where does Reconstruct get the "old" name? Now I just renamed like you did, with cyradmin.. and guess what? another wrong cyrus.header: root@mailer:~# cyradm --user=admin localhost Password: localhost> rename user/asaudeTODELETE user/asaude localhost> quit root@mailer:/var/spool/cyrus/mail/a/user/asaude# cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew user.asaude 62c4f1d44c54c32e asaudetodelete lrswipkxtecda -- Atenciosamente / Best Regards, Heiler Bemerguy Network Manager - CINBESA 55 91 98151-4894/3184-1751 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
Re: please HELP
Em 22/01/2018 18:46, Dan White escreveu: On 01/22/18 17:44 -0300, Heiler Bemerguy via Info-cyrus wrote: imap_renamemailbox($mbox, "$mailbox", "$mailbox"."TODELETE") Was this performed as an admin? Yes. In a huge list of imap accounts I THOUGHT were unused Some mailboxes were erroneusly renamed to "loginTODELETE" and I need to put them back to the original name. I reverted this command, like: imap_renamemailbox($mbox, "$mailbox"."TODELETE", "$mailbox") And the mailbox seems to be there with the correct name. It lists all folders, but they all show up as EMPTY. We use roundcube as client and it always says "no messages was found" I've already tried like "cyrus reconstruct -r -f user/personlogin" with no luck !!! What is your Cyrus version, and what does a sanitized copy of your imapd.conf look like? 2.5.10 configdirectory: /var/lib/cyrus proc_path: /dev/shm/cyrus/proc mboxname_lockpath: /dev/shm/cyrus/lock defaultpartition: default partition-default: /var/spool/cyrus/mail partition-news: /var/spool/cyrus/news newsspool: /var/spool/news altnamespace: no unixhierarchysep: yes reject8bit: yes lmtp_downcase_rcpt: yes admins: admin allowanonymouslogin: no popminpoll: 0 autocreate_quota: 0 umask: 077 hashimapspool: true allowplaintext: yes sasl_mech_list: PLAIN lmtp_strict_quota: 1 allowusermoves: true If you have unixhierarchysep turned off, then you'd want: cyrreconstruct -r -f user.personlogin Please make sure you have a backup of the current state of your mailstore before proceeding, in addition to whatever backups you had prior to modification. I've done that. But in the cyrus.header, the "todelete" is still there, although in lower case.. I think that is the big problem!! The '^' implies you have unixhierarchysep turned off, based on this: https://www.cyrusimap.org/imap/concepts/features/namespaces.html?highlight=internal See the /doc/internal documentation within the source as well. iury.pintotodelete lrswipkxtecda But it is enabled.. should I disable it or what? I just renamed another imap account from "loginTODELETE" to "login" and even after Reconstruct, it shows on cyrus.header: root@mailer:/var/spool/cyrus/mail/a/user/ana^claudia# cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew user.ana^claudia 2696fec95963d41f $MDNSent $Forwarded ana.claudiatodelete lrswipkxtecda Is this incorrect header file that is causing all this users folders to appears as empty ?? why reconstruct isnt' fixing it ??! -- Atenciosamente / Best Regards, Heiler Bemerguy Network Manager - CINBESA 55 91 98151-4894/3184-1751 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
please HELP
Hi guys, I used a php script with this command: imap_renamemailbox($mbox, "$mailbox", "$mailbox"."TODELETE") Some mailboxes were erroneusly renamed to "loginTODELETE" and I need to put them back to the original name. I reverted this command, like: imap_renamemailbox($mbox, "$mailbox"."TODELETE", "$mailbox") And the mailbox seems to be there with the correct name. It lists all folders, but they all show up as EMPTY. We use roundcube as client and it always says "no messages was found" I've already tried like "cyrus reconstruct -r -f user/personlogin" with no luck !!! I've noticed the cyrus.index file still mention the TODELETE name.. like this: cat cyrus.header Cyrus mailbox header "The best thing about this system was that it had lots of goals." --Jim Morris on Andrew user.iury^pinto 78e57a515a664ca1 iury.pintotodelete lrswipkxtecda How can I fix it ??? -- Atenciosamente / Best Regards, Heiler Bemerguy Network Manager - CINBESA 55 91 98151-4894/3184-1751 Cyrus Home Page: http://www.cyrusimap.org/ List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/ To Unsubscribe: https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus