Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
d6db3a93
Commit
d6db3a93
authored
Dec 16, 2013
by
Leigh B Stoller
Browse files
Add accept rules to FORWARD table.
parent
744ec52e
Changes
1
Show whitespace changes
Inline
Side-by-side
clientside/tmcc/linux/xen/emulab-tun.pl
View file @
d6db3a93
...
...
@@ -54,6 +54,7 @@ use libsetup;
use
libtmcc
;
use
libutil
;
use
libtestbed
;
use
libgenvnode
;
use
libvnode
;
#
...
...
@@ -93,6 +94,17 @@ sub Online()
mysystem2
("
echo 1 > /proc/sys/net/ipv4/conf/
$vif
/proxy_arp
");
mysystem2
("
$IPBIN
link set
$vif
mtu 1450
");
#
# We need to allow fowarding. vif-bridge does this, but since
# we are doing our own bridge setup, we have to do this here.
#
DoIPtables
("
-A FORWARD -m physdev --physdev-is-bridged --physdev-in
"
.
"
$vif
-j ACCEPT
")
==
0
or
return
-
1
;
DoIPtables
("
-A FORWARD -m physdev --physdev-is-bridged --physdev-out
"
.
"
$vif
-j ACCEPT
")
==
0
or
return
-
1
;
#
# Add the veth to the OVS bridge.
#
...
...
@@ -106,6 +118,11 @@ sub Online()
sub
Offline
()
{
DoIPtables
("
-D FORWARD -m physdev --physdev-is-bridged --physdev-in
"
.
"
$vif
-j ACCEPT
");
DoIPtables
("
-D FORWARD -m physdev --physdev-is-bridged --physdev-out
"
.
"
$vif
-j ACCEPT
");
mysystem2
("
$OVSCTL
del-port
$bridge
$vifname
")
==
0
or
return
-
1
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment