Saturday, October 3, 2020

One method to disable IPv6 with Linux

One method to disable IPv6 with Linux Mint is to use the following commands.

sudo nano /etc/sysctl.conf

Add the following lines to the bottom of the file and save it:

# IPv6 disabled
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1

Restart sysclt using the following command:

sudo sysctl -p

If IPv6 is still enabled after rebooting, you create the file /etc/rc.local and and use the following lines:

#!/bin/bash
# /etc/rc.local

/etc/sysctl.d
/etc/init.d/procps restart

exit 0

Use chmod command to make the file executable:

sudo chmod 755 /etc/rc.local

To manually disable IPv6, use the commands below:

sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.default.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.lo.disable_ipv6=1

http://itsfoss.com/disable-ipv6-ubuntu-linux

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.