Scott,
Sorry this took so long, but I've been out of town the last two days.
Here is a patch against cyrus-imapd-2.0.9. Consider it beta.
1. Apply this patch in the imap/ directory of the distribution
2. run config.status from the toplevel directory so that imap/Makefile
gets rebuilt
3. run make from either the toplevel or the imap/ directory
NOTE: I put this patch together from the 'user-rename' branch in CVS
and tested it *very* quickly. However I'm pretty confident that it will
work without any problems.
If you want to be really safe, use the 'user-rename' branch from CVS
(that's what I've been using and developing on). This branch also
contains all of the changes from the trunk that will be in 2.0.10.
As long as you're using cyrusdb_flat for seen state, subscriptions and
quotas, you shouldn't have any problems if someone is accessing the
folders when they are renamed. But just to play it safe, make sure that
the user that you are renaming is not logged into the server when you
rename him/her. To help prevent this, change their login name via
whatever SASL mechanism you're using first, so they can't log in using
their old login.
When you rename the user, the seen state, quota, subscriptions and ACLs
should all be renamed as well. The only thing that won't happen is the
renaming of any sieve scripts (this is outside of the scope of IMAP -- I
might modify cyradm to handle this however).
Let me know how it goes,
Ken
Scott Pederick wrote:
>
> -----Original Message-----
> From: Ken Murchison <[EMAIL PROTECTED]>
> To: Scott Pederick <[EMAIL PROTECTED]>
> Cc: Cyrus Mailing List <[EMAIL PROTECTED]>
> Date: Thursday, 25 January 2001 1:10
> Subject: Re: Renaming users
>
> >
> >
> >Scott Pederick wrote:
> >>
> >> G'day,
> >>
> >> Just wondering if anyone has done this before. The username format has
> >> changed from being "<first initial><last name>@xyz.com" to "<first
> >> name>_<last name>@xyz.com".
> >>
> >> Therefore I have to rename a number of mailboxes. The problem is that
> cyradm
> >> tells me "renamemailbox: Operation is not supported on mailbox". It
> doesn't
> >> seem to be a permissions issue so I'm thinking I'll have to do something
> >> more low-level (ie. move files, rebuild db's, etc).
> >>
> >> If anyone has any advice or can point me in the right direction, it would
> be
> >> greatly appreciated. Thanks in advance.
> >
> >I have some user rename code checked-in on a dev branch in CVS which I
> >trying to put the finishing touches on (primarily file locking) before I
> >submit it to the list as beta. If you need this immediately, I can post
> >the patches with the standard disclaimer.
> >
> >FYI, I have tested this on my production server (~20 users) without any
> >problems, but I make SURE that nobody is trying to access any of the
> >user's mailboxes while doing the rename. You must also note that this
> >is a fairly expensive operation, since it requires renaming all of the
> >mailboxes, renaming the seen state and quota files and modifying the
> >ACLs and subscriptions.
> >
> >Ken
> >--
> >Kenneth Murchison Oceana Matrix Ltd.
> >Software Engineer 21 Princeton Place
> >716-662-8973 x26 Orchard Park, NY 14127
> >--PGP Public Key-- http://www.oceana.com/~ken/ksm.pgp
>
> Ken,
>
> If you could post it, that would be great. I need to get this done as soon
> as possible.
>
> Thanks again for your help - greatly appreciated!
>
> Scott Pederick
--
Kenneth Murchison Oceana Matrix Ltd.
Software Engineer 21 Princeton Place
716-662-8973 x26 Orchard Park, NY 14127
--PGP Public Key-- http://www.oceana.com/~ken/ksm.pgp
user-rename.patch.gz