networkd vs. netctl

This forum is for topics specific to the Raspberry Pi and Arch Linux ARM

networkd vs. netctl

Postby dsc3507 » Tue Mar 17, 2015 5:31 am

In a new install of archlinux - 3.18.9-2 I found that static IP was not working properly using netctl. It would always configure a DHCP address as well as static if static was defined in /etc/netctl/eth0.

I came to find out that there was a file in /etc/systemd/network named 'eth0.network' defining 'dhcp=both'

Exactly how that file got there I don't know as it was not in a beaglebone black install of kernel 3.16 era.

This was assigning a DHCP address and then netctl was assigning a static IP address as defined in /etc/netctl/eth0 Both addresses worked and were listed in 'ip addr show'

My question in all this is what is the best way to init DHCP/Static wired/wireless IP at boot. I suspect the answer is netctl after getting networkd out of the way by not defining anything for the interface in its configure directories.

I did find networkd to be faster - ip address assignment seemed quicker at boot vs doing it in netctl.

What is the case for doing it in one vs. the other? Are there any docs that explain this?
dsc3507
 
Posts: 13
Joined: Sat Apr 12, 2014 5:07 pm

Re: networkd vs. netctl

Postby WarheadsSE » Tue Mar 17, 2015 1:27 pm

Wiki.

As for not using one or the other? Disable their systemd services, and viola. Yanking profile files is not the right way to go, as it will still attempt to run, throw errors and false flags.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: networkd vs. netctl

Postby dsc3507 » Tue Mar 17, 2015 4:15 pm

I guess I don't understand your reply. The file in question was not in a prior install of Archlinux. It was causing a conflict between the networkd and netctl services.

Are you telling me I do not need the networkd service. That I could just enable the netctl service? I was under the assumption that networkd was required.
dsc3507
 
Posts: 13
Joined: Sat Apr 12, 2014 5:07 pm

Re: networkd vs. netctl

Postby WarheadsSE » Tue Mar 17, 2015 5:15 pm

The newer tarballs (fresh installs) SHIP with systemd-networkd enabled in place of netctl. So, no, it is not causing a conflict until you change the configuration of the system. Even then, you're the one that didn't disable one to use the other, or verify what was getting you DHCP functionality in the first place.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: networkd vs. netctl

Postby dsc3507 » Tue Mar 17, 2015 5:44 pm

I do not remember enabling netctl but perhaps I did. I understand now. It is important to check enabled services before enabling other competing services.
dsc3507
 
Posts: 13
Joined: Sat Apr 12, 2014 5:07 pm

Re: networkd vs. netctl

Postby dsc3507 » Wed Mar 18, 2015 1:27 am

OK carrying this a little further. It appears that networkd needs to be running for timesyncd to function properly.

First of all is this always the case? If it is then is there a conflict between networkd and netctl?

If I have networkd running do I need netctl? Does networkd supply all the functionality of netctl at this time (3.18-9 kernel) ? That is can it be made to work well for static or DHCP both wired and wireless? I have to handle all these possibilities on the system but nothing more exotic.
dsc3507
 
Posts: 13
Joined: Sat Apr 12, 2014 5:07 pm


Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 6 guests