I am trying to configure a gre tunnel between two Ubuntu PCs: 1st with wlan1 interface 192.168.1.51 and 2nd with wlan2 192.168.1.2.
ip link add gre1 type gretap remote 192.168.1.2 local 192.168.1.51 ip link set dev gre1 up [email protected]: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1462 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 1000 link/ether 92:d0:28:8b:3e:a6 brd ff:ff:ff:ff:ff:ff promiscuity 0 gretap remote 192.168.1.2 local 192.168.1.51 ttl inherit
ip link add gre1 type gretap remote 192.168.1.51 local 192.168.1.2 ip link set dev gre1 up 7: [email protected]: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1462 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 1000 link/ether ba:09:9a:66:85:02 brd ff:ff:ff:ff:ff:ff promiscuity 0 gretap remote 192.168.1.51 local 192.168.1.2 ttl inherit
But when I ping from .51 to .2, I don’t see any GRE encapsulation. It is just going over wlan interface.
10.1.0.0/16 dev eth0 proto kernel scope link src 10.1.0.51 metric 1 192.168.1.0/24 dev wlan1 proto kernel scope link src 192.168.1.51
i know this is an old question, but looking for something else, i found this and decided to answer.
Long story short, it doesn't work that way.
bit longer of an answer: both ends need separate IPs: the tunnel endpoints would get a more different IP than the WLAN addresses. So, you have 192.168.1.0/24 as your main (physical) network. you would then have, say, 10.0.0.0/24 as your virtual (GRE) network. if you give the gre1 interfaces an ip in the 10.0.0.0/24 subnet, and ping then, they will go over GRE links then. watching traffic on the wlan connections should then show you the GRE encapsulation.
Answered by TiernanO on December 6, 2020
1 Asked on September 14, 2020 by young_souvlaki
2 Asked on September 14, 2020 by skg
5 Asked on September 13, 2020 by user394
1 Asked on September 10, 2020 by ansgar
1 Asked on September 7, 2020 by tsm
2 Asked on September 4, 2020 by fivedogit
0 Asked on September 3, 2020 by rohit-pillai
0 Asked on September 1, 2020 by hba
1 Asked on August 29, 2020 by paddy
0 Asked on August 28, 2020 by yeremia-danang
2 Asked on August 27, 2020 by roman
2 Asked on August 27, 2020 by indranil
1 Asked on August 24, 2020 by saurav-raj-joshi
2 Asked on August 20, 2020 by myndstream
0 Asked on August 18, 2020 by harriet
1 Asked on August 17, 2020 by fidodido
Get help from others!