diff --git a/hsarback/src/de/hsadmin/mods/dom/DomainProcessorFactory.java b/hsarback/src/de/hsadmin/mods/dom/DomainProcessorFactory.java index ce2e137..12a837a 100644 --- a/hsarback/src/de/hsadmin/mods/dom/DomainProcessorFactory.java +++ b/hsarback/src/de/hsadmin/mods/dom/DomainProcessorFactory.java @@ -166,7 +166,7 @@ public class DomainProcessorFactory implements EntityProcessorFactory { public Processor createDeleteProcessor(EntityManager em, T entity) { Domain dom = (Domain) entity; String domName = dom.getName(); - ShellProcessor emailAddressRemoveProcessor = new ShellProcessor("for KEY in $(postmap -s /etc/postfix/virtual|grep " + domName + "|cut -f1); do postmap -d $KEY /etc/postfix/virtual; done"); + ShellProcessor emailAddressRemoveProcessor = new ShellProcessor("for KEY in $(postmap -s /etc/postfix/virtual|grep '@" + domName + "\\s'|cut -f1); do postmap -d $KEY /etc/postfix/virtual; done"); ShellProcessor dnsRemoveRemoveProcessor = new ShellProcessor("grep -v '\"pri." + domName + "\"' /etc/bind/named.pri-zones > /etc/bind/named.pri-zones.tmp" + " && mv /etc/bind/named.pri-zones.tmp /etc/bind/named.pri-zones" +