The problem is this:
After converting vdominfo says that there are "0" users in the domain, the
users are in fact in the database but it appears that the field "cur_users"
in the dir_control table isn't updated by vconvert.
Can you (or someone else) test this patch and report back? It should increment the count just like vadduser does. I did a quick test with a 5-user domain and it worked. It should also help with getting the other fields of dir_control set right (so a domain with 1000's of users hashes properly).
I'm going to add code to properly update dir_control for MySQL->CDB as well. I'll check the changes into CVS and they will be in the next release.
diff -u -r1.2.2.1 vconvert.c --- vconvert.c 10 Mar 2004 15:18:50 -0000 1.2.2.1 +++ vconvert.c 18 Aug 2004 05:01:38 -0000 @@ -188,6 +188,8 @@ int i, colon_count, dir_count; int bFoundDomain = 0; char assign_file[MAX_BUFF]; + uid_t uid; + gid_t gid;
snprintf(assign_file, sizeof(assign_file), "%s/users/assign", QMAILDIR);
if ( (assign_fs=fopen(assign_file, "r"))==NULL ) {
@@ -227,9 +229,13 @@
fclose(assign_fs);
vauth_deldomain(domain);
+ vdel_dir_control(domain);
vauth_adddomain(domain);- vget_assign(domain, Dir, sizeof(Dir), NULL, NULL );
+ vget_assign(domain, Dir, sizeof(Dir), &uid, &gid );
+#ifdef USERS_BIG_DIR
+ open_big_dir (domain, uid, gid);
+#endif
snprintf(tmpbuf, sizeof(tmpbuf), "%s/vpasswd", Dir);
fs = fopen(tmpbuf,"r");
if ( fs == NULL ) return(-1);
@@ -241,8 +247,14 @@
continue;
}
vauth_setpw(pw, domain);
+#ifdef USERS_BIG_DIR
+ next_big_dir (uid, gid); /* increment user count */
+#endif
}
fclose(fs);
+#ifdef USERS_BIG_DIR
+ close_big_dir (domain, uid, gid);
+#endif
#endif /* USE_SQL */
return(0);
}-- Tom Collins - [EMAIL PROTECTED] QmailAdmin: http://qmailadmin.sf.net/ Vpopmail: http://vpopmail.sf.net/ Info on the Sniffter hand-held Network Tester: http://sniffter.com/
