emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#64616: closed ([PATCH 0/1] services: static-networking: Add support


From: GNU bug Tracking System
Subject: bug#64616: closed ([PATCH 0/1] services: static-networking: Add support for bonds and vlans)
Date: Wed, 11 Oct 2023 17:02:01 +0000

Your message dated Wed, 11 Oct 2023 19:00:35 +0200
with message-id <87h6mxt7po.fsf@gnu.org>
and subject line Re: [bug#64616] [PATCH v2] services: static-networking: Add 
support for bonding.
has caused the debbugs.gnu.org bug report #64616,
regarding [PATCH 0/1] services: static-networking: Add support for bonds and 
vlans
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
64616: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=64616
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: [PATCH 0/1] services: static-networking: Add support for bonds and vlans Date: Fri, 14 Jul 2023 17:29:58 +0200
Hi Guix!

After new release of guile-netlink, I made some changes on a guix side to be
able to configure bonds and vlans using static-networking declaration.

In short, I introduced two more structures for *matching* existing interfaces:
<network-link-by-macaddress> and <network-link-by-name>. The reason for that
is that <network-link> struct creates new interfaces in network-set-up/linux.
And if we want to construct a bond we need a way to apply settings for
existing interfaces.

With these changes applied, it is passable to do something like this:

(static-networking
 (links (list (network-link
               (name "bond0")
               (type "bond")
               (arguments '((mode . "802.3ad")
                            (miimon . 100)
                            (lacp-active . "on")
                            (lacp-rate . "fast"))))

              (network-link-by-macaddress
               (macaddress "98:11:22:33:44:55")
               (arguments '((master . "bond0"))))
              (network-link-by-macaddress
               (macaddress "98:11:22:33:44:56")
               (arguments '((master . "bond0"))))

              (network-link
               (name "bond0.1055")
               (type "vlan")
               (arguments '((id . 1055)
                            (link . "bond0"))))))
 (addresses (list (network-address
                   (value "192.168.1.4/24")
                   (device "bond0.1055")))))

This example is taken from the test, where I removed interface renaming
step. You should also know that network stack in Qemu won't with this
configuration.  The purpose of the test was to check if the stack has proper
settings.  If it is not enough, Please let me know.  I can try to use
openvswitch for that

There is one thing that bothers me. Here is a comment I put in the code:

It is interesting that "modprobe bonding" creates an interface bond0 straigt
away.  If we won't have bonding module, and execute `ip link add name bond0
type bond' we will get

RTNETLINK answers: File exists

This breaks our configuration if we want to use `bond0' name.  Create (force
modprobe bonding) and delete the interface to free up.  As you can see I
create an interface bond0 (in case some bonds are in configuration). It is
forces netlink to load the bonding module and then delete it to free up the
'name'.

Please let me know what you think.

Alexey Abramov (1):
  services: static-networking: Add support for bonding.

 doc/guix.texi            |  61 ++++++++++++++++-
 gnu/services/base.scm    | 109 +++++++++++++++++++++++++++---
 gnu/tests/networking.scm | 141 +++++++++++++++++++++++++++++++++++++++
 3 files changed, 299 insertions(+), 12 deletions(-)

-- 
2.40.1




--- End Message ---
--- Begin Message --- Subject: Re: [bug#64616] [PATCH v2] services: static-networking: Add support for bonding. Date: Wed, 11 Oct 2023 19:00:35 +0200 User-agent: Gnus/5.13 (Gnus v5.13)
Hi Alexey,

Alexey Abramov <levenson@mmer.org> skribis:

> * gnu/services/base.scm (<network-link>): Add mac-address field. Set
> type field to #f by default, so it won't be mandatory. network-link
> without a type will be used for existing interfaces.
> (assert-network-link-mac-address, mac-address?): Add sanitizer. Allow
> valid mac-address or #f.
> (assert-network-link-type): Add sanitizer. Allow symbol or #f.
> * gnu/services/base.scm (network-set-up/linux,
> network-tear-down/linux): Adapt to new structure.
> * doc/guix.texi (Networking Setup): Document it.
> * gnu/tests/networking.scm (run-static-networking-advanced-test): New
> variable.

Finally applied, thank you!

Ludo’.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]