I noticed that disabling IPv6 on the VPS network interfaces makes resolving some websites faster. In my particular case, I have a web app on the VPS that connects to an external website and grabs data via the API. When I tried running the web app it would take about 10-20 seconds for the page to load and after some investigation it appears that disabling IPv6 on the interfaces made the web app load in 2-3 seconds.
The first thing to do is check whether the interfaces on the VPS server is actually using IPv6. Just issue ifconfig -a on the terminal as root or su:
To disable IPv6 on all the network interfaces (disabling on just the main interface didn’t help – I had to disable on all interfaces) on a CentOS system you need to do add the following code in the /etc/sysctl.conf file:
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
Just like this.
Restart the VPS and then check again the ifconfig -a to see if it’s removed the IPv6 addresses from the interfaces:
Test and see if it the speed is faster. I hope this helps.
If this article helped you in any way and you want to show your appreciation, I am more than happy to receive donations through PayPal. This will help me maintain and improve this website so I can help more people out there. Thank you for your help.
HELP OTHERS AND SHARE THIS ARTICLE
LEAVE A COMMENT
I am an entrepreneur based in Sydney Australia. I was born in Vietnam, grew up in Italy and currently residing in Australia. I started my first business venture Advertise Me from a random idea and have never looked back since. My passion is in the digital space, affiliate marketing, fitness and I launched several digital products. You will find these on the portfolio page.
I’ve decided to change from a Vegetarian to a Vegan diet and started a website called Veggie Meals.
I started this blog so I could leave a digital footprint of my random thoughts, ideas and life in general.
If any of the articles helped you in any way, please donate. Thank you for your help.
Affiliate Compensated: there are some articles with links to products or services that I may receive a commission.