{"action":"created","issue":{"url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/1030","repository_url":"https://api.github.com/repos/Azure/sonic-mgmt","labels_url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/1030/labels{/name}","comments_url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/1030/comments","events_url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/1030/events","html_url":"https://github.com/Azure/sonic-mgmt/pull/1030","id":472184713,"node_id":"MDExOlB1bGxSZXF1ZXN0MzAwNjQzNjk4","number":1030,"title":"Set Broadcast flag for dhcp offer&ack in dhcp_relay_test.py","user":{"login":"bbinxie","id":27556406,"node_id":"MDQ6VXNlcjI3NTU2NDA2","avatar_url":"https://avatars3.githubusercontent.com/u/27556406?v=4","gravatar_id":"","url":"https://api.github.com/users/bbinxie","html_url":"https://github.com/bbinxie","followers_url":"https://api.github.com/users/bbinxie/followers","following_url":"https://api.github.com/users/bbinxie/following{/other_user}","gists_url":"https://api.github.com/users/bbinxie/gists{/gist_id}","starred_url":"https://api.github.com/users/bbinxie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbinxie/subscriptions","organizations_url":"https://api.github.com/users/bbinxie/orgs","repos_url":"https://api.github.com/users/bbinxie/repos","events_url":"https://api.github.com/users/bbinxie/events{/privacy}","received_events_url":"https://api.github.com/users/bbinxie/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2019-07-24T09:46:10Z","updated_at":"2019-07-30T22:53:05Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/Azure/sonic-mgmt/pulls/1030","html_url":"https://github.com/Azure/sonic-mgmt/pull/1030","diff_url":"https://github.com/Azure/sonic-mgmt/pull/1030.diff","patch_url":"https://github.com/Azure/sonic-mgmt/pull/1030.patch"},"body":"<!--\r\nPlease make sure you've read and understood our contributing guidelines;\r\nhttps://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md\r\n\r\nPlease provide following information to help code review process a bit easier:\r\n-->\r\n### Description of PR\r\nThe expected offer& ack package is broadcast\r\nBut get the package is Unicast.\r\nSo，we  need to set Broadcast flag  for dhcp offer&ack, \r\n\r\n<!--\r\n- Please include a summary of the change and which issue is fixed.\r\n- Please also include relevant motivation and context. Where should reviewer start? background contaxt?\r\n- List any dependencies that are required for this change.\r\n-->\r\n\r\nSummary:\r\nFixes # (issue)\r\ndhcp relay test failed because   verified packet not correct.\r\n### Type of change\r\n\r\n- [√] Bug fix\r\n- [] Testbed and Framework(new/improvement)\r\n- [] Test case(new/improvement)\r\n\r\n### Approach\r\n#### How did you do it?\r\nModify file dhcp_relay_test.py\r\nAdd “set_broadcast_bit=True” in create_dhcp_offer_packet and  create_dhcp_ack_packet\r\n Set “flags=0x8000” in create_dhcp_offer_relayed_packet and  create_dhcp_ack_relayed_packet\r\n#### How did you verify/test it?\r\ntestbed  dhcp_relay test\r\n\r\nPLAY RECAP *********************************************************************\r\ncel-e1031-01               : ok=58   changed=10   unreachable=0    failed=0\r\n\r\nWednesday 24 July 2019  09:41:45 +0000 (0:00:00.033)       0:00:30.786 ********\r\n===============================================================================\r\nTASK: test : command ---------------------------------------------------- 4.53s\r\nTASK: test : gather system version information -------------------------- 2.49s\r\nTASK: setup ------------------------------------------------------------- 1.72s\r\nTASK: test : Copy tests to the PTF container ---------------------------- 1.67s\r\nTASK: test : Get interface facts ---------------------------------------- 1.47s\r\nTASK: test : Get interface facts ---------------------------------------- 1.43s\r\nTASK: test : set_fact --------------------------------------------------- 1.28s\r\nTASK: test : Get process information in syncd docker -------------------- 1.24s\r\nTASK: test : Get process information in syncd docker -------------------- 1.11s\r\nTASK: test : Verify port channel interfaces are up correctly ------------ 0.98s\r\nTASK: test : validate all interfaces are up after test ------------------ 0.82s\r\nTASK: test : Fetch result files from switch to ansible machine ---------- 0.65s\r\nTASK: test : Verify port channel interfaces are up correctly ------------ 0.64s\r\nTASK: test : Gather minigraph facts about the device -------------------- 0.64s\r\nTASK: test : debug ------------------------------------------------------ 0.60s\r\nTASK: test : Gather minigraph facts about the device -------------------- 0.58s\r\nTASK: test : Gathering minigraph facts about the device ----------------- 0.57s\r\nTASK: test : Get orchagent process information -------------------------- 0.52s\r\nTASK: test : validate all interfaces are up ----------------------------- 0.49s\r\nTASK: test : Get orchagent process information -------------------------- 0.49s\r\n\r\n#### Any platform specific information?\r\ncel_e1031&cel_seastone devices\r\n#### Supported testbed topology if it's a new test case?\r\n\r\n### Documentation \r\n<!--\r\n(If it's a new feature, new test case)\r\nDid you update documentation/Wiki relevant to your implementation?\r\nLink to the wiki page?\r\n-->\r\n"},"comment":{"url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/comments/516625825","html_url":"https://github.com/Azure/sonic-mgmt/pull/1030#issuecomment-516625825","issue_url":"https://api.github.com/repos/Azure/sonic-mgmt/issues/1030","id":516625825,"node_id":"MDEyOklzc3VlQ29tbWVudDUxNjYyNTgyNQ==","user":{"login":"jleveque","id":3300381,"node_id":"MDQ6VXNlcjMzMDAzODE=","avatar_url":"https://avatars1.githubusercontent.com/u/3300381?v=4","gravatar_id":"","url":"https://api.github.com/users/jleveque","html_url":"https://github.com/jleveque","followers_url":"https://api.github.com/users/jleveque/followers","following_url":"https://api.github.com/users/jleveque/following{/other_user}","gists_url":"https://api.github.com/users/jleveque/gists{/gist_id}","starred_url":"https://api.github.com/users/jleveque/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jleveque/subscriptions","organizations_url":"https://api.github.com/users/jleveque/orgs","repos_url":"https://api.github.com/users/jleveque/repos","events_url":"https://api.github.com/users/jleveque/events{/privacy}","received_events_url":"https://api.github.com/users/jleveque/received_events","type":"User","site_admin":false},"created_at":"2019-07-30T22:53:05Z","updated_at":"2019-07-30T22:53:05Z","author_association":"CONTRIBUTOR","body":"Your understanding appears correct. If the client sets the \"broadcast flag\" to 1 in the DISCOVER packet, the relay agent should send the replies back as broadcasts, otherwise, the agent should send them back as unicast.\r\n\r\nIs your claim that the latest DHCP realay agent code is always sending broadcast, even if the broadcast flag isn't set? That's what it looks like to me, just wanted to confirm."}}
{"actor":{"display_login":"jleveque"}}