Skip to content

Commit af4e868

Browse files
jvanlieshoutDaanHoogland
authored andcommitted
By preloading some modules we fix two things. 1. Some sysctl settings like ip_conntrack_max are not set during boot because the module is not loaded at that time. 2. Passive ftp does not work through iptables without these modules.
Signed-off-by: Daan Hoogland <daan@onecht.net> (cherry picked from commit bfccf43)
1 parent 5bcd017 commit af4e868

2 files changed

Lines changed: 22 additions & 0 deletions

File tree

‎tools/appliance/definitions/systemvm64template/postinstall.sh‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,13 +188,24 @@ fix_vhdutil() {
188188
chmod a+x /bin/vhd-util
189189
}
190190

191+
# Preload these module otherwise the sysctl settings will not be set, and pasive ftp will not work.
192+
fix_modules() {
193+
cat >> /etc/modules << EOF
194+
nf_conntrack_ipv4
195+
nf_conntrack
196+
nf_conntrack_ftp
197+
nf_nat_ftp
198+
EOF
199+
}
200+
191201
do_fixes() {
192202
fix_nameserver
193203
fix_inittab
194204
fix_acpid
195205
fix_hostname
196206
fix_locale
197207
fix_vhdutil
208+
fix_modules
198209
}
199210

200211
configure_apache2() {

‎tools/appliance/definitions/systemvmtemplate/postinstall.sh‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,13 +178,24 @@ fix_vhdutil() {
178178
chmod a+x /bin/vhd-util
179179
}
180180

181+
# Preload these module otherwise the sysctl settings will not be set, and pasive ftp will not work.
182+
fix_modules() {
183+
cat >> /etc/modules << EOF
184+
nf_conntrack_ipv4
185+
nf_conntrack
186+
nf_conntrack_ftp
187+
nf_nat_ftp
188+
EOF
189+
}
190+
181191
do_fixes() {
182192
fix_nameserver
183193
fix_inittab
184194
fix_acpid
185195
fix_hostname
186196
fix_locale
187197
fix_vhdutil
198+
fix_modules
188199
}
189200

190201
configure_apache2() {

0 commit comments

Comments
 (0)