Skip to content

Conversation

chain710
Copy link

@chain710 chain710 commented Jan 6, 2023

在x86路由环境下clash重启过程中偶尔出现错误:Start TUN listening error: configure tun interface: file exists
问题来源如下

	if len(t.options.Inet4Address) > 0 {
		for _, address := range t.options.Inet4Address {
			addr4, _ := netlink.ParseAddr(address.String())
			err = netlink.AddrAdd(tunLink, addr4)
			if err != nil {
				return err
			}
		}
	}

netlink.AddrAdd不知为何地址已存在

此PR未对addr已存在原因做分析,仅将AddrAdd替换为AddrReplace,可绕过该问题

…Replace

- add more error info to help diagnose
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant