Pergunta

My Exim mail queue was full of spam so I ran a custom grep command to search out spooled messages that contained the spam terms. Problem is, I didn't know that Exim breaks messages up into multiple files (one for header information, one for data, etc.) so my grep command deleted the data files while leaving the header files.

Does anyone know of a way I can easily find and delete messages in the queue that have a header file but no data file? Or another way to fix it?

Foi útil?

Solução

Find them:

exipick '$message_body_missing'

Find and delete them:

exipick -i '$message_body_missing' | xargs exim -Mrm

Outras dicas

For lack of exipick,

cd /var/spool/exim/input
find -name "*-H" -exec sh -c 'H={}; if [ ! -e ${H%-*}-D ]; then rm $H; fi' \;
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top