Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No ipv6 on default #48

Closed
kaihendry opened this issue Jul 13, 2013 · 15 comments
Closed

No ipv6 on default #48

kaihendry opened this issue Jul 13, 2013 · 15 comments

Comments

@kaihendry
Copy link

This might be related to #34

I uncommented out the IP6=dhcp which should be uncommented out by default IMHO in a fresh netctl 1.1-1.1 install in any case:
http://sprunge.us/OQDf

Yet still systemctl status netctl-ifplugd@eth0.service
http://sprunge.us/jSAR
shows dhcpcd -4qL -t 10 eth0.

@joukewitteveen
Copy link
Owner

There is still very little uptake of IPv6, so it's reasonable to have it commented out by default (besides: it's just an example). Currently, two dhcp clients are started when dhcp is desired for both IPv4 and IPv6. This might not be optimal, but at least allows you to specify different parameters to both clients. One thing that is missing still, is support for dhcpcd for IPv6. It uses dhclient (if you don't have it, you should see a warning in your log: "You need to install dhclient to use DHCPv6").

@kaihendry
Copy link
Author

Ok, I'm fine with ipv6 being disabled by default.

I've now installed dhclient http://sprunge.us/NHXU
And now I have this issue:
ifplugd[116]: client: sysctl: cannot stat /proc/sys/net/ipv6/conf/eth0/accept_ra: No such file or directory
Google doesn't indicate what my problem is here on my Raspberry PI hardware.

Sidenote: I noticed that my systemd ssh-loop.sh service with After=network.target fired before the network was actually ready. Does netctl work with systemd to trigger the network.target?

@joukewitteveen
Copy link
Owner

The error indicates that, somehow, IPv6 is disabled in your setup. Check your kernel command line and your /etc/sysctl.conf. netctl does position itself before network.target, but not with the dynamic services netctl-auto and netctl-ifplugd, because these services cannot guarantee that the network is up after they are started. If you have your cable plugged in anyway, it is probably best to just netctl enable your profile. In that case, the dependencies are resolved the way you expect.

@kaihendry
Copy link
Author

Firstly thank you for taking the time on Saturday to answer my questions Jouke.

Oh yes, ipv6 is ipv6.disable=1 on the /proc/cmdline. Sorry!

@kaihendry
Copy link
Author

I did a netctl enable ethernet-dhcp and now I'm down to one ssh-loop error:
http://sprunge.us/fBAF

What role does ifplugd play (if anything) if I've enabled a wired network profile?

@joukewitteveen
Copy link
Owner

If you enable a profile, it is started automatically at boot. When netctl-ifplugd is enabled on the same interface that the profile is for, both services conflict (a race condition occurs).

Ergo: if you enable a profile for interface eth0, you should disable netctl-ifplugd (and netctl-auto, and any other network management service) on eth0.

@kaihendry
Copy link
Author

Tried disabling the ifplugd and now my machine won't come up after reboot. Woops. I'll fix it on Monday.
http://sprunge.us/NHcX

@joukewitteveen
Copy link
Owner

# systemctl disable netctl-ifplugd@eth0.service
# netctl enable <profile-name>

Don't use systemctl on the netctl@ services and use systemctl --full to display full unit names (the ellipsis ... is not part of the actual unit name).

@kaihendry
Copy link
Author

Hmm, I don't quite understand. http://sprunge.us/DQNK

I seem to have netctl@ethernet\x2ddhcp.service and netctl@ethernetx2ddhcp.service. This is some escaping bug, caused by... ?

@kaihendry
Copy link
Author

[root@pihsg ~]# netctl enable ethernet-dhcp
A unit file for profile 'ethernet-dhcp' already exists

I'm confused if this from systemd or netctl ...

@kaihendry
Copy link
Author

There must be a bug in your enable code, since systemd doesn't like dash. mv ethernet-dhcp ethernetdhcp is how I worked around this.

Now the next problem I have is that it's constantly activating:
http://ix.io/6DZ

@kaihendry
Copy link
Author

Discovered a couple of things

  1. netctl.service is not needed. Seems to try restore a profile and fails. Confusing. :/
  2. If IP6=dhcp is uncommented, the systemd service gets stuck like http://ix.io/6E0
  3. There is definitely a bug with the dash literal and netctl. systemd escapes it as \x2d and netctl gripes there is no profile ethernetx2ddhcp

@joukewitteveen
Copy link
Owner

There is no such bug, escaping is intentional. If a profile is already enabled, you cannot enable it again (reenable is possible, though). Don't use systemctl on netctl@ services, instead use netctl.

@kaihendry
Copy link
Author

I'm back to using netctl-ifplugd@eth0.service since when there is no network cable plugged in with an enabled profile, it just goes crazy:
http://www.youtube.com/watch?v=nbFNG_du0VI

IP6 is commented out in /etc/netctl/ethernetdhcp yet my system seems to get a ipv6 address unexpectedly. I hoped you could toggle ipv6 from netctl, though it seems like you can't?
http://sprunge.us/NTHN

@joukewitteveen
Copy link
Owner

The crazy stuff is new to me, I still think you're doing something wrong. You can disable IPv6 altogether (also SLAAC) by setting IP6=no. Did you read the man pages (netctl(1), netctl.profile(5), and netctl.special(7))?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants