Tom Collins wrote:

On Apr 21, 2004, at 4:00 AM, Rick Widmer wrote:
I have an insertion sort working with users/assign that keeps domain names in order. Should I try to make it support all the qmail control files or have a separate function for that file?

Will there be a procedure for people upgrading to follow that will get their file sorted properly?

Probably... First, I don't see a problem just switching to the new code. The entries aren't in any special order now, and if we switched to inserting new records before the first record with a domain name > the entry being added... who cares?

Second, sort worked on my 1500 test domains just fine:

   > sort assign > assign.sorted
   > mv assign.sorted assign
   > qmail-newu

I am considering adding a search for out or order records in the sort code. If any are found, the program would sort the entire file right after it gets done inserting the new entry. No user intervention, ever.

Finally, does anyone have any thoughts on a function that promotes an alias domain to primary. It would rename the domains/ directory and update all the users/assign entries. Someday it might even fix mailing lists to reflect the primary domain name change.

I think this would be an excellent idea. I think I talked with Michael Bowe about this in respect to vdeldomain -- that there should be a way to "promote" one of the aliases to be the "real" domain.

Keep in mind that you might also need to update every .qmail file, looking for Maildir pathnames (used in autoresponders, .qmail-default, old-style aliases, etc.) as well. It might just be easier to keep the old directory name and update users/assign with a new "real" domain for the aliases.

I will look at both possibilities, this is pretty high on my desired features list. (I've done it by hand... :( ) It seems weird to me having virtual domains on a system where the parent domain doesn't actually exist. Who knows what might go wrong in the future. If I do decide to update the domain directory, is there an easy way to make qmail defer all mail to the domain(s) while the surgery is in progress.

Reply via email to