1

Simple question: i want to load two modules

/usr/sbin/modprobe ip_nat_ftp 
/usr/sbin/modprobe ip_conntrack_ftp

I can put those lines in rc.local or use /etc/sysconfig/iptables-config But at reboot firewalld overwrite my choices and doesn't load modules Question : how to instructe firewalld to load those two modules?

marked as duplicate by garethTheRed, don_crissti, roaima, Ramesh, G-Man Nov 1 '15 at 20:15

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

3

Centos 7 uses systemd, so files named *.conf in /etc/modules-load.d/ can be used to configure which kernel modules are loaded at boot.

e.g.

echo ip_nat_ftp > /etc/modules-load.d/iptables.conf
echo ip_conntrack_ftp >> /etc/modules-load.d/iptables.conf

You can specify any options for those modules or blacklist unwanted modules using the usual /etc/modprobe.d/*.conf method.

See man 5 modules-load.d, man 5 modprobe.d and man 8 systemd-modules-load.service for more details.


PS: in debian and derivatives, you can just list them one-per-line in /etc/modules. /etc/modprobe.d/*.conf is also used to specify module options and blacklisting.

  • I like this solution,i try after a reload of firewall zone – elbarna Nov 1 '15 at 1:29

Not the answer you're looking for? Browse other questions tagged or ask your own question.