ufw fails to add MASQUERADE rule
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ufw (Ubuntu) |
Invalid
|
Undecided
|
Jamie Strandboge |
Bug Description
Binary package hint: ufw
I want to enable NAT (more precisely Masquerading) and I followed the example at "man ufw-framework"
root@server:~# tail /etc/ufw/
*nat
:POSTROUTING ACCEPT [0:0]
# Forward traffic through eth0 - Change to match you out-interface
-A POSTROUTING -s 10.10.0.0/16 -o eth0 -j MASQUERADE
# don't delete the 'COMMIT' line or these rules won't be processed
COMMIT
But when I run "ufw enable" I get:
root@wg:~# ufw enable
Command may disrupt existing ssh connections. Proceed with operation (y|n)? y
ERROR: problem running ufw-init # <-- ** This is the error! **
And when I check the nat table there is nothing:
root@server:~# iptables -t nat -L
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination ion.
I am using Lucid beta server edit
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: ufw 0.30pre1-0ubuntu2
ProcVersionSign
Uname: Linux 2.6.32-
Architecture: i386
Date: Mon Mar 29 18:43:07 2010
InstallationMedia: Ubuntu-Server 10.04 "Lucid Lynx" - Beta i386 (20100317)
PackageArchitec
ProcEnviron:
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: ufw
As a temporary workaround I added the following line:
iptables -t nat -A POSTROUTING -s 10.10.0.0/16 -o eth0 -j MASQUERADE
...in /etc/rc.local