Hi spaceout,
I'm facing with the same probelm and I found your post/solution because.
However, before to implement this script, I would like to be sure that the deletion of the file will not cause any problem.
In the directories /var/qmail/mailnames/domain/youruser/Maildir/cur or /var/qmail/mailnames/domain/youruser/Maildir/new, I can find the files and delete the ones older than x days.
BUT... in the /var/qmail/mailnames/domain/youruser/Maildir/ directory, there is a file named "maildirsize" which seems to contain 1 line for each file in the cur/new directory. I don't know the usage of this file and what is the goal of it's content. Would it be possible that Plesk uses it to know the size of the mailbox?
Did you also see this file in the Maildir directory and did you make something special with it?
Regards,
Joel