LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-25-2014, 07:47 PM   #1
ASTRAPI
Member
 
Registered: Feb 2007
Posts: 210

Rep: Reputation: 16
Question How can i disbale ipv6 on Centos 6.6


Hi

How can i disbale ipv6 on Centos 6.6 ?

Thanks
 
Old 12-25-2014, 07:57 PM   #2
Head_on_a_Stick
Senior Member
 
Registered: Dec 2014
Location: London, England
Distribution: Arch & Debian
Posts: 1,183

Rep: Reputation: 283Reputation: 283Reputation: 283
I don't use CentOS, but I think this will work if you add it to your kernel command line parameters:
Code:
ipv6.disable=1
 
Old 12-25-2014, 08:32 PM   #3
ASTRAPI
Member
 
Registered: Feb 2007
Posts: 210

Original Poster
Rep: Reputation: 16
No idea how to do it
 
Old 12-25-2014, 10:10 PM   #4
veerain
Senior Member
 
Registered: Mar 2005
Location: Earth bound to Helios
Distribution: Custom
Posts: 2,524

Rep: Reputation: 319Reputation: 319Reputation: 319Reputation: 319
Use sysctl command to do it.
 
Old 12-25-2014, 10:40 PM   #5
ASTRAPI
Member
 
Registered: Feb 2007
Posts: 210

Original Poster
Rep: Reputation: 16
How?

It seems that Centos server 6.6 is trying to use always ipv6 (don't know why) and not ipv4
 
Old 12-26-2014, 06:39 AM   #6
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,331
Blog Entries: 55

Rep: Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530
Quote:
Originally Posted by ASTRAPI View Post
How?
If you don't know what to look for and somebody gave you a hint then first reflex should be to use the standard local "which", "whatis", "whereis" and "locate" commands, or (the local copy of) the CentOS documentation and search LQ before resorting to using an online search engine. This is efficient. In your case the CentOS FAQ has an appropriate entry: http://wiki.centos.org/FAQ/CentOS6#h...6a8a10d41781df .
 
Old 12-26-2014, 10:24 AM   #7
ASTRAPI
Member
 
Registered: Feb 2007
Posts: 210

Original Poster
Rep: Reputation: 16
Ok thanks

Is there any other way to force all connections to use ipv4?

As if i use wget is not working for a file link and if i use wget -4 is working great for the same file link ?
 
Old 12-26-2014, 11:30 AM   #8
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,331
Blog Entries: 55

Rep: Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530Reputation: 3530
Quote:
Originally Posted by ASTRAPI View Post
if i use wget is not working for a file link and if i use wget -4 is working great for the same file link ?
That means you have not disabled IPv6 properly. (Re-)check /proc/cmdline, sysctl and /etc/sysctl.conf, (if|iw)config, lsmod, any /etc/mod*/ output / contents for anything IPv6-related.
 
Old 12-26-2014, 04:05 PM   #9
ASTRAPI
Member
 
Registered: Feb 2007
Posts: 210

Original Poster
Rep: Reputation: 16
I mean to do this with ipv6 enabled....
 
Old 12-26-2014, 05:39 PM   #10
luvzlinux
LQ Newbie
 
Registered: Dec 2014
Posts: 3

Rep: Reputation: Disabled
There are a few ways to do this (ranging from simple to complex), including:

1. Adjust network settings.
2. Use /etc/sysctl.conf to adjust /proc/sys/ kernel parameters.
3. Blacklist kernel modules associated with IPv6.

Option 1: Adjust network settings

Add/ensure "NETWORKING_IPV6=no" to /etc/sysconfig/network
Add/ensure "IPV6INIT=no" to /etc/sysconfig/network-scripts/ifcfg-eth0 or similar (depending on interface).

Option 2: Adjust /etc/sysctl.conf

Add/ensure "net.ipv6.conf.default.disable_ipv6 = 1" is in /etc/sysctl.conf
Run "sysctl -p" to apply this changed setting from /etc/sysctl.conf configuration file
Alternatively, "echo 1> /proc/sys/net/ipv6/conf/default/disable_ipv6" ... but this won't persist after reboot.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Disable IPv6 From CentOS 7 carlosinfl CentOS 2 11-19-2014 04:49 PM
IPv6 en Centos Marco Gualpa Linux - Server 1 07-15-2014 02:43 AM
Disbale IPv6 Debain 7.0 installation shorto Linux - Networking 1 06-13-2013 06:01 PM
centOS 6 IPv6 openvz ciscllc Linux - Server 0 02-14-2013 02:44 PM
IPv6 appearing in CentOS snq Linux - Networking 3 11-24-2010 09:19 AM


All times are GMT -5. The time now is 07:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration