[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-03 Thread Eric Shubert

On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've 
noticed some weirdness/cruft in that table as well.


Please ask on the vpopmail list (vch...@inter7.com). if nothing comes of 
that, perhaps we can write something.


--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-03 Thread Eric Shubert

On 08/03/2012 02:52 PM, ales...@skye.it wrote:


Eric Shubert  ha scritto:


On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've
noticed some weirdness/cruft in that table as well.

Please ask on the vpopmail list (vch...@inter7.com). if nothing comes
of that, perhaps we can write something.


Thanks for your reply. I have alreadyasked on vpopmail list but nobody
answered :-(



Ooops. Sorry, I missed that post. I guess we're on our own with this.

I wonder if this is a symptom of a buggy vqadmin. Have you used vqadmin 
to update anything?


Are you noticing any specific problem with this?

This implies that you have domains being hosted that aren't listed in 
the dir_control table. Is that correct?


Let's see if we can get this fixed up. I wouldn't be surprised if there 
are people with disparities there too who haven't migrated. :(


--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-03 Thread Eric Shubert

On 08/03/2012 10:08 AM, Bharath Chari wrote:

On Friday 03 August 2012 09:00 PM, Eric Shubert wrote:

On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've
noticed some weirdness/cruft in that table as well.

Please ask on the vpopmail list (vch...@inter7.com). if nothing comes
of that, perhaps we can write something.



I think dir_control has driven all of us insane at one point of time or
the other :). There's one more anomaly that I had forgotten about.
According to inter7, no directory will contain more than 100 users. To
quote :



Vpopmail uses an adaptive directory structure based on a state file
".dir-control" which is automatically managed by the core vpopmail api
functions "vadduser" and "vdeluser". For sites with 100 users or less,
all user directories are stored in the virtual domain directory. For
sites that go above 100 users the adaptive directory structure goes into
effect. The basic idea is to break up the user Maildir directories
across multple directories and sub directories so that there are never
more than 100 user directories in a single directory.

The default directory setup allows for 62 directories in 3 levels and
100 user directories per directory. The total number of user directories
is equal to 100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100) =
over 24 million directories. This should be more than sufficent for any
site and probably goes beyond the technology of directory structures.

If you are going to be storing large numbers of user directories, make
sure you set your file system to have a higher than normal percentage of
inodes.

Vpopmail will automatically create these directories and sub directories
as needed and populate each directory with up to 100 user accounts. As
soon as a directory reaches 100 users it will create the next directory
or sub directory and store the new users directory there.




However, I have directories that have well over 100 accounts in them. Is
this peculiar to me, or is this the case with everyone else too?

Bharath


QMT has this feature turned off (if I'm not mistaken):
# rpm -qi vpopmail-toaster | grep hash
 user dir hashing  = OFF --disable-users-big-dir
#

Personally, I like having this off. I believe this feature goes back to 
the days when ext2/3 was slow when the number of directory entries got 
very large. If someone is experiencing a problem with this, I would 
suggest enabling the dir_index feature. Actually I'd suggest using this 
for any ext2/3 filesystem that contains maildirs. Or perhaps using a 
filesystem that's better suited for the situation. Personally, I think 
ext4 does pretty well though.


--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-04 Thread Eric Shubert

On 08/04/2012 02:42 AM, Alessio Cecchi wrote:

Yes could be, currently the only certain thing is that domains in
rcpthosts+morercpthosts are more that domain in dir_control table and so
the dom_89 row is "corrupted".


So rather than me having to look it up, will you (or someone) post a CLI 
command we can run to check this value? I'd like to see what various 
people find.


The next question then is what impact does that field have? Once we have 
some idea of how wide spread the disparity is, we can as Matt on the 
vpopmail list about how that field is used. If he's not responsive, 
we'll need to take a look at the vpopmail code.


Just off the top of my head, I'm wondering if it's used to determine 
whether or not to use rcpthosts and/or more_rcpthosts files to add 
domains. If that's the case, it probably doesn't have much if any impact.


(Use the Source, Luke.) ;)

