Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix no standalone lo_v6 entry which break YANG validation #19514

Merged
merged 1 commit into from
Jul 11, 2024

Conversation

wen587
Copy link
Contributor

@wen587 wen587 commented Jul 9, 2024

Why I did it

The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

Work item tracking
  • Microsoft ADO (number only):28665800

How I did it

Add the standalone entry

How to verify it

Manual test in DUT

Before change:

admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}

After change:

admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205
  • 202211
  • 202305

Tested branch (Please provide the tested image version)

Description for the changelog

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@qiluo-msft qiluo-msft merged commit c2055ab into sonic-net:master Jul 11, 2024
21 checks passed
@wen587
Copy link
Contributor Author

wen587 commented Jul 12, 2024

Hi @yxieca , could you help merge to 202311?

mssonicbld pushed a commit to mssonicbld/sonic-buildimage that referenced this pull request Jul 12, 2024
…19514)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202405: #19545

mssonicbld pushed a commit to mssonicbld/sonic-buildimage that referenced this pull request Jul 12, 2024
…19514)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202311: #19546

mssonicbld pushed a commit to mssonicbld/sonic-buildimage that referenced this pull request Jul 12, 2024
…19514)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202305: #19547

yxieca pushed a commit that referenced this pull request Jul 18, 2024
…19546)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```

Co-authored-by: jingwenxie <jingwenxie@microsoft.com>
arun1355492 pushed a commit to arun1355492/sonic-buildimage that referenced this pull request Jul 26, 2024
…19514)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
liushilongbuaa pushed a commit to liushilongbuaa/sonic-buildimage that referenced this pull request Aug 1, 2024
…19514)

### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
mssonicbld pushed a commit that referenced this pull request Aug 3, 2024
### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
mssonicbld pushed a commit that referenced this pull request Oct 10, 2024
### Why I did it
The load_mgmt_config generated lo_v6 is missing standalone entry which fail YANG validation

##### Work item tracking
- Microsoft ADO **(number only)**:28665800

#### How I did it
Add the standalone entry
#### How to verify it
Manual test in DUT

Before change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6|2603:10d0:e:5eb::/128": {}         <==== missing standalone entry which fail YANG
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
After change:
```
admin@str-msn2700a1-03:~$ sonic-cfggen -M /etc/sonic/device_desc.xml --print-data 
{
    "DEVICE_METADATA": {
        "localhost": {
            "hostname": "CPQ21-0101-0509-04T0",
            "hwsku": "Arista-7260CX3-D108C8"
        }
    },
    "LOOPBACK_INTERFACE": {
        "lo_v6": {},                                          <=== added standalone entry
        "lo_v6|2603:10d0:e:5eb::/128": {}
    },
    "MGMT_INTERFACE": {
        "eth0|100.84.101.139/26": {
            "gwaddr": "100.84.101.129"
        },
        "eth0|2603:10e2:f0:7478::b/64": {
            "gwaddr": "2603:10e2:f0:7478::1"
        }
    }
}
```
@wen587 wen587 added the Chassis for 202205 branch PRs needed for 202205 branch in msft repo label Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants