[Nfd-dev] Changing the MTU size

Aboodi Ahed Hussein Ali aboodi at student.usm.my
Thu Nov 7 08:18:04 PST 2019


That is really helpful, thank you very much, Davide. Yes, it works for me, although It will be better if NDN has the possibility to addresses that in nfd.conf.

Now, the mtu for ethernet multicast is 105 and the UDP multicast is 8800. Besides, I can use the IP traffic normally with mtu = 1298.

Thanks again Davide,

Ahed

________________________________
From: Davide Pesavento <davidepesa at gmail.com>
Sent: Thursday, November 7, 2019 11:41 PM
To: Aboodi Ahed Hussein Ali <aboodi at student.usm.my>
Cc: <nfd-dev at lists.cs.ucla.edu> <nfd-dev at lists.cs.ucla.edu>
Subject: Re: [Nfd-dev] Changing the MTU size

Correct. That would affect all multicast faces (side note: TCP
multicast doesn't exist). Unicast faces would not be affected.

If you want to use different MTUs for UDP multicast vs Ethernet
multicast, the (now even uglier) hack becomes as follows:

1. make sure there are *no* IP addresses on the interface(s) that you
want to use with NDN/UDP multicast.
2. set the interface MTU to whatever you need for NDN over ethernet
mcast traffic
3. start NFD
4. set the interface MTU to whatever you need for NDN over UDP mcast traffic
5. configure whatever IP address(es) you need on the interface(s),
this will trigger NFD to create UDP multicast faces as needed
6. set the interface MTU to the original value prior to step 1, or to
whatever you need for non-NDN traffic

Again, this is completely untested. You can verify the MTUs of the
various faces are correct with 'nfdc face list'.

Davide

On Thu, Nov 7, 2019 at 10:26 AM Aboodi Ahed Hussein Ali
<aboodi at student.usm.my> wrote:
>
> If I get that correctly, TCP and UDP multicast faces will be affected too. if yes, how can I make it works only for ethernet multicast face and not affecting the other faces created at start-up?
>
> Thank you,
> Ahed
> ________________________________
> From: Davide Pesavento <davidepesa at gmail.com>
> Sent: Thursday, November 7, 2019 11:16 PM
> To: Aboodi Ahed Hussein Ali <aboodi at student.usm.my>
> Cc: Junxiao Shi <shijunxiao at email.arizona.edu>; <nfd-dev at lists.cs.ucla.edu> <nfd-dev at lists.cs.ucla.edu>
> Subject: Re: [Nfd-dev] Changing the MTU size
>
> Ahed,
>
> Given that NFD does not currently react to MTU changes of the
> underlying network interface while running, you could use the
> following (untested) hack:
>
> 1. set the interface MTU to 127, or whatever you need for NDN traffic
> 2. start NFD
> 3. set the interface MTU back to 1500, or whatever it was prior to step 1
>
> Now NFD should be using an MTU of 127 for the ethernet face, while IP
> traffic will use 1500.
> As I said, this is an ugly hack and it will stop working when we fix
> issue #3257 in NFD (https://redmine.named-data.net/issues/3257).
>
> Hope that helps!
>
> Davide
>
> On Wed, Nov 6, 2019 at 2:35 PM Aboodi Ahed Hussein Ali
> <aboodi at student.usm.my> wrote:
> >
> > Actually, I meant I am using the same RavenUSB-Stick adapter for both traffic, NDN and IPV6/4.
> > ________________________________
> > From: Junxiao Shi <shijunxiao at email.arizona.edu>
> > Sent: Thursday, November 7, 2019 3:33 AM
> > To: Aboodi Ahed Hussein Ali <aboodi at student.usm.my>
> > Cc: <nfd-dev at lists.cs.ucla.edu> <nfd-dev at lists.cs.ucla.edu>
> > Subject: Re: [Nfd-dev] Changing the MTU size
> >
> > Hi Aboodi
> >
> > 'ip link' can set MTU separately for each Ethernet adapter. You can set low MTU on the USB Ethernet adapter only, without affecting traffic on other adapters.
> >
> > Yours, Junxiao
> >
> > On Wed, Nov 6, 2019, 14:28 Aboodi Ahed Hussein Ali <aboodi at student.usm.my> wrote:
> >
> > Hi all,
> >
> > Thank you for your replay Junxiao.
> >
> > The "ip link" command works great when I set the MTU size even to 105 bytes. However, I would prefer to set the MTU within NDN/NFD only, I don't want to force 127/105 mtu to IPV6/4 packets, which I am still using parallel with NDN. I thought we can set NDN packet size using the nfdc command (per face) or the tlv.hpp (general).
> >
> > Just to clarify why I need that, I have connected my Ubuntu with RavenUSB-Stick which is flashed with the Contiki-based 6lowpan communication protocol (802.15.4). The RavenUSB-Stick purports the OS to be an ethernet card and accepts the ethernet frames from the USB port, replace the frame header with 6lowpan header, and then sends it using 805.15.4 radio. It fragments the ethernet packet to 127 using the 6lowpan fragmentation process because the MTU limit for 6lowpan is 127. However, NDN packets cannot be sent (packet ignored for wrong packet type...) using the 6lowpan Contiki code, thus, I modify the code to accept ethernet frame with NDN packet type (when it comes from the OS), and ignore 6lowpan fragmentation as NDN has implemented that in the link-service of NDNLPv2. Therefore, my issue is to make sure that NDN, in my ubuntu, considers the 802.15.4 MTU limit and fragments the NDN packet if bigger than 127bytes. How can I set the MTU for a specific face (e.g. ethernet multicast face) to 127/105? or How to set it generally for NDN/NFD?
> >
> > I am a beginner here, please forgive if I sent to the wrong mailing list.
> >
> > Thank you,
> > Ahed
> > ________________________________
> > From: Junxiao Shi <shijunxiao at email.arizona.edu>
> > Sent: Wednesday, November 6, 2019 7:52 PM
> > To: Aboodi Ahed Hussein Ali <aboodi at student.usm.my>
> > Cc: nfd-dev at lists.cs.ucla.edu <nfd-dev at lists.cs.ucla.edu>
> > Subject: Re: [Nfd-dev] Changing the MTU size
> >
> > Hi Aboodi
> >
> > MTU of Ethernet faces is read from the kernel. You can use ‘ip link’ command to change it before starting NFD.
> >
> > I doubt you can go as low as 127. IPv4 would stop working at that MTU.
> >
> > Yours, Junxiao
> >
> > On Wed, Nov 6, 2019 at 04:05 Aboodi Ahed Hussein Ali <aboodi at student.usm.my> wrote:
> >
> > Hi,
> >
> > I am trying to change the MTU size for the ethernet multicast face (remote=ether://[01:00:5e:00:17:aa]) to 127 but  I am not sure how to do that.
> >
> > I have tried to change the MTU of the multicast face with the below command, but I got "Error 406 when creating face: Cannot create multicast Ethernet faces"
> > The command: nfdc face create remote ether://[01:00:5e:00:17:aa] local dev://ens33 mtu 127
> >
> > I have also tried to change the "MAX_NDN_PACKET_SIZE = 127" in the "~/ndn-cxx/ndn-cxx/encoding/tlv.hpp" but I get a fatal exception, "encodes into 413 octets, exceeding the implementation limit of 127 octets, when I run the "nfd-start".
> >
> > Could you please advise me on how to change it.
> >
> > Thank you,
> > Ahed
> >
> > _______________________________________________
> > Nfd-dev mailing list
> > Nfd-dev at lists.cs.ucla.edu
> > http://www.lists.cs.ucla.edu/mailman/listinfo/nfd-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/nfd-dev/attachments/20191107/b4c2243a/attachment.html>


More information about the Nfd-dev mailing list