Iptables – restorecon: command not found

Today I got below error when saving iptables on on openvz centos 6 vps.
[bash]
iptables: Saving firewall rules to /etc/sysconfig/iptables: /etc/init.d/iptables: line 268: restorecon: command not found
[/bash]
This is due to the missing restorecon file.
[bash]
root@server [~]# ls -la /sbin/ | grep -i restore
lrwxrwxrwx 1 root root 14 Sep 2 18:55 iptables-restore -> iptables-multi*
lrwxrwxrwx 1 root root 8 Sep 9 23:47 restorecon -> setfiles*
root@server [~]#
[/bash]

Solution:
Install the policycoreutils package
[bash]
yum install policycoreutils
[/bash]


Comments

Leave a Reply

Your email address will not be published. Required fields are marked *


four − 1 =