cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1298
Views
5
Helpful
2
Replies

How to relaod or update ncs.conf configuration

viwagh
Cisco Employee
Cisco Employee

Hi All,

I'm trying NSO high availability POC for which I'm referring the below link https://developer.cisco.com/docs/nso/guides/#!nso-5-6-administration-guide-high-availability

Then as per the documentation I've done the changes in ncs.conf file. But I'm not sure how to restart NSO with updated configuration or reload it.

Also how can we check the high-availability status in NSO? Currently I'm using below commands

$ncs_cli -C -u admin  // Loging to ncs_cli

$show high-availability // Checking for HA state. Here I may be wrong

Whereas in ncs.conf I've added below configuration.

<ha>
<enabled>true</enabled>
<ip>0.0.0.0</ip>
<port>4570</port>
<tick-timeout>PT20S</tick-timeout>
</ha>

Note: I've not added the IP of slave node i.e. NSO. I'm just expecting that with above configuration atleast HA should be enabled.

Thanks in advance.

Regards,

Vishal

1 Accepted Solution

Accepted Solutions

Nabsch
Spotlight
Spotlight

Hello,

First you need to enable HA it's what you did in your ncs.conf then you need to restart your NSO instance. If you  are using system setup  you can use 

 

 sudo systemctl restart ncs  

if you are using local install you have to move to the NSO runtime  directory where you have your ncs.conf then do 

 

ncs --stop
ncs 

Then you need to add some configuration in cdb in order to specify  the slave and master. 

Th

Here an example from based on examples.ncs/development-guide/high-availability/basic

 

high-availability tokensuper-secret
high-availability ha-node n1
 address      127.0.0.1
 nominal-role master
!
high-availability ha-node n2
 address         127.0.0.2
 nominal-role    slave
 failover-master true
!
high-availability settings enable-failover true
high-availability settings start-up assume-nominal-role true
high-availability settings start-up join-ha true
high-availability settings reconnect-interval 10
high-availability settings reconnect-attempts 6

 then you have to enable ha 

high-availability enable 

 

then you can check using 

 

 show high-availability  

View solution in original post

2 Replies 2

Nabsch
Spotlight
Spotlight

Hello,

First you need to enable HA it's what you did in your ncs.conf then you need to restart your NSO instance. If you  are using system setup  you can use 

 

 sudo systemctl restart ncs  

if you are using local install you have to move to the NSO runtime  directory where you have your ncs.conf then do 

 

ncs --stop
ncs 

Then you need to add some configuration in cdb in order to specify  the slave and master. 

Th

Here an example from based on examples.ncs/development-guide/high-availability/basic

 

high-availability tokensuper-secret
high-availability ha-node n1
 address      127.0.0.1
 nominal-role master
!
high-availability ha-node n2
 address         127.0.0.2
 nominal-role    slave
 failover-master true
!
high-availability settings enable-failover true
high-availability settings start-up assume-nominal-role true
high-availability settings start-up join-ha true
high-availability settings reconnect-interval 10
high-availability settings reconnect-attempts 6

 then you have to enable ha 

high-availability enable 

 

then you can check using 

 

 show high-availability  

viwagh
Cisco Employee
Cisco Employee

How can implement the same in the kubernetes cluster?

Because in one of the docker image I've NSO configured. For which I create the 2 replica's & one will be primary & other one will be secondary.

Also, I tried something like when pod is up on which nso is running. So I'm trying to configure the HA in the running pod & trying to restart the same using 'ncs -- reload -c <ncs.conf> but in logs, I can see that configuration is loaded but not applied.

Do you have any idea about it?