Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
netq config add agent gnmi-enable true
netq config add agent opta-enable false
netq config add agent gnmi-port 9339
netq config restart agent
netq config status agent
netq config add agent gnmi-port 50052
netq config restart agent
netq config status agent
cumulus@cumulus:mgmt:~$ cat /etc/netq/netq.yml
netq-agent:
is-gnmi-enabled: true
is-opta-enabled: false
netq-gnmi:
gnmi_port: 9339ip,user,passwd,layer,region,azid,brickid,rackid
10.4.4.61,admin,YourPaSsWoRd,Spine,SanJose,1,1,1
10.4.4.62,admin,YourPaSsWoRd,Leaf,SanJose,1,1,1
...
...
...Does the ONES-agent is integrated with SONiC NOS? (yes/no): noEnter the ip address of collectors to auto-discover. Do not enter more than 2. Eg - 10.1.1.10, 10.2.2.5 : 10.4.4.11Do you want to restrict access only to provided collector ip?
Note: Providing Yes will restrict access to agent only with the provided collector IP Address
Enter Yes/No : Yesroot@ones-application/ONES-2.0/ones_t_agent:~$./ones_agent_parallel_installer.sh
Does the ONES-agent is integrated with SONiC NOS? (yes/no): no
Enter the ip address of collectors to auto-discover. Do not enter more than 2. E.g. - 10.1.1.10, 10.2.2.5 : 10.4.4.11
Do you want to restrict access only to provided collector ip?
Note: Providing Yes will restrict access to agent only with the provided collector IP Address
Enter Yes/No : Yes
[{'ip': '10.4.4.61', 'user': 'admin', 'passwd': 'YourPaSsWoRd', 'layer': 'Spine', 'region': 'Sanjose', 'azid': '1', 'brickid': '1', 'rackid': '1', 'installation_instance': 1, 'agentip': '10.4.4.61', 'collectorip': '10.4.4.11', 'restrict_collector_ip': 'Yes'}, {'ip': '10.4.4.62', 'user': 'admin', 'passwd': 'YourPaSsWoRd', 'layer': 'Leaf', 'region': 'Sanjose', 'azid': '1', 'brickid': '1', 'rackid': '1', 'installation_instance': 1, 'agentip': '10.4.4.62', 'collectorip': '10.4.4.11', 'restrict_collector_ip': 'Yes'}]
###############Connecting to switch###############
###############Connecting to switch###############
Connection to switch 10.4.4.61 successful.....................
Looking for previous installation........................
avizdock/ones-agent:devu
Connection to switch 10.4.4.62 successful.....................
Looking for previous installation........................
avizdock/ones-agent:latest
...
...
...
...
ones-agent.service file copied successfully on the device 10.4.4.61........
##################################################################
ones-agent.service file copied successfully on the device 10.4.4.62........
##################################################################
Deployment of ones-agent to switch 10.4.4.61 is successful
Deployment of ones-agent to switch 10.4.4.62 is successful
sudo ln -s /etc/nginx/sites-{available,enabled}/nvue.conf
sudo sed -i 's/listen localhost:8765 ssl;/listen \[::\]:8765 ipv6only=off ssl;/g' /etc/nginx/sites-available/nvue.conf
sudo systemctl restart nginxip,user,passwd
10.4.4.61,admin,YourPaSsWoRd
10.4.4.62,admin,YourPaSsWoRd
...
...
...root@ones-application/ONES-2.0/ones_fm_agent:~$ ./deploy_fmcli.sh 'install'
Installer will proceed with FMCLI-install ...
2fa37f2ee66e: Loading layer [==================================================>] 121.3MB/121.3MB
5cc3a4df1251: Loading layer [==================================================>] 49.6MB/49.6MB
2ef3351afa6d: Loading layer [==================================================>] 181.5MB/181.5MB
0c2d6fc19d6a: Loading layer [==================================================>] 596.9MB/596.9MB
d3de4ba9f72c: Loading layer [==================================================>] 19.25MB/19.25MB
6546924ee8e7: Loading layer [==================================================>] 41.04MB/41.04MB
16227882e38c: Loading layer [==================================================>] 5.12kB/5.12kB
29d8b0c23f30: Loading layer [==================================================>] 10.5MB/10.5MB
0eb731fd9ff0: Loading layer [==================================================>] 69.94MB/69.94MB
015b774a058f: Loading layer [==================================================>] 2.56kB/2.56kB
35743f2c1258: Loading layer [==================================================>] 37.47MB/37.47MB
e02e88375b40: Loading layer [==================================================>] 4.428MB/4.428MB
Loaded image: avizdock/agent_installer:latest
Docker image 'avizdock/agent_installer:latest' is loaded.
4c7a6666fea40554651f85c6b6857a79a99433872ba168c8865fbcf3246f0adc
Docker container 'agent_installer' is running.
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
4c7a6666fea4 avizdock/agent_installer:latest "python3" 4 seconds ago Up Less than a second agent_installer
Server IP: 172.17.0.2
fm_port: None
[{'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None}]
Operation = install
##### params = {'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None} #####
###############Connecting to switch###############
...
#################### Installing FMCLI on the device 10.20.7.12 ######################
####### Debug LOGS on the device 10.20.7.12 #######
...
FM-Agent installed successfully on the device 10.20.7.12........root@ones-application/ONES2.0/ones_fm_agent# ./deploy_fmcli.sh 'installresetconfig'
Installer will proceed with FMCLI-installresetconfig ...
2fa37f2ee66e: Loading layer [==================================================>] 121.3MB/121.3MB
5cc3a4df1251: Loading layer [==================================================>] 49.6MB/49.6MB
2ef3351afa6d: Loading layer [==================================================>] 181.5MB/181.5MB
0c2d6fc19d6a: Loading layer [==================================================>] 596.9MB/596.9MB
d3de4ba9f72c: Loading layer [==================================================>] 19.25MB/19.25MB
6546924ee8e7: Loading layer [==================================================>] 41.04MB/41.04MB
16227882e38c: Loading layer [==================================================>] 5.12kB/5.12kB
29d8b0c23f30: Loading layer [==================================================>] 10.5MB/10.5MB
0eb731fd9ff0: Loading layer [==================================================>] 69.94MB/69.94MB
015b774a058f: Loading layer [==================================================>] 2.56kB/2.56kB
35743f2c1258: Loading layer [==================================================>] 37.47MB/37.47MB
e02e88375b40: Loading layer [==================================================>] 4.428MB/4.428MB
Loaded image: avizdock/agent_installer:latest
Docker image 'avizdock/agent_installer:latest' is loaded.
86086002858bad33fa21019f48eb58c7e37d9104d5b161ad7706d61c0bfa89f2
Docker container 'agent_installer' is running.
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
86086002858b avizdock/agent_installer:latest "python3" 3 seconds ago Up Less than a second agent_installer
ones-fm container is not running
Server IP: 172.17.0.2
fm_port: None
[{'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None}]
Operation = installresetconfig
##### params = {'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None} #####
###############Connecting to switch###############
<paramiko.client.SSHClient object at 0x7feb0b5b0310>
Connection to switch 10.20.7.12 successfull.....................
/home/ones_fm_agent
Creating work directory on the device 10.20.7.12........
Work Directory ones-fm_1702897991_0583997 created successfully on the device 10.20.7.12 .............
Copying FMCLI_Installer.py to directory ones-fm_1702897991_0583997 on the device 10.20.7.12 .............
Copying FMCLI_Installer.py to directory ones-fm_1702897991_0583997 successful on the device 10.20.7.12 .............
Copying fmcli-app.tgz to directory ones-fm_1702897991_0583997 on the device 10.20.7.12 .............
Copying fmcli-app.tgz to directory ones-fm_1702897991_0583997 successful on the device 10.20.7.12 .............
#################### Installing FMCLI on the device 10.20.7.12 ######################
####### Debug LOGS on the device 10.20.7.12 #######
...
...
...
FM-Agent installed successfully on the device 10.20.7.12........
####### Deleting ones-fm_1702897991_0583997 dir on the device 10.20.7.12 #######
##### params = {'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None} #####
###############Connecting to switch - 10.20.7.12 ###############
<paramiko.client.SSHClient object at 0x7feb0b5b0640>
Connection to switch 10.20.7.12 successfull.....................
/home/ones_fm_agent
Creating work directory on the device 10.20.7.12........
Work Directory ones-fm_1702898114_0637665 created successfully on the device 10.20.7.12 .............
Copying config-reset.py to directory ones-fm_1702898114_0637665 on the device 10.20.7.12 .............
Copying config-reset.py to directory ones-fm_1702898114_0637665 successful on the device 10.20.7.12 .............
#################### Cleaning config on the device 10.20.7.12 ######################
...
...
...
OCI runtime exec failed: exec failed: unable to start container process: exec: "/usr/lib/frr/frr-reload.py": stat /usr/lib/frr/frr-reload.py: no such file or directory: unknown
Running command: /usr/local/bin/sonic-cfggen -d --print-data > /etc/sonic/config_db.json
###################################
###################################
###### Config Reset Successful !!! #######
root@ones-application/ONES-2.0/ones_fm_agent:~$ ./deploy_fmcli.sh 'upgrade'
Installer will proceed with FMCLI-upgrade ...
2fa37f2ee66e: Loading layer [==================================================>] 121.3MB/121.3MB
5cc3a4df1251: Loading layer [==================================================>] 49.6MB/49.6MB
2ef3351afa6d: Loading layer [==================================================>] 181.5MB/181.5MB
0c2d6fc19d6a: Loading layer [==================================================>] 596.9MB/596.9MB
d3de4ba9f72c: Loading layer [==================================================>] 19.25MB/19.25MB
6546924ee8e7: Loading layer [==================================================>] 41.04MB/41.04MB
16227882e38c: Loading layer [==================================================>] 5.12kB/5.12kB
29d8b0c23f30: Loading layer [==================================================>] 10.5MB/10.5MB
0eb731fd9ff0: Loading layer [==================================================>] 69.94MB/69.94MB
015b774a058f: Loading layer [==================================================>] 2.56kB/2.56kB
35743f2c1258: Loading layer [==================================================>] 37.47MB/37.47MB
e02e88375b40: Loading layer [==================================================>] 4.428MB/4.428MB
Loaded image: avizdock/agent_installer:latest
Docker image 'avizdock/agent_installer:latest' is loaded.
73bf7f665d0df3633a83b58fae02e987cad8f1246ec6119aa58088e00c1e44a6
Docker container 'agent_installer' is running.
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
73bf7f665d0d avizdock/agent_installer:latest "python3" 3 seconds ago Up Less than a second agent_installer
ones-fm container is not running
Server IP: 172.17.0.2
fm_port: None
[{'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None}]
Operation = upgrade
##### params = {'ip': '10.20.7.12', 'passwd': 'YourPaSsWoRd', 'user': 'admin', 'server_ip': '172.17.0.2', 'fm_port': None} #####
###############Connecting to switch###############
...
...
...
#################### Upgrading FMCLI on the device 10.20.7.12 ######################
####### Debug LOGS on the device 10.20.7.12 #######
fmcli-app/
fmcli-app/fmcli
fmcli-app/fmclimain.service
fmcli-app/fmcli.cli
...
...
...
Created symlink /etc/systemd/system/multi-user.target.wants/fmclimain.service → /etc/systemd/system/fmclimain.service.
/tmp/fmcliStartup.init
FM-Agent Upgraded successfully on the device 10.20.7.12........root@Switch:~$ sudo fmcli
fmcli# Arista-DCS-7010T(config)#management api gnmi
Arista-DCS-7010T(config-mgmt-api-gnmi)#transport grpc default
Arista-DCS-7010T(config-gnmi-transport-default)#port 50052
Arista-DCS-7010T(config-gnmi-transport-default)#provider eos-native
Arista-DCS-7010T(config-mgmt-api-gnmi)#end
Arista-DCS-7010T#show management api gnmi
Octa: enabled
Transport: GRPC
Enabled: yes
Server: running on port 50052, in default VRF
SSL profile: SELFSIGNED
QoS DSCP: none
Authorization required: no
Accounting requests: no
Certificate username authentication: no
Notification timestamp: last change time
Listen addresses: ::
Transport: default
Enabled: yes
Server: running on port 6030, in default VRF
SSL profile: none
QoS DSCP: none
Authorization required: no
Accounting requests: no
Certificate username authentication: no
Notification timestamp: last change time
Listen addresses: ::
bash$ ssh username@myswitch
Password: <passw0rd>
myswitch> enable
myswitch# configure terminal
myswitch(config)# management api http-commands
myswitch(config-mgmt-api-http-cmds)# no shutdown
myswitch(config-mgmt-api-http-cmds)# show management api http-commands
Enabled: Yes
HTTPS server: running, set to use port 443
HTTP server: shutdown, set to use port 80
Local HTTP server: shutdown, no authentication, set to use port 8080
Unix Socket server: shutdown, no authentication
VRFs: defaultadmin@Spine-2:/etc/sonic$ docker restart ones-agentadmin@Spine-2:~$ cd /etc/sonic/
admin@Spine-2:/etc/sonic$admin@Spine-2:/etc/sonic$ sudo vi agent.conf
# Configuration file for agent gnmi
# Any edits require restart of the agent
# Mode - can be Tls/NoTls
mode = NoTls
#restrict_collector_ip = Yes/No
#Setting this to yes means that only the IP address mentioned under collectorip
#will be allowed to connect to the agent. No sets off this behavior
restrict_collector_ip = No
#layer of the switch Eg - Superspine/ Leaf/ Spine/ ToR
layer = Spine
#region of the switch Eg - Denver
region = Sj
#ip of the switch Eg - 10.4.4.33
agentip = 10.20.2.12
#ip of the collector Eg - 10.1.1.10
collectorip = 10.20.0.16,10.20.0.14
#azid of the switch Eg - 1
azid = 1
#brickid of the switch Eg - 1
brickid = 1
#rackid of the switch Eg - 1Installing Open Networking Enterprise Suite (ONES)
..................................................
ONES is getting installed for the first time, choose appropriate options when prompted...
....................
Installing prerequisites for ONES application
....................
....................
....................
....................
Installing ONES application...
Do you want to install domain SSL certificate(if not, installation will proceed with a self signed certificate)? [y/n]: n
Using self signed certificates...
Installing Open Networking Enterprise Suite (ONES)
..................................................
ONES is getting installed for the first time, choose appropriate options when prompted...
....................
Installing prerequisites for ONES application
....................
....................
....................
....................
Installing ONES application...
Do you want to install domain SSL certificate(if not, installation will proceed with a self signed certificate)? [y/n]: y
Enter the path to the private key file: ./certs/server.pem
Enter the path to the certificate file: ./certs/server.crt.pemLocal backup:
Do you want to enable DB backups? [y/n]y
Where do you want to store the backups? [local/remote]: local #local keyword trigger local database on server
Enter the backup directory: ./backups #Enter the server directory in which user wants to take backup
Enter the number of backups (between 1 and 3) to retain (Older backups will be deleted): 1 #Enter the number of backup user wants to create
Enter the backup interval in seconds (3600 seconds or higher): 86400 #Enter the value in seconds to take a backup Remote backup:
Do you want to enable DB backup feature? [y/n]: y
Where do you want to store the backups? [local/remote]: remote #remote keyword trigger remote database on server
Please make sure the remote server is reachable via SSH
Enter the remote machine IP: 10.0.0.1
Enter the remote machine username: admin
Enter the remote machine password:
Enter the backup directory: ~/backups #Enter the remote server directory in which user wants to take backup
Backup is being done in 10.0.0.1 at ~/backups
Enter the number of backups (between 1 and 100) to retain (Older backups will be deleted): 5 #Enter the number of backup user wants to create
Enter the backup interval in seconds (3600 seconds or higher): 86400 #Enter the value in seconds to take a backup No:
Do you want to enable certificate based authentication between ONES controller and devices? [y/n]: nYes:
Do you want to enable certificate based authentication between ONES controller and devices? [y/n]: y
Enter the path to the ca-cert.pem file: ca-cert.pem
Enter the path to the server-cert.pem file: server-cert.pem
Enter the path to the server-key.pem file: server-key.pem
Enter the path to the client-cert.pem file: client-cert.pem
Enter the path to the client-key.pem file: client-key.pem
Proceeding with certificates for Agent Auto Registration
Enter the path to the ca-cert-reg.pem file: ca-cert-reg.pem
Enter the path to the server-cert.pem file: server-cert.pem
Enter the path to the server-key.pem file: server-key.pem
Enter the path to the client-cert.pem file: client-cert.pem
Enter the path to the client-key.pem file: client-key.pem
Enter the ONES App URL: https://192.168.1.1Installing Open Networking Enterprise Suite (ONES)
..................................................
ONES is getting installed for the first time, choose appropriate options when prompted...
....................
Installing prerequisites for ONES application
....................
....................
....................
....................
Installing ONES application...
Do you want to install domain SSL certificate(if not, installation will proceed with a self signed certificate)? [y/n]: n
Using self signed certificates...
Do you want to enable DB backup feature? [y/n] : y
Where do you want to store the backups? [local/remote]: local
Enter the backup directory: ./backups
Enter the number of backups(between 1 and 3) to retain (Older backups will be deleted) : 1
Enter the backup interval in seconds(3600 seconds or higher) : 86400
Do you want to enable certificate based authentication between ONES controller and devices? [y/n]: n
Enter the ONES App URL: https://192.168.1.1
Setting up the environment and loading essential dockers...
d07119f7c800: Loading layer [==================================================>] 53.62MB/53.62MB
366319f9a81c: Loading layer [==================================================>] 2.56kB/2.56kB
0f6276391b12: Loading layer [==================================================>] 86.32MB/86.32MB
5f70bf18a086: Loading layer [==================================================>] 1.024kB/1.024kB..
...
...
...
Name Command State Ports
--------------------------------------------------------------------------------------------------------------------
api-server "java -jar /app/apis…" api-server running 0.0.0.0:8080->8080/tcp, :::8080->8080/tcp
broker "/etc/confluent/dock…" broker running 0.0.0.0:9092->9092/tcp, :::9092->9092/tcp, 0.0.0.0:9101->9101/tcp, :::9101->9101/tcp, 0.0.0.0:29092->29092/tcp, :::29092->29092/tcp
docker "python3 app.py" docker running
kafka-connect "/etc/confluent/dock…" kafka-connect running (healthy) 0.0.0.0:8083->8083/tcp, :::8083->8083/tcp, 9092/tcp
ksqldb-server "/usr/bin/docker/run" ksqldb-server running 0.0.0.0:8088->8088/tcp, :::8088->8088/tcp
ones-collector "java -jar /app/coll…" collector running 8093/tcp, 0.0.0.0:50053->50053/tcp, :::50053->50053/tcp
ones-collector-db "/docker-entrypoint.…" collector-db running 8008/tcp, 0.0.0.0:5432->5432/tcp, :::5432->5432/tcp, 8081/tcp
ones-fm "/bin/sh -c '{ gunic…" fm running 0.0.0.0:8787->8080/tcp, :::8787->8080/tcp
ones-fm-db "docker-entrypoint.s…" fm-db running 0.0.0.0:2345->5432/tcp, :::2345->5432/tcp
ones-gateway "./gnmi-gateway -Tar…" gateway running 0.0.0.0:9339->9339/tcp, :::9339->9339/tcp
ones-pty-server "docker-entrypoint.s…" pty-server running 0.0.0.0:8885->8885/tcp, :::8885->8885/tcp
ones-rule-service "java -jar /app/rule…" rule-service running 8080/tcp
ones-rule-service-db "docker-entrypoint.s…" rule-service-db running 5432/tcp
ones-ui "docker-entrypoint.s…" ui running 0.0.0.0:443->443/tcp, :::443->443/tcp, 3002/tcp
schema-registry "/etc/confluent/dock…" schema-registry running 0.0.0.0:8081->8081/tcp, :::8081->8081/tcp
stream-processor "java -jar /app/stre…" stream-processor running 8080/tcp
zookeeper "/etc/confluent/dock…" zookeeper running 2888/tcp, 0.0.0.0:2181->2181/tcp, :::2181->2181/tcp, 3888/tcp
Finishing up ONES Installation...
...................................................................................
Installed ONES application successfully
Open the ONES application at https://<host-ip>Enter the ONES App URL: https://ones.aviznetworks.com





