Hurricane Electric's IPv6 Tunnel Broker Forums

General IPv6 Topics => IPv6 on Linux & BSD & Mac => Topic started by: sweex on February 06, 2011, 04:18:39 AM

Title: Help needed clearing routing tables.
Post by: sweex on February 06, 2011, 04:18:39 AM
Hy I was experimenting with some different tunnel brokers and was able to configure them but what I didn't found that well is how to delete a specific tunnel or all tunnels.
As you can see I have a bit to much tunnels configured so a little bit of help would be appreciated!
Thanks in advance.
$ ifconfig gif0
gif0: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 1280
inet6 fe80::c62c:3ff:fe2a:4116%gif0 prefixlen 64 scopeid 0x2
inet6 2001:470:1f12:4a6::2 --> 2001:470:1f12:4a6::1 prefixlen 128
inet6 2001:6f8:202:4b5::2 --> 2001:6f8:202:4b5::1 prefixlen 128
inet6 2001:470:1f12:61d::2 --> 2001:470:1f12:61d::1 prefixlen 128

Title: Re: Help needed clearing routing tables.
Post by: cholzhauer on February 06, 2011, 01:42:12 PM
What OS?

Looks like some sort of BSD...

If that's the case, you can just reboot to clear it (as long as you didn't put the info in /etc/rc.conf or /etc/rc.local.

If you've put the information there, just clear it and reboot.
Title: Re: Help needed clearing routing tables.
Post by: sweex on February 06, 2011, 01:49:16 PM
Mac OS X
Thank you but isn't there a command which could help me clear it?
Title: Re: Help needed clearing routing tables.
Post by: cholzhauer on February 06, 2011, 01:51:50 PM
Sure there is.

Why not just reboot?  It's much easier.

I don't know what commands you're trying to "undo", so I'm going to need some more information...what do you want to undo and get rid of?
Title: Re: Help needed clearing routing tables.
Post by: sweex on February 06, 2011, 05:18:26 PM
It seems easier to me to add and delete tunnels to compare them than to add a tunnel reboot and try another one...
But as you can see I configured 4 different tunnels, I would like to be able to delete them and then reconfigure.
Also I have a dynamic IP address so sometimes my IP address changes and therefore my tunnel becomes inactive. So I can get a new one from HE but OS X still uses the first one, even if I add another tunnel.
I hope you get what I'm trying to say.
Title: Re: Help needed clearing routing tables.
Post by: comptech on February 06, 2011, 10:50:52 PM
If you just want to start over again you can use the "ifconfig gif0 destroy" command.  You might also need to delete your default route(s) with "route delete -inet6 default" (I think this is the right command).
Title: Re: Help needed clearing routing tables.
Post by: sweex on February 07, 2011, 03:04:36 AM
Thank you by the time I found out how to delete them one by one,
but with your destroy command I get this :"ifconfig: SIOCIFDESTROY: Invalid argument" error.
Title: Re: Help needed clearing routing tables.
Post by: Randomandy on February 18, 2011, 12:21:42 AM
I've been struggling with this too. I don't have any problem removing tunnels in Linux, but on the Mac it just keeps accumulating addresses. It won't let me destroy and I don't know how to remove them.