设置 mlvpn 环境时出错 - 隧道启动时遇到问题

设置 mlvpn 环境时出错 - 隧道启动时遇到问题

陣容隧道两侧均无法通行。每次都出现设备或资源繁忙错误。

配置如下:

  • 这是客户端的文件mlvpn.conf

    [general]
    statuscommand = "/etc/mlvpn/mlvpn0_updown.sh"
    tuntap = "tun"
    mode = "client"
    interface_name = "mlvpn0"
    timeout = 30
    password = "you have not changed me yet?"
    reorder_buffer_size = 64
    loss_tolerence = 50
    
    [filters]
    
    [adsl1]
    bindhost = "172.20.10.22"
    remotehost = "server ip"
    remoteport = 5080
    
    [adsl2]
    bindhost = "192.168.42.130"
    remotehost = "server_ip"
    remoteport = 5081
    
  • 这是 updown 脚本:

    #!/bin/bash
    error=0; trap "error=$((error|1))" ERR
    
    tuntap_intf="$1"
    newstatus="$2"
    rtun="$3"
    
    [ -z "$newstatus" ] && exit 1
    
    (
    if [ "$newstatus" = "tuntap_up" ]; then
        echo "$tuntap_intf setup"
        /sbin/ip link set dev $tuntap_intf mtu 1400 up
        /sbin/route add proof.ovh.net dev $tuntap_intf
    elif [ "$newstatus" = "tuntap_down" ]; then
        echo "$tuntap_intf shutdown"
        /sbin/route del proof.ovh.net dev $tuntap_intf
    elif [ "$newstatus" = "rtun_up" ]; then
        echo "rtun [${rtun}] is up"
    elif [ "$newstatus" = "rtun_down" ]; then
        echo "rtun [${rtun}] is down"
    fi
    ) >> /var/log/mlvpn_commands.log 2>&1
    
    exit $errors
    

这些是我的错误:

    mlvpn0:tun or device or resource busy.

相关内容