--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-08 Thread Eric Shubert

On 08/08/2012 11:12 AM, xaf wrote:

|--> Alessio Cecchi, le 06/08/2012 09:42, a dit :


One last question, in dir_control the dom_89 row report in "domains"
filed "51" and "0" in all other fields. i do not think is correct.

How can fix it? If someone explain me what the fileds means I can try to
correct it manually.


domains 51 is the total number of domains
for 51 domains
default values
level_cur 0
level_max 3
level_start0 0
level_start1 0
level_start2 0
level_end0 61
level_end1 61
level_end2 61
level_mod0 0
level_mod1 2
level_mod2 4
level_index0 0
level_index1 0
level_index2 0
the_dir nothing

the_dir indicate where to put the next domain in the directory structure

Directory structure in the manual
The default directory setup allows for 62 directories in 3 levels and
100 user directories per directory. The total number of user directories
is equal to
100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100)
= over 24 million directories.

1st level 1st directory
/home/vpopmail/domains/ the_dir nothing
100 domains go here
2nd directory
/home/vpopmail/domains/0/ the_dir = 0
100 domains go here
... 1-9 then A-Z then a-z
so 62th
/home/vpopmail/domains/z/ the_dir = z

2nd & 3rd level
/home/vpopmail/domains/0/0/
/home/vpopmail/domains/0/0/0/
so for 7001th domain
/home/vpopmail/domains/0/7/
level_cur = 1 level_index0 = 7 the_dir = 7

xaf

-


Please keep in mind that QMT uses this configuration setting:
 user dir hashing  = OFF --disable-users-big-dir
so a good deal of this (all of it?) does not come into effect.

--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-08 Thread Eric Shubert

On 08/08/2012 03:57 PM, xaf wrote:

|--> Eric Shubert, le 08/08/2012 20:53, a dit :


On 08/08/2012 11:12 AM, xaf wrote:

|--> Alessio Cecchi, le 06/08/2012 09:42, a dit :


One last question, in dir_control the dom_89 row report in "domains"
filed "51" and "0" in all other fields. i do not think is correct.

How can fix it? If someone explain me what the fileds means I can try to
correct it manually.


domains 51 is the total number of domains
for 51 domains
default values
level_cur 0
level_max 3
level_start0 0
level_start1 0
level_start2 0
level_end0 61
level_end1 61
level_end2 61
level_mod0 0
level_mod1 2
level_mod2 4
level_index0 0
level_index1 0
level_index2 0
the_dir nothing

the_dir indicate where to put the next domain in the directory structure

Directory structure in the manual
The default directory setup allows for 62 directories in 3 levels and
100 user directories per directory. The total number of user directories
is equal to
100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100)
= over 24 million directories.

1st level 1st directory
/home/vpopmail/domains/ the_dir nothing
100 domains go here
2nd directory
/home/vpopmail/domains/0/ the_dir = 0
100 domains go here
... 1-9 then A-Z then a-z
so 62th
/home/vpopmail/domains/z/ the_dir = z

2nd & 3rd level
/home/vpopmail/domains/0/0/
/home/vpopmail/domains/0/0/0/
so for 7001th domain
/home/vpopmail/domains/0/7/
level_cur = 1 level_index0 = 7 the_dir = 7

xaf

-


Please keep in mind that QMT uses this configuration setting:
   user dir hashing  = OFF --disable-users-big-dir
so a good deal of this (all of it?) does not come into effect.



--disable-users-big-dir is for users directories
here it's about domains directories

just a mistake, forget to count from 0 on the last line
so for 7001th domain
/home/vpopmail/domains/0/7/
level_cur = 1 level_index1 = 8 the_dir = 0/7

xaf




Thanks for the correction. I wasn't paying close enough attention. 
Sometimes it says 'user' directories though, meaning 'domain' directories.


