Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
ubuntu@chonk:~$ sudo systemctl status snap.conjure-up.bridge.service
● snap.conjure-up.bridge.service - Service for snap application conjure-up.bridge
Loaded: loaded (/etc/systemd/system/snap.conjure-up.bridge.service; enabled; vendor preset: enabled)
Active: inactive (dead) since Thu 2017-02-16 20:32:12 UTC; 2min 27s ago
Process: 1400 ExecStop=/usr/bin/snap run --command=stop conjure-up.bridge (code=exited, status=0/SUCCESS)
Process: 1208 ExecStart=/usr/bin/snap run conjure-up.bridge (code=exited, status=0/SUCCESS)
Main PID: 1208 (code=exited, status=0/SUCCESS)
Feb 16 20:32:11 chonk snap[1208]: + iptables -I FORWARD -i conjureup0 -j ACCEPT
Feb 16 20:32:11 chonk snap[1208]: + iptables -I FORWARD -o conjureup0 -j ACCEPT
Feb 16 20:32:11 chonk snap[1208]: + iptables -t nat -A POSTROUTING -s 10.99.0.1/24 ! -d 10.99.0.1/24 -j MASQUERADE
Feb 16 20:32:11 chonk snap[1208]: + iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 53 -j ACCEPT
Feb 16 20:32:11 chonk snap[1208]: + iptables -I INPUT -i conjureup0 -p udp -m udp --dport 53 -j ACCEPT
Feb 16 20:32:11 chonk snap[1208]: + iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 67 -j ACCEPT
Feb 16 20:32:11 chonk snap[1208]: + iptables -I INPUT -i conjureup0 -p udp -m udp --dport 67 -j ACCEPT
Feb 16 20:32:11 chonk /usr/bin/snap[1400]: cmd.go:105: DEBUG: restarting into "/snap/core/current/usr/bin/snap"
Feb 16 20:32:11 chonk /usr/bin/snap[1400]: cmd.go:59: DEBUG: re-exec disabled by user
Feb 16 20:32:12 chonk systemd[1]: Started Service for snap application conjure-up.bridge.
ubuntu@chonk:~$ sudo /usr/bin/snap run conjure-up.bridge
+ ip link add dev conjureup0 type bridge
RTNETLINK answers: File exists
+ true
+ ip addr add 10.99.0.1/24 dev conjureup0
RTNETLINK answers: File exists
+ true
+ ip link set dev conjureup0 up
+ iptables -I FORWARD -i conjureup0 -j ACCEPT
+ iptables -I FORWARD -o conjureup0 -j ACCEPT
+ iptables -t nat -A POSTROUTING -s 10.99.0.1/24 ! -d 10.99.0.1/24 -j MASQUERADE
+ iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 53 -j ACCEPT
+ iptables -I INPUT -i conjureup0 -p udp -m udp --dport 53 -j ACCEPT
+ iptables -I INPUT -i conjureup0 -p tcp -m tcp --dport 67 -j ACCEPT
+ iptables -I INPUT -i conjureup0 -p udp -m udp --dport 67 -j ACCEPT
ubuntu@chonk:~$ ifconfig
conjureup0 Link encap:Ethernet HWaddr ee:4d:5e:9e:b4:8a
inet addr:10.99.0.1 Bcast:0.0.0.0 Mask:255.255.255.0
inet6 addr: fe80::ec4d:5eff:fe9e:b48a/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:828 (828.0 B)
eth0 Link encap:Ethernet HWaddr ec:a8:6b:fe:15:75
inet addr:172.16.0.13 Bcast:172.16.0.255 Mask:255.255.255.0
inet6 addr: fe80::eea8:6bff:fefe:1575/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1122 errors:0 dropped:0 overruns:0 frame:0
TX packets:1229 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:132171 (132.1 KB) TX bytes:185412 (185.4 KB)
Interrupt:20 Memory:f7c00000-f7c20000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:1 errors:0 dropped:0 overruns:0 frame:0
TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1
RX bytes:88 (88.0 B) TX bytes:88 (88.0 B)
ubuntu@chonk:~$ iptables -L -t nat
iptables v1.6.0: can't initialize iptables table `nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
ubuntu@chonk:~$ sudo iptables -L -t nat
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
MASQUERADE all -- 10.99.0.0/24 !10.99.0.0/24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment