Hi Peter,
Thank you very much. After it is included in draft-ietf-lsr-dynamic-flooding, we can work together to reduce the side effect. Best Regards, Huaimo ________________________________ From: Peter Psenak <ppse...@cisco.com> Sent: Friday, May 24, 2019 5:35 AM To: Huaimo Chen; Tony Li; lsr@ietf.org Subject: Re: [Lsr] Enhancements on encoding of router IDs and DR IDs Hi Huaimo, thanks for the suggestion, I think it's good one to include. One side effect of your proposal is that when the new ID or DR ID is inserted, it may cause other IDs/DR IDs to change their index, as you can not assume you can simply add to the end of the list anymore. thanks, Peter On 23/05/2019 20:47 , Huaimo Chen wrote: > Hi Tony, > > > Enhancements on encoding the IDs are described below for > discussions. A .pdf file is attached in the case that the formats below > are messed up. > > > Currently for OSPFv2, OSPFv2 Area Router IDs TLVs are used to represent > a sequence of router IDs or DR IDs (addresses). Each of IDs is encoded > as an OSPFv2 Router IDs TLV Entry of 8 bytes. > > 0 1 2 3 > > 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Conn Type | Reserved | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Originating Router ID/DR Address (4 bytes) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > (Current) OSPFv2 Router IDs TLV Entry > > > > To represent N router IDs or DR addresses, we need N entries, which > occupies 8*N bytes in the OSPFv2 Area Router IDs TLVs. Each entry > represents just only one router ID or DR address. > > > > An enhancement below is to allow one entry to represent a number of > router IDs or a number of DR addresses. This can be achieved by using > two bytes of the Reserved field to indicate the number M of router IDs > or a number of DR addresses contained in the entry. The value of the > two bytes can be the number of IDs/Addresses (i.e., M) or the number of > octets used (i.e., 4*M). The former is preferred. > > > > 0 1 2 3 > > 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Conn Type | NumberOfIDs (M) | Reserved | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 1st Originating Router ID/DR Address (4 bytes) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 2nd Originating Router ID/DR Address (4 bytes) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | | > > ~ . . . . . . ~ > > | | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | M-th Originating Router ID/DR Address (4 bytes) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > (Enhanced) OSPFv2 Router IDs TLV Entry > > > > To represent N router IDs or N DR addresses using the enhanced entry, we > need just one or a few entries. Using X entries occupies 4*(N + X) bytes > in the OSPFv2 Area Router IDs TLVs. > > > > Consider the case where there are 1000 routers in an area. To represent > 1000 router IDs, > > Using the current OSPFv2 Router IDs TLV Entries occupies 8*1000 = 8000 > bytes; > > Using the enhanced OSPFv2 Router IDs TLV Entries occupies 4*(1000 + 1) = > 4004 bytes. > > 8000/4004 = 1..998. The saving on space is about 50% in this case. > > > > Similarly for OSPFv3, OSPFv3 Area Router IDs TLVs are used to represent > a sequence of router IDs or DR IDs. Each of router IDs is encoded as an > OSPFv3 Router IDs TLV Entry of 8 bytes. Each of DR IDs is encoded as an > OSPFv3 Router IDs TLV Entry of 12 bytes. > > > > 0 1 2 3 > > 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Conn Type | Reserved | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Originating Router ID (always present) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Interface ID (present for DRs) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > (Current) OSPFv3 Router IDs TLV Entry > > > > An enhancement below is to allow one entry to represent a number of > router IDs or a number of DR IDs. This can be achieved by using two > bytes of the Reserved field to indicate the number M of router IDs or a > number of DR IDs contained in the entry. The value of the two bytes can > be the number of IDs (i.e., M) or the number of octets used (i.e., 4*M > for M router IDs or 8*M for M DR IDs). The former is preferred. > > > > 0 1 2 3 > > 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | Conn Type | NumberOfIDs (M) | Reserved | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 1st Originating Router ID (always present) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 1st Interface ID (present for DRs) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 2nd Originating Router ID (always present) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | 2nd Interface ID (present for DRs) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | | > > ~ . . . . .. . ~ > > | | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | M-th Originating Router ID (always present) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > | M-th Interface ID (present for DRs) | > > +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ > > (Enhanced) OSPFv3 Router IDs TLV Entry > > > > > Best Regards, > > Huaimo > > > > _______________________________________________ > Lsr mailing list > Lsr@ietf.org > https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.ietf.org%2Fmailman%2Flistinfo%2Flsr&data=02%7C01%7Chchen%40futurewei.com%7Ca64e7494268f40814a5208d6e02b3cbe%7C0fee8ff2a3b240189c753a1d5591fedc%7C1%7C0%7C636942873655794273&sdata=96k2VMi7zhftIeoZFfcHJpsyX2UdII6R2LbOvLpBFIY%3D&reserved=0 >
_______________________________________________ Lsr mailing list Lsr@ietf.org https://www.ietf.org/mailman/listinfo/lsr