The vpopmail features web page says:
Support for 1 to 23 million virtual email domains using a "grow as it 
goes" balenced directory tree.
Support for 1 to 23 million email users per domain using the same 
balenced tree structure.


The --disable-users-big-dir turns it off for users, but not domains. 
There unfortunately is no --disable-domains-big-dir option (yet). 
There's not a whole lot involved with --disable-users-big-dir, so I 
presume that adding a --disable-domains-big-dir wouldn't be too tough.


Makes me wonder what the largest number of domains is on a QMT host. 
Probably < 1000. I expect that 10,000 would be stretching it.


I'm guessing this complexity is largely unnecessary in today's world. 
ext3 can have 32,000 subdirectories, and ext4 can have 64,000. I suppose 
it doesn't hurt to have the capability though (so long as it works). I'm 
inclined to have it go away for QMT though.


I just poked around the source a bit, and in the vauth.h file I found this:
#define MAX_USERS_PER_LEVEL 100

So it'd be trivial to patch this to, say, 3 on ext3 systems or 6 
on ext4 systems (with a configure option indicating the filesystem). 
This is the same code used regardless of hashed domains or users. Just 
thinking about possibilities.


If you have a QMT host with more than 100 domains, I'd like to hear from 
you. What do you think about this "feature"? Would you like to see it go 
away (like it has done with hashed user directories)?


P.S. This 'feature' needs to be kept in mind when writing scripts which 
do things in domain directories. I can think of a few scripts which will 
probably break when there are >100 domains.


Thanks for participating, everyone.

--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



[qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-08 Thread Eric Shubert

On 08/08/2012 11:12 AM, xaf wrote:

|--> Alessio Cecchi, le 06/08/2012 09:42, a dit :


One last question, in dir_control the dom_89 row report in "domains"
filed "51" and "0" in all other fields. i do not think is correct.

How can fix it? If someone explain me what the fileds means I can try to
correct it manually.


domains 51 is the total number of domains
for 51 domains
default values
level_cur 0
level_max 3
level_start0 0
level_start1 0
level_start2 0
level_end0 61
level_end1 61
level_end2 61
level_mod0 0
level_mod1 2
level_mod2 4
level_index0 0
level_index1 0
level_index2 0
the_dir nothing

the_dir indicate where to put the next domain in the directory structure



51 is total number of domains? Alessio said originally that he had 
around 1300 domains. I expect this directory hashing has definitely 
kicked in if that's the case.


Alessio, do you have a good count? What does your present domains/ tree 
look like? Should have 12 or so level-0 domains in addition to 100 real 
domains. I'm guessing there could be holes though if domains have been 
deleted.


Man, what a mess. :(


--
-Eric 'shubes'




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-03 Thread Bharath Chari

On Friday 03 August 2012 09:00 PM, Eric Shubert wrote:

On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've 
noticed some weirdness/cruft in that table as well.


Please ask on the vpopmail list (vch...@inter7.com). if nothing comes 
of that, perhaps we can write something.




I think dir_control has driven all of us insane at one point of time or 
the other :). There's one more anomaly that I had forgotten about. 
According to inter7, no directory will contain more than 100 users. To 
quote :




Vpopmail uses an adaptive directory structure based on a state file 
".dir-control" which is automatically managed by the core vpopmail api 
functions "vadduser" and "vdeluser". For sites with 100 users or less, 
all user directories are stored in the virtual domain directory. For 
sites that go above 100 users the adaptive directory structure goes into 
effect. The basic idea is to break up the user Maildir directories 
across multple directories and sub directories so that there are never 
more than 100 user directories in a single directory.


The default directory setup allows for 62 directories in 3 levels and 
100 user directories per directory. The total number of user directories 
is equal to 100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100) = 
over 24 million directories. This should be more than sufficent for any 
site and probably goes beyond the technology of directory structures.


