systemd-networkd DHCPServer configuring static lease












1














Does systemd-networkd DHCPServer support configure static lease based on for example mac addresses? If yes how? The systemd-networkd documentation doesn't mention anything about it.










share|improve this question






















  • Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
    – RubberStamp
    Dec 22 '18 at 0:45










  • Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
    – R.J
    Dec 23 '18 at 11:07
















1














Does systemd-networkd DHCPServer support configure static lease based on for example mac addresses? If yes how? The systemd-networkd documentation doesn't mention anything about it.










share|improve this question






















  • Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
    – RubberStamp
    Dec 22 '18 at 0:45










  • Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
    – R.J
    Dec 23 '18 at 11:07














1












1








1


1





Does systemd-networkd DHCPServer support configure static lease based on for example mac addresses? If yes how? The systemd-networkd documentation doesn't mention anything about it.










share|improve this question













Does systemd-networkd DHCPServer support configure static lease based on for example mac addresses? If yes how? The systemd-networkd documentation doesn't mention anything about it.







ip dhcp systemd-networkd






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Dec 21 '18 at 18:32









R.J

212




212












  • Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
    – RubberStamp
    Dec 22 '18 at 0:45










  • Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
    – R.J
    Dec 23 '18 at 11:07


















  • Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
    – RubberStamp
    Dec 22 '18 at 0:45










  • Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
    – R.J
    Dec 23 '18 at 11:07
















Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
– RubberStamp
Dec 22 '18 at 0:45




Haven't tried but... perhaps use a [Match] section with a MACAddress= line to configure static leases. Seems cumbersome, but perhaps that's the basic methodology.
– RubberStamp
Dec 22 '18 at 0:45












Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
– R.J
Dec 23 '18 at 11:07




Doesn't seem so. According to the systemd.network documentation, MATCH section option is only to determine which interface(s) the network file should apply to. I don't think it makes sense if I use it before or after DHCPServer option.
– R.J
Dec 23 '18 at 11:07










1 Answer
1






active

oldest

votes


















0














Use man dhcpd.conf to confirm that this still works on systemd based systems, but, at least in older initd systems, you can use:



host hostname {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address x.x.x.x;
}


within the subnet to reserve that address for the given MAC. Since this is a function of dhcpd.conf, it probably has not changed.






share|improve this answer





















  • Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
    – R.J
    Dec 23 '18 at 11:13











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f490370%2fsystemd-networkd-dhcpserver-configuring-static-lease%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Use man dhcpd.conf to confirm that this still works on systemd based systems, but, at least in older initd systems, you can use:



host hostname {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address x.x.x.x;
}


within the subnet to reserve that address for the given MAC. Since this is a function of dhcpd.conf, it probably has not changed.






share|improve this answer





















  • Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
    – R.J
    Dec 23 '18 at 11:13
















0














Use man dhcpd.conf to confirm that this still works on systemd based systems, but, at least in older initd systems, you can use:



host hostname {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address x.x.x.x;
}


within the subnet to reserve that address for the given MAC. Since this is a function of dhcpd.conf, it probably has not changed.






share|improve this answer





















  • Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
    – R.J
    Dec 23 '18 at 11:13














0












0








0






Use man dhcpd.conf to confirm that this still works on systemd based systems, but, at least in older initd systems, you can use:



host hostname {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address x.x.x.x;
}


within the subnet to reserve that address for the given MAC. Since this is a function of dhcpd.conf, it probably has not changed.






share|improve this answer












Use man dhcpd.conf to confirm that this still works on systemd based systems, but, at least in older initd systems, you can use:



host hostname {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address x.x.x.x;
}


within the subnet to reserve that address for the given MAC. Since this is a function of dhcpd.conf, it probably has not changed.







share|improve this answer












share|improve this answer



share|improve this answer










answered Dec 21 '18 at 18:48









Xalorous

24218




24218












  • Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
    – R.J
    Dec 23 '18 at 11:13


















  • Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
    – R.J
    Dec 23 '18 at 11:13
















Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
– R.J
Dec 23 '18 at 11:13




Problem is, I moved from dhcpd to systemd.network only some time ago because of simplicity and systemd integration. But it seems despite it supports configuring dhcp server for an interface, it doesn't have many configurations that was supported by other dhcp servers like dhcpd.
– R.J
Dec 23 '18 at 11:13


















draft saved

draft discarded




















































Thanks for contributing an answer to Unix & Linux Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f490370%2fsystemd-networkd-dhcpserver-configuring-static-lease%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Morgemoulin

Scott Moir

Souastre