EVOLUTION-MANAGER
Edit File: cluster@.service
[Unit] Description=PF_RING ZC cluster service with ID %I After=network.target syslog.target pf_ring.service Requires=pf_ring.service [Service] Type=simple ExecStartPre=/bin/sh -c '/bin/sed "/-d$\\|-P=.*/s/^/#/" /etc/cluster/cluster-%i.conf > /run/cluster-%i.conf' ExecStartPre=/bin/sh -c '/bin/echo "$(/bin/date) cluster %i StartPre" >> /var/log/ntop-systemd.log' ExecStart=/usr/bin/zbalance_ipc /run/cluster-%i.conf ExecStartPost=/bin/sh -c 'T=10; until [ $(/bin/cat /proc/net/pf_ring/*-none* 2>/dev/null|/bin/grep "pfring-zc-cluster-%i$"|/usr/bin/wc -l) -gt 0 ] || [ $T -eq 0 ]; do /bin/sleep 1; T=$((T-1)); done' ExecStartPost=/bin/sh -c '/bin/echo "$(/bin/date) cluster %i StartPost" >> /var/log/ntop-systemd.log' ExecStopPost=/usr/local/bin/clusterctl stop-deps %i ExecStopPost=-/bin/rm -rf /run/cluster-%i.conf ExecStopPost=/bin/sh -c '/bin/echo "$(/bin/date) cluster %i StopPost" >> /var/log/ntop-systemd.log' Restart=on-abnormal RestartSec=5 [Install] WantedBy=multi-user.target