我使用netconf的时候,里面的huawei和huaweiyang的区别是什么?
device_params = {"name": "huawei"}
device_params = {"name": "huaweiyang"}
def netconfig_set_logserver(device_ip, username, password, log_name, log_server):
with manager.connect(
host = device_ip,
port=830,
username = username,
password = password,
hostkey_verify = False,
device_params = {"name": "huaweiyang"}
) as m:
config = '''
<config>
<syslog:syslog xmlns:syslog="urn:ietf:params:xml:ns:yang:ietf-syslog">
<syslog:log-actions>
<syslog:remote>
<syslog:destination>
<syslog:name>{}</syslog:name>
<syslog:udp>
<syslog:address xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0" xc:operation="replace">{}</syslog:address>
</syslog:udp>
</syslog:destination>
</syslog:remote>
</syslog:log-actions>
</syslog:syslog>
</config>'''.format(log_name, log_server)