aboutsummaryrefslogtreecommitdiff
path: root/content/blog/miscellaneous/purge-postfix-queue-based-content.md
diff options
context:
space:
mode:
Diffstat (limited to 'content/blog/miscellaneous/purge-postfix-queue-based-content.md')
-rw-r--r--content/blog/miscellaneous/purge-postfix-queue-based-content.md13
1 files changed, 9 insertions, 4 deletions
diff --git a/content/blog/miscellaneous/purge-postfix-queue-based-content.md b/content/blog/miscellaneous/purge-postfix-queue-based-content.md
index 2db52ac..d131af2 100644
--- a/content/blog/miscellaneous/purge-postfix-queue-based-content.md
+++ b/content/blog/miscellaneous/purge-postfix-queue-based-content.md
@@ -1,13 +1,18 @@
---
title: "Purge postfix queue based on email contents"
-linkTitle: "Purge postfix queue based on email contents"
date: 2009-04-27
-description: >
- Purge postfix queue based on email contents
+description: How to selectively purge a postfix queue based on email contents
+tags:
+ - toolbox
---
+## The problem
+Sometimes a lot of spam can acacumulate in a postfix queue.
+
+## The solution
+
+Here is a command that can search through queued emails for a certain character string (here XXX as an example) and delete the ones that contain it :
{{< highlight sh >}}
find /var/spool/postfix/deferred/ -type f -exec grep -li 'XXX' '{}' \; | xargs -n1 basename | xargs -n1 postsuper -d
{{< /highlight >}}
-