Mailing List Archive

SQL command for deleting an user?
What is the best way to delete an user from dbmail in SQL? Is there a
cascading delete for dbmail_users?
--
View this message in context: http://old.nabble.com/SQL-command-for-deleting-an-user--tp34058470p34058470.html
Sent from the dbmail users mailing list archive at Nabble.com.

_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
Re: SQL command for deleting an user? [ In reply to ]
Am 23.06.2012 12:29, schrieb cl445:
>
> What is the best way to delete an user from dbmail in SQL? Is there a
> cascading delete for dbmail_users?

after remove it from "dbmail_users" all messages are orhpaned
and cleaned by dbmail-util - i am not sure if you have to
remove the records from "dbmail_aliases" manually, my backend does
Re: SQL command for deleting an user? [ In reply to ]
Hmm... this solution isn't really statisfing. Making a dirty delete and hope
that the command-line tool will clean it up...


Reindl Harald-2 wrote:
>
>
>
> Am 23.06.2012 12:29, schrieb cl445:
>>
>> What is the best way to delete an user from dbmail in SQL? Is there a
>> cascading delete for dbmail_users?
>
> after remove it from "dbmail_users" all messages are orhpaned
> and cleaned by dbmail-util - i am not sure if you have to
> remove the records from "dbmail_aliases" manually, my backend does
>
>
>
> _______________________________________________
> DBmail mailing list
> DBmail@dbmail.org
> http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
>
>

--
View this message in context: http://old.nabble.com/SQL-command-for-deleting-an-user--tp34058470p34058974.html
Sent from the dbmail users mailing list archive at Nabble.com.

_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
Re: SQL command for deleting an user? [ In reply to ]
this has nothing to do with hope - this is simply the way dbmail works internally even if you delete a message via imap or Pop3

you remove only a reference record and the rest is done via dbmail-util called daily from crond


-------- Original-Nachricht --------
Von: cl445 <claaskaehler@yfx.de>
Gesendet: Sat Jun 23 15:37:45 MESZ 2012
An: dbmail@dbmail.org
Betreff: Re: [Dbmail] SQL command for deleting an user?


Hmm... this solution isn't really statisfing. Making a dirty delete and hope
that the command-line tool will clean it up...


Reindl Harald-2 wrote:
>
>
>
> Am 23.06.2012 12:29, schrieb cl445:
>>
>> What is the best way to delete an user from dbmail in SQL? Is there a
>> cascading delete for dbmail_users?
>
> after remove it from "dbmail_users" all messages are orhpaned
> and cleaned by dbmail-util - i am not sure if you have to
> remove the records from "dbmail_aliases" manually, my backend does
>
>
>
> _______________________________________________
> DBmail mailing list
> DBmail@dbmail.org
> http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
>
>

--
View this message in context: http://old.nabble.com/SQL-command-for-deleting-an-user--tp34058470p34058974.html
Sent from the dbmail users mailing list archive at Nabble.com.

_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


--

Reindl Harald (mobile)
the lounge interactive design GmbH
A-1060 Vienna, Hofmühlgasse 17
CTO / CISO / Software-Development
+43 (676) 40 221 40
http://www.thelounge.net
_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
Re: SQL command for deleting an user? [ In reply to ]
back on my workstation....

why in the world do you think that this is a matter of hope?
dbmail will NEVER remove all records even if you remove
a message via POP3/IMAP - it will always only delete
references and the rest is the job of dbmail-util

* delete 20000 messages
* you will not notice load
* call "dbmail-util -c -t -u -b -p -d -y"
* call it 3 times
* on the last 2 times you will note HEAVY IO-LOad

and that is why dbmail-util is called via crond
on each proper setup in the night to not raise
up system-load at business time for remove
unused data

Am 23.06.2012 15:37, schrieb cl445:
>
> Hmm... this solution isn't really statisfing. Making a dirty delete and hope
> that the command-line tool will clean it up...
>
>
> Reindl Harald-2 wrote:
>>
>>
>>
>> Am 23.06.2012 12:29, schrieb cl445:
>>>
>>> What is the best way to delete an user from dbmail in SQL? Is there a
>>> cascading delete for dbmail_users?
>>
>> after remove it from "dbmail_users" all messages are orhpaned
>> and cleaned by dbmail-util - i am not sure if you have to
>> remove the records from "dbmail_aliases" manually, my backend does
>>
>>
>>
>> _______________________________________________
>> DBmail mailing list
>> DBmail@dbmail.org
>> http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail
>>
>>
>

--

Reindl Harald
the lounge interactive design GmbH
A-1060 Vienna, Hofmühlgasse 17
CTO / CISO / Software-Development
p: +43 (1) 595 3999 33, m: +43 (676) 40 221 40
icq: 154546673, http://www.thelounge.net/

http://www.thelounge.net/signature.asc.what.htm
Re: SQL command for deleting an user? [ In reply to ]
On 06/23/2012 12:29 PM, cl445 wrote:
>
> What is the best way to delete an user from dbmail in SQL? Is there a
> cascading delete for dbmail_users?


Yes. When you delete a dbmail_users record, this will trigger a
cascading delete on

dbmail_mailboxes,
dbmail_acl,
dbmail_sievescripts,
dbmail_subscription,
dbmail_auto_notifications,
dbmail_auto_replies
dbmail_messages

However, as Harald mentions this will not clean out the actual message
blobs, only their metadata records.

dbmail-util will clean out any physmessages, partlists and mimeparts
records that are no longer connected to any email messages.




--
________________________________________________________________
Paul J Stevens pjstevns @ gmail, twitter, skype, linkedin

* Premium Hosting Services and Web Application Consultancy *

www.nfg.nl/info@nfg.nl/+31.85.877.99.97
________________________________________________________________
_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail