• The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Deleting a users email

K

kdrerup

Guest
Does anyone know if there is a better to deleted mail out of a user's mailbox. Currently I login in via webmail as the user and delte the mail that way. At the rate of 25 emails at a time this can be very tedious. On our old server I use to us mutt to access mailboxes and it was easy to delete mail then.

Any help would be apprecated.
 
You could delete via shell from /var/qmail/mailnames/domain.com/mailboxname/
 
Ok I get to the directory then what do I do? I just want to delete several email that he has in the mailbox. Do I use vi to open his mailbox. I am sorry if this sounds like a dumb question but I am just starting to learn Linux.
 
Every file is an email, you can view the email with less, more, cat or similar then delete the appropriate ones with rm.
 
We I go to the mailbox name and do an ls all I see are three files@attachments, maildir, and user_prefs. No email.
 
Maildir is a directory, if you enter the directory you'll find some more config files, and directories. Enter the directories and you can delete the email.
 
I thank you for your patience and help. When I get to the mailbox and try to to a cd maildir. It will not let me. When I do an ls maildir is blue in color. does that mean the file is lock or do I have to use another command to get into it.

Again Thanks for you help.
 
Blue is probably telling you it's a directory. Are you logged in as root? What exactly happens when you try to enter the directory?
 
I got in it. It is case sensitive. Now once I am in it I see the following courierimapkeywords, courierimapuiddb, courierpop3dsizelist, cur, new, tmp. Which one do i go into next?
 
Go into the "Cur" directory and do a:

find -type f | xargs rm -f

I just had to delete 20,000 emails from a box this way. MAKE SURE YOU ARE IN THE CUR DIRECTORY WHEN YOU DO THIS!!!
 
Back
Top