Skip to content
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
423177e
hostcfgd service enhancements: 1.Added support for Dynamic handling o…
Mar 9, 2020
eacfbf6
Fixed issue in adding and deleting ipv6 config.
Mar 30, 2020
f6fd9fb
Addressed review comments, Added support for handling forced_mgmt_rou…
Apr 21, 2020
02d9006
Merge branch 'master' into master
rvasanthm Apr 21, 2020
3a82ade
[docker]: Enabled ipv6 in dockers when using docker bridge network (#…
arlakshm Apr 22, 2020
4cd7540
Removed unused imports.
Apr 22, 2020
49fd662
Merge branch 'master' of https://github.com/rvasanthm/sonic-buildimage
Apr 22, 2020
43e80f7
[doc]: ask the motivation of the PR (#4462)
lguohan Apr 22, 2020
45c88d1
[kvm]: disable pmon daemons on kvm vs platform (#4461)
lguohan Apr 22, 2020
c5e9844
[device/acction] Support AS9716-32D(R0BA) (#4449)
chihhan123 Apr 22, 2020
c52b8c4
[platform-modules]: set debian control depends on unsigned kernel pac…
lguohan Apr 23, 2020
9129378
[accton/as9716-32d] add support get_transceiver_change_event (#4105)
jostar-yang Apr 23, 2020
057ced0
[bgpcfgd]: Split one bgp mega-template to chunks. (#4143)
pavel-shirshov Apr 23, 2020
4adf243
Fix docker restapi start issue, undefined error (#4475)
prsunny Apr 24, 2020
c56752a
[build]: add sonic-slave-run target to run any cmds inside sonic-slav…
lguohan Apr 25, 2020
e75da77
[device/celestica]: Fix sfp index on dx010 platform api (#4346)
Apr 25, 2020
ac6cfb1
[Mellanox] Add a new Mellanox platform x86_64-mlnx_msn3420 and new SK…
shlomibitton Apr 26, 2020
e363293
[Mellanox]Mellanox-SN3800-D112C8 support warm-reboot (#4482)
stephenxs Apr 27, 2020
b26814f
[Mellanox] Adjust dynamic minimum fan speed algorithm (#4476)
Junchao-Mellanox Apr 28, 2020
72af555
Parse Device region field in Minigraph (#4486)
sumukhatv Apr 28, 2020
a60a203
[dhcpmon] Filter DHCP O/A Messages of Neighboring Vlans (#4469)
tahmed-dev Apr 28, 2020
0409a32
[mellanox]: Align CPLD component with latest hw-mgmt. (#4485)
nazariig Apr 28, 2020
a40fe3b
[DellEMC] S6100-Fix i2C ISMT issue (#4330)
aravindmani-1 Apr 28, 2020
fc55329
[mgmt-framework]: convert mgmt-framework to use buster docker (#4480)
joyas-joseph Apr 28, 2020
93ade1d
[Multi-ASIC] To pass the asic instance ID to orchagent, Advance the s…
judyjoseph Apr 29, 2020
0895033
[sonic-utilities] Update submodule (#4492)
jleveque Apr 29, 2020
087e5fb
[build]: build missing stretch dockers when debug build is enabled (#…
lguohan Apr 29, 2020
4c55adf
[iccpd]: ICCPD support IPv6 ND (#4422)
jianjundong Apr 29, 2020
0038305
[docker-iccpd]: disable iccpd build by default (#4502)
lguohan Apr 30, 2020
a539cf2
[build]: remove -t for non-tty terminal
lguohan Apr 30, 2020
e1ba5b0
[docker-restapi]: add restapi config to config Db (#4495)
sumukhatv Apr 30, 2020
b629137
[Mellanox] Add a new Mellanox platform x86_64-mlnx_msn4600c and new S…
shlomibitton Apr 30, 2020
799f22d
[baseimage]: Run fsck filesystem check support prior mounting filesys…
olivier-singla Apr 30, 2020
6850644
[vs]: add missing dvslib link for the vs test
lguohan Apr 30, 2020
a87bf4d
[Mellanox] Fix error in sensors.conf for 3700/3700c/3800 (#4506)
stephenxs Apr 30, 2020
80a025a
[arista] update platform driver submodules (#4512)
Staphylo Apr 30, 2020
4c210f0
[Mellanox] Enhancement for support PSU LED management (#4467)
Junchao-Mellanox Apr 30, 2020
2153cae
[submodule]: Advance sonic-platform-common. (#4513)
nazariig Apr 30, 2020
86bc8ae
[vs]: dynamically create front panel ports in vs docker (#4499)
lguohan Apr 30, 2020
aca5bec
[sonic-py-swsssdk/snmpagent] update submodule for sonic-py-swsssdk / …
dzhangalibaba Apr 30, 2020
352a397
[mellanox]: MSN4700 support 8 lanes 400G with new SAI/SDK/FW (#4509)
keboliu Apr 30, 2020
81f4c81
[build]: changing debian names based on Architecture (#4508)
Sabareesh-Kumar-Anandan Apr 30, 2020
46161ca
[sonic-utilities][sonic-ztp] Update submodules (#4501)
jleveque Apr 30, 2020
cbc75fe
[pmon]: Fix the continous syseepromd autorestart issue on 201911 (#4478)
sujinmkang Apr 30, 2020
4511216
Ssd mitigation changes (#4214)
rkdevi27 May 1, 2020
506e954
[device] Upgrade as4630_54pe for new platform (#4268)
dereksun01 May 1, 2020
3f1c3dd
[device/accton] Modify as8000 configuration (#4446)
dereksun01 May 1, 2020
34cad97
[device] Modify configuration and add led_proc_init.soc (#4418)
dereksun01 May 1, 2020
aafe825
Addressed review comments.
May 1, 2020
c55603f
[build]: add docker-ptf-* as stretch docker targets (#4516)
lguohan May 1, 2020
30bbbbf
hw-mgmt_V.7.0000.3034 integration (#4519)
shlomibitton May 2, 2020
49df4b7
Addressed review comments and fixed build issue
May 2, 2020
e8748eb
[submodule]: advance sonic-utilities submodule (#4523)
judyjoseph May 4, 2020
86e1390
Update golang version for 1.11.5 to 1.14.2 (#4520)
pavel-shirshov May 4, 2020
8ac1c60
[config engine] Parser changes to support parsing of multi-asic devic…
SuvarnaMeenakshi May 4, 2020
35998ba
Added default mgmt routes and rules
May 5, 2020
d238662
Addressed issuses reported LGTM analysis
May 5, 2020
8671fd1
Addressed issuses reported LGTM analysis
May 5, 2020
6c9dd76
[device] DellEMC s5232f 50G hwsku support (#4525)
srideepDell May 5, 2020
5307f94
[devices] skip_fancontrol for wedge 100 barefoot platforms (#4528)
msosyak May 5, 2020
f0c13d3
Fixed issue in handling net.ipv6.conf.eth0.accept_ra sysctl
May 5, 2020
53c00ba
hostcfgd service enhancements: 1.Added support for Dynamic handling o…
Mar 9, 2020
a2d9722
Fixed issue in adding and deleting ipv6 config.
Mar 30, 2020
ffb660e
Addressed review comments, Added support for handling forced_mgmt_rou…
Apr 21, 2020
424ab53
Removed unused imports.
Apr 22, 2020
d3faf45
Addressed review comments.
May 1, 2020
55445c4
Addressed review comments and fixed build issue
May 2, 2020
7ca8e39
Added default mgmt routes and rules
May 5, 2020
903ad51
Addressed issuses reported LGTM analysis
May 5, 2020
07eb6ad
Addressed issuses reported LGTM analysis
May 5, 2020
6513b32
Fixed issue in handling net.ipv6.conf.eth0.accept_ra sysctl
May 5, 2020
50e5f0e
Merge branch 'master' of https://github.com/rvasanthm/sonic-buildimage
May 6, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions build_debian.sh
Original file line number Diff line number Diff line change
Expand Up @@ -442,6 +442,8 @@ sudo cp files/dhcp/sethostname6 $FILESYSTEM_ROOT/etc/dhcp/dhclient-exit-hooks.d/
sudo cp files/dhcp/graphserviceurl $FILESYSTEM_ROOT/etc/dhcp/dhclient-exit-hooks.d/
sudo cp files/dhcp/snmpcommunity $FILESYSTEM_ROOT/etc/dhcp/dhclient-exit-hooks.d/
sudo cp files/dhcp/vrf $FILESYSTEM_ROOT/etc/dhcp/dhclient-exit-hooks.d/
sudo cp files/dhcp/dhcp_mgmt_interface $FILESYSTEM_ROOT/etc/dhcp/dhclient-exit-hooks.d/
sudo cp files/dhcp/dhcp_mgmt_conf.py $FILESYSTEM_ROOT/usr/bin/
if [ -f files/image_config/ntp/ntp ]; then
sudo cp ./files/image_config/ntp/ntp $FILESYSTEM_ROOT/etc/init.d/
fi
Expand Down
42 changes: 42 additions & 0 deletions files/dhcp/dhcp_mgmt_conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/usr/bin/python -u
# -*- coding: utf-8 -*-

import os
import re
import sys
import subprocess
import syslog
import ipaddress
import netaddr
from swsssdk import ConfigDBConnector

APP_MGMT_INTF_TABLE = "MGMT_INTF_TABLE"

def update_dhcp_mgmt_ip_info():
app_db = ConfigDBConnector()
app_db.db_connect('APPL_DB', wait_for_init=False, retry_on=True)
appdb_entry = {}
appdb_entry["NULL"] = "NULL"

op = sys.argv[2]
plen = ipaddress.ip_network((0, sys.argv[4])).prefixlen
key = sys.argv[1] + ":" + sys.argv[3] + "/" + str(plen)
syslog.syslog(syslog.LOG_INFO, "update_dhcp_mgmt_ip_info : op - {}, key - {}".format(op, key))
if op == "add":
app_db.set_entry(APP_MGMT_INTF_TABLE, key, appdb_entry)
elif op == "del":
app_db.delete_entry(APP_MGMT_INTF_TABLE, key)
return

if __name__ == "__main__":
if len(sys.argv) < 5:
syslog.syslog(syslog.LOG_INFO, "number of arguments not correct")
syslog.syslog(syslog.LOG_INFO, "usage:")
syslog.syslog(syslog.LOG_INFO, "dhcp_mgmt_conf.py <add/del> <interface name> <ip address> <subnet mask>")
else:
syslog.syslog(syslog.LOG_INFO, "Args : {}".format(sys.argv))
update_dhcp_mgmt_ip_info()




Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete blank lines at EOF

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

53 changes: 53 additions & 0 deletions files/dhcp/dhcp_mgmt_interface
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#!/bin/sh
#
# DHCLIENT exit hook for ip address update in app db
#


set -x

PYTHON_PATH=/usr/bin/python
SCRIPT=/usr/bin/dhcp_mgmt_conf.py


dhcp_mgmt_conf_handle() {
IF_NAME=$interface
echo "dhcp_mgmt_conf_handle, interface : $IF_NAME"

if [ "$IF_NAME" = "eth0" ]; then
echo "DHCP exit hook is called for $IF_NAME, reason : $reason"

case $reason in
BOUND|REBOOT|BOUND6)
if [ -n "$new_ip_address" ] && [ -n "$new_subnet_mask" ]; then

$PYTHON_PATH $SCRIPT $IF_NAME add $new_ip_address $new_subnet_mask
fi
;;
RENEW|REBIND|RENEW6|REBIND6)
if [ -n "$old_ip_address" ] && [ -n "$old_subnet_mask" ]; then
$PYTHON_PATH $SCRIPT $IF_NAME del $old_ip_address $old_subnet_mask
fi

if [ -n "$new_ip_address" ] && [ -n "$new_subnet_mask" ]; then
$PYTHON_PATH $SCRIPT $IF_NAME add $new_ip_address $new_subnet_mask
fi

;;
EXPIRE|FAIL|RELEASE|STOP)
if [ -n "$new_ip_address" ] && [ -n "$new_subnet_mask" ]; then
$PYTHON_PATH $SCRIPT $IF_NAME del $new_ip_address $new_subnet_mask
fi

if [ -n "$old_ip_address" ] && [ -n "$old_subnet_mask" ]; then
$PYTHON_PATH $SCRIPT $IF_NAME del $old_ip_address $old_subnet_mask
fi
;;
TIMEOUT)
;;
esac
fi
}

echo "dhcp_mgmt_conf"
dhcp_mgmt_conf_handle
Loading