IPv6 Support in Kasm
By default Kasm does not support IPv6 communication. To enable IPv6 support please follow the procedure below. These steps assume that the VM provider and the providerās virtual network also has both IPv4 and IPv6 support enabled. Typically enabling IPv6 support for a VCN (virtual cloud network) must be done at the time of VNC creation.
Ā Instructions
Ensure that the subnet that has both IPv4 and IPv6 subnets associated with it.
Deploy a VM instance and install Kasm.
Stop Kasm services before enabling IPv6 for Docker and Kasm.
/opt/kasm/bin/stop
Remove any existing docker containers.
sudo docker rm $(sudo docker ps -aq)
Add this to the
/etc/docker/daemon.json
file and restart docker. Create the file if it does not exist.{ "experimental": true, "ip6tables": true }
Restart the docker daemon.
sudo systemctl restart docker
Delete the
kasm_default_network
, recreate it with IPv6 support, and reapply dhclient. The IPv6 subnet can be any valid RFC4193 ULA (Unique Local Address).sudo docker network rm kasm_default_network sudo docker network create --ipv6 --subnet fc00:0:0:1::/64 kasm_default_network sudo dhclient
Confirm the
kasm_default_network
is recreated for docker with IPv6 enabled.This command uses the ājqā utility.
docker network inspect kasm_default_network | jq '.[] | {"Name":.Name, "EnableIPv6":.EnableIPv6}'
This alternate command uses egrep instead of the jq utility.
docker network inspect kasm_default_network | egrep 'Name|EnableIPv6'
Edit the
/opt/kasm/current/docker/docker-compose.yaml
file to enable ipv6 for the Kasm network. Add key-value pair āenable_ipv6: true
" under thenetworks
.kasm_default_network
section.networks: kasm_default_network: external: true enable_ipv6: true
Confirm the
kasm_default_network
is recreated for Kasm with IPv6 enabled.cat /opt/kasm/current/docker/docker-compose.yaml | grep -B5 'enable_ipv6'
Restart Kasm.
sudo /opt/kasm/bin/start
Ā
From this point on workspaces deployed in the kasm_default_network
will get both IPv4 and IPv6 addresses.Ā
Ā
Testing
To validate your changes launch a workspace, then run the following docker inspect command on the kasm agent to view the configuration details of the workspace.
Launch a workspace
Use command
sudo docker ps -a
to get the ācontainer IDā or ācontainer Nameā.Use the following command to view the network configurations for the container.
This command uses the ājqā utility.
sudo docker container inspect CONTAINER_ID | jq '.[].NetworkSettings'
This alternate command uses egrep instead of the jq utility.
sudo docker container inspect CONTAINER_ID | egrep 'IPv6'
The āGlobalIPv6Addressā and āIPv6Gatewayā should be set to an IPv6 address within the subnet specified for the ākasm_default_networkā docker network.
Ā
Ā
Related Docs:
Links to related docs in the kasm_docs project
Ā Related articles
Links to related kb articles in the Confluence project
Ā