To create gretap we must to use ip link instead of ip tunnel. With ip tunnel command possible to create only limited interfaces
vyos@RTR1:~$ sudo ip tunnel help
Usage: ip tunnel { add | change | del | show | prl | 6rd } [ NAME ]
[ mode { ipip | gre | sit | isatap | vti } ] [ remote ADDR ] [ local ADDR ]
...Reproducing steps:
set interfaces tunnel tun1 address '100.64.0.1/24'
set interfaces tunnel tun1 encapsulation 'gre-bridge'
set interfaces tunnel tun1 local-ip '192.168.255.35'
set interfaces tunnel tun1 remote-ip '192.168.255.61'
commit
Traceback (most recent call last):
File "/usr/libexec/vyos/conf_mode/interfaces-tunnel.py", line 196, in <module>
apply(c)
File "/usr/libexec/vyos/conf_mode/interfaces-tunnel.py", line 185, in apply
tun = klass(tunnel['ifname'], **conf)
File "/usr/lib/python3/dist-packages/vyos/ifconfig/tunnel.py", line 68, in __init__
super().__init__(ifname, **config)
File "/usr/lib/python3/dist-packages/vyos/ifconfig/interface.py", line 264, in __init__
self._create()
File "/usr/lib/python3/dist-packages/vyos/ifconfig/tunnel.py", line 76, in _create
self._cmd('{} {}'.format(create.format(**self.config), options))
File "/usr/lib/python3/dist-packages/vyos/ifconfig/control.py", line 51, in _cmd
return cmd(command, self.debug)
File "/usr/lib/python3/dist-packages/vyos/util.py", line 179, in cmd
raise OSError(code, feedback)
OSError: [Errno 255] failed to run command: ip tunnel add tun1 mode gretap local 192.168.255.35 remote 192.168.255.61 ttl 255
returned:
exit code: 255
noteworthy:
cmd 'ip tunnel add tun1 mode gretap local 192.168.255.35 remote 192.168.255.61 ttl 255'
returned (out):
returned (err):
Unknown tunnel mode "gretap"
[[interfaces tunnel tun1]] failed
Commit failed