Solved how to add ipv6 address to my vm switch in freebsd14.2 bhyve ?

Dear all:
i have used freebsd14.2 vm-bhyve to create a vm switch fellow below command,
#vm switch create -a 288e:4555:2288:3200::1/64 public
#/usr/local/sbin/vm: ERROR: address must be supplied in CIDR notation (a.b.c.d/prefix-len)

when i want to add ipv6 address to vm switch public . how to do that ? thanks.

vm switch create -a 192.168.122.1/24 public ... add ipv4 to public switch was ok. i just want to add ipv4 and ipv6 to public switch in the same time. thanks.
 
It seems the code in /usr/local/lib/vm-bhyve/vm-switch only accepts IPv4 addresses:
Code:
    # check address
    if [ -n "${_addr}" ]; then
        echo "${_addr}" | egrep -qs '^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\/[0-9]{1,2}$'
        [ $? -eq 0 ] || util::err "address must be supplied in CIDR notation (a.b.c.d/prefix-len)"
    fi
 
It seems the code in /usr/local/lib/vm-bhyve/vm-switch only accepts IPv4 addresses:
Code:
    # check address
    if [ -n "${_addr}" ]; then
        echo "${_addr}" | egrep -qs '^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\/[0-9]{1,2}$'
        [ $? -eq 0 ] || util::err "address must be supplied in CIDR notation (a.b.c.d/prefix-len)"
    fi
Dear sirdice:
thanks for your reply .. but i have saw somebody did this in below link. please check it .thanks.
 
Back
Top