If you are going to be storing large numbers of user directories, make 
sure you set your file system to have a higher than normal percentage of 
inodes.


Vpopmail will automatically create these directories and sub directories 
as needed and populate each directory with up to 100 user accounts. As 
soon as a directory reaches 100 users it will create the next directory 
or sub directory and store the new users directory there.





However, I have directories that have well over 100 accounts in them. Is 
this peculiar to me, or is this the case with everyone else too?


Bharath


Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-03 Thread alessio


Eric Shubert  ha scritto:


On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've  
noticed some weirdness/cruft in that table as well.


Please ask on the vpopmail list (vch...@inter7.com). if nothing  
comes of that, perhaps we can write something.


Thanks for your reply. I have alreadyasked on vpopmail list but nobody  
answered :-(


--
Alessio Cecchi is:
@ ILS -> http://www.linux.it/~alessice/
on LinkedIn -> http://www.linkedin.com/in/alessice
Assistenza Sistemi GNU/Linux -> http://www.cecchi.biz/
@ PLUG -> ex-Presidente, adesso senatore a vita, http://www.prato.linux.it


-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-04 Thread Alessio Cecchi


Eric Shubert  ha scritto:


On 08/03/2012 02:52 PM, ales...@skye.it wrote:


Eric Shubert  ha scritto:


On 08/03/2012 02:54 AM, Alessio Cecchi wrote:

Hi,

after a migration, based on mysqldump and rsync, I think I've corrupted
the dir_control table in vpopmail database (I'm using mysql).

The row total in my dir_control are 1220 but the total number of domain
hosted in the email server are about 1300.

How can I rebuild or check the table dir_control?

Thank



Good question. I think it'd be handy to have a script for that. I've
noticed some weirdness/cruft in that table as well.

Please ask on the vpopmail list (vch...@inter7.com). if nothing comes
of that, perhaps we can write something.


Thanks for your reply. I have alreadyasked on vpopmail list but nobody
answered :-(



Ooops. Sorry, I missed that post. I guess we're on our own with this.

I wonder if this is a symptom of a buggy vqadmin. Have you used  
vqadmin to update anything?


I'm not using vqadmin, only vadddomain.


Are you noticing any specific problem with this?


No, no problem was found.

This implies that you have domains being hosted that aren't listed  
in the dir_control table. Is that correct?


Yes could be, currently the only certain thing is that domains in  
rcpthosts+morercpthosts are more that domain in dir_control table and  
so the dom_89 row is "corrupted".


Let's see if we can get this fixed up. I wouldn't be surprised if  
there are people with disparities there too who haven't migrated. :(


Thanks.
--
Alessio Cecchi is:
@ ILS -> http://www.linux.it/~alessice/
on LinkedIn -> http://www.linkedin.com/in/alessice
Assistenza Sistemi GNU/Linux -> http://www.cecchi.biz/
@ PLUG -> ex-Presidente, adesso senatore a vita, http://www.prato.linux.it



-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-04 Thread xaf
|--> Eric Shubert, le 04/08/2012 14:27, a dit :

> On 08/04/2012 02:42 AM, Alessio Cecchi wrote:
>> Yes could be, currently the only certain thing is that domains in
>> rcpthosts+morercpthosts are more that domain in dir_control table and so
>> the dom_89 row is "corrupted".


run /home/vpopmail/bin/vdominfo
should add to dir_control missing domains
dom_89 should be equal to (and so total rows -1)
/home/vpopmail/bin/vdominfo |grep domain: | grep -v alias | wc -l
if not, fix it manually


> 
> So rather than me having to look it up, will you (or someone) post a CLI 
> command we can run to check this value? I'd like to see what various 
> people find.

/home/vpopmail/bin/vdominfo |grep domain: | grep -v alias | wc -l
cat /var/qmail/users/assign | grep -o ':.*:' | sort | uniq | wc -l
must be equal


/home/vpopmail/bin/vdominfo |grep domain: | wc -l
cat /var/qmail/control/rcpthosts /var/qmail/control/morercpthosts | wc -l
cat /var/qmail/control/virtualdomains | wc -l
sed '$d' /var/qmail/users/assign | wc -l
must be equal

> 
> The next question then is what impact does that field have? Once we have 
> some idea of how wide spread the disparity is, we can as Matt on the 
> vpopmail list about how that field is used. If he's not responsive, 
> we'll need to take a look at the vpopmail code.
> 
> Just off the top of my head, I'm wondering if it's used to determine 
> whether or not to use rcpthosts and/or more_rcpthosts files to add 
> domains. If that's the case, it probably doesn't have much if any impact.
> 

no, vpopmail does count rcpthosts domains each time vadddomain is
invoked (rcpthosts < 50 < morercpthosts)
xaf



-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-06 Thread Alessio Cecchi

Il 04/08/2012 16:26, xaf ha scritto:

|--> Eric Shubert, le 04/08/2012 14:27, a dit :


On 08/04/2012 02:42 AM, Alessio Cecchi wrote:

Yes could be, currently the only certain thing is that domains in
rcpthosts+morercpthosts are more that domain in dir_control table and so
the dom_89 row is "corrupted".



run /home/vpopmail/bin/vdominfo
should add to dir_control missing domains
dom_89 should be equal to (and so total rows -1)
/home/vpopmail/bin/vdominfo |grep domain: | grep -v alias | wc -l
if not, fix it manually


Thanks,

run /home/vpopmail/bin/vdominfo add the missing domains but not set the 
correct value in "cur_users" (set it to 0). With a query (SELECT * FROM 
dir_control WHERE cur_users='0';) I found this domains and manually 
corrected.


with this commands I have found and correct the mismatched domains.

One last question, in dir_control the dom_89 row report in "domains" 
filed "51" and "0" in all other fields. i do not think is correct.


How can fix it? If someone explain me what the fileds means I can try to 
correct it manually.


--
Alessio Cecchi is:
@ ILS -> http://www.linux.it/~alessice/
on LinkedIn -> http://www.linkedin.com/in/alessice
Assistenza Sistemi GNU/Linux -> http://www.cecchi.biz/
@ PLUG -> ex-Presidente, adesso senatore a vita, http://www.prato.linux.it

-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-08 Thread xaf
|--> Alessio Cecchi, le 06/08/2012 09:42, a dit :

> One last question, in dir_control the dom_89 row report in "domains" 
> filed "51" and "0" in all other fields. i do not think is correct.
> 
> How can fix it? If someone explain me what the fileds means I can try to 
> correct it manually.

domains 51 is the total number of domains
for 51 domains
default values
level_cur 0
level_max 3
level_start0 0
level_start1 0
level_start2 0
level_end0 61
level_end1 61
level_end2 61
level_mod0 0
level_mod1 2
level_mod2 4
level_index0 0
level_index1 0
level_index2 0
the_dir nothing

the_dir indicate where to put the next domain in the directory structure

Directory structure in the manual
The default directory setup allows for 62 directories in 3 levels and
100 user directories per directory. The total number of user directories
is equal to
100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100)
= over 24 million directories.

1st level 1st directory
/home/vpopmail/domains/ the_dir nothing
100 domains go here
2nd directory
/home/vpopmail/domains/0/ the_dir = 0
100 domains go here
... 1-9 then A-Z then a-z
so 62th
/home/vpopmail/domains/z/ the_dir = z

2nd & 3rd level
/home/vpopmail/domains/0/0/
/home/vpopmail/domains/0/0/0/
so for 7001th domain
/home/vpopmail/domains/0/7/
level_cur = 1 level_index0 = 7 the_dir = 7

xaf






-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-08 Thread xaf
|--> Eric Shubert, le 08/08/2012 20:53, a dit :

> On 08/08/2012 11:12 AM, xaf wrote:
>> |--> Alessio Cecchi, le 06/08/2012 09:42, a dit :
>>
>>> One last question, in dir_control the dom_89 row report in "domains"
>>> filed "51" and "0" in all other fields. i do not think is correct.
>>>
>>> How can fix it? If someone explain me what the fileds means I can try to
>>> correct it manually.
>>
>> domains 51 is the total number of domains
>> for 51 domains
>> default values
>> level_cur 0
>> level_max 3
>> level_start0 0
>> level_start1 0
>> level_start2 0
>> level_end0 61
>> level_end1 61
>> level_end2 61
>> level_mod0 0
>> level_mod1 2
>> level_mod2 4
>> level_index0 0
>> level_index1 0
>> level_index2 0
>> the_dir nothing
>>
>> the_dir indicate where to put the next domain in the directory structure
>>
>> Directory structure in the manual
>> The default directory setup allows for 62 directories in 3 levels and
>> 100 user directories per directory. The total number of user directories
>> is equal to
>> 100 + (62 * 100) + (62 * 62 * 100) + (62 * 62 * 62 * 100)
>> = over 24 million directories.
>>
>> 1st level 1st directory
>> /home/vpopmail/domains/ the_dir nothing
>> 100 domains go here
>> 2nd directory
>> /home/vpopmail/domains/0/ the_dir = 0
>> 100 domains go here
>> ... 1-9 then A-Z then a-z
>> so 62th
>> /home/vpopmail/domains/z/ the_dir = z
>>
>> 2nd & 3rd level
>> /home/vpopmail/domains/0/0/
>> /home/vpopmail/domains/0/0/0/
>> so for 7001th domain
>> /home/vpopmail/domains/0/7/
>> level_cur = 1 level_index0 = 7 the_dir = 7
>>
>> xaf
>>
>> -
> 
> Please keep in mind that QMT uses this configuration setting:
>   user dir hashing  = OFF --disable-users-big-dir
> so a good deal of this (all of it?) does not come into effect.
> 

--disable-users-big-dir is for users directories
here it's about domains directories

just a mistake, forget to count from 0 on the last line
so for 7001th domain
/home/vpopmail/domains/0/7/
level_cur = 1 level_index1 = 8 the_dir = 0/7

xaf




-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com



Re: [qmailtoaster] Re: Check data in vpopmail/dir_control table

2012-08-10 Thread xaf
|--> Eric Shubert, le 09/08/2012 02:52, a dit :

> Makes me wonder what the largest number of domains is on a QMT host. 
> Probably < 1000. I expect that 10,000 would be stretching it.
> 
> I'm guessing this complexity is largely unnecessary in today's world. 
> ext3 can have 32,000 subdirectories, and ext4 can have 64,000. I suppose 
> it doesn't hurt to have the capability though (so long as it works). I'm 
> inclined to have it go away for QMT though.
> 
> I just poked around the source a bit, and in the vauth.h file I found this:
> #define MAX_USERS_PER_LEVEL 100
> 
> So it'd be trivial to patch this to, say, 3 on ext3 systems or 6 
> on ext4 systems (with a configure option indicating the filesystem). 
> This is the same code used regardless of hashed domains or users. Just 
> thinking about possibilities.
> 
> If you have a QMT host with more than 100 domains, I'd like to hear from 
> you. What do you think about this "feature"? Would you like to see it go 
> away (like it has done with hashed user directories)?


bigdir behaviour is a real pain
but i dont' like thousand and thousand directories per directory
and i want visual access to the domain directory (without reading assign
file)
so i've 1 level sub-directories 0-9 a-z
and move domains depending on its first letter
nothing in the master directory (/home/vpopmail/domains/)

either change bigdir behaviour
either let it go

xaf


-
To unsubscribe, e-mail: qmailtoaster-list-unsubscr...@qmailtoaster.com
For additional commands, e-mail: qmailtoaster-list-h...@qmailtoaster.com