cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2452
Views
25
Helpful
7
Replies
Highlighted

ANSWERED - How to change PI HA role from Primary to Secondary

I found this link describing a CLI script to allow you to change your PI role.

https://wirelessforccie.com/2015/04/04/how-to-convert-cisco-prime-infrastructure-primary-server-to-a-secoundary-server/

I have run this script and now my new HA Secondary server is syncronizing with the Primary.  I'm not sure why all the ps commands in the beginning but the script worked.

pi-hostname/admin# shell
Enter shell access password :
Starting bash shell ...
ade # sudo su
ade # cd /opt/CSCOlumos/bin
ade # ./hamode.sh secondary
HA mode is : primary
Setting HA mode to 'secondary'
Setting HA mode to 'secondary'
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

Changing HA mode will result in *LOSS* of any data currently on the system
Enter 'yes' to proceed ....

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
yes
Setting HA mode to 'secondary'
 
ade # exit
exit
ade # exit
exit

pi-hostname/admin# ncs stop
Stopping Prime Infrastructure...
...
Completed shutdown of all services

pi-hostname/admin# ncs start
Starting Prime Infrastructure...
...
Prime Infrastructure started successfully.

Completed in 1126 seconds

pi-hostname/admin# ncs ha authkey **************
Going to update Secondary authentication key
Successfully updated Secondary authentication key in standalone server

7 REPLIES 7
Highlighted
Beginner

It worked for me too! Thanks

It worked for me too! Thanks for posting!!

J.McKay

Highlighted

Thanks a lot for your help !!

Thanks a lot for your help !!

Beginner

I receive the error, "No

I receive the error, "No input arguments are allowed to this script." when attempting "./hamode.sh secondary"

Highlighted
Beginner

Re: I receive the error, "No

Getting the same thing here.  PI 3.3 after an upgrade, where the secondary decided it would become primary because it felt like it.  Maybe it was the beautiful weather outside.

Highlighted

Re: I receive the error, "No

Hello Team

 

I received the same error cannot change the role from in HA from Primary to secondary for appliance in 3.3 Version

Highlighted

Re: I receive the error, "No

Hello Team,

 

PRIME/admin# shell
Enter shell access password :
Starting bash shell ...
ade # sudo su
ade # cdp /opt/CSCOlumos/bin
bash: cdp: command not found
ade # cdp /opt/CSCOlumos/bin/
bash: cdp: command not found
ade # cdp /opt/CSCOlumos/bin
bash: cdp: command not found
ade # cdp /opt/CSCOlumos/
bash: cdp: command not found
ade # cd /opt/CSCOlumos/bin
ade # ./hamode.sh secondary
HA mode is : primary
No input arguments are allowed to this script.
ade #

 

below error while changing role in 3.3

 

please help, i don't want to re-install the server

Highlighted

Re: I receive the error, "No

For anyone still looking for answers to this for 3.3/3.4, here is the answer.

 

https://supportforums.cisco.com/t5/security-and-network-management/how-to-run-setup-script-again-on-prime-infrastructure-2-2/m-p/2637739/highlight/false#M45343

 

Towards the end, last reply by DanLeeRankin worked for me at 3.4, where I had both servers as Primary and I needed one to be converted as secondary to join the two in HA.

SSH to the node that you want to change
to secondary.
Type in following:
shell
(will prompt to create password if not already done for shell)
sudo /opt/CSCOlumos/bin/setup.sh

This will now restart the setup and potentially will only ask if this will
be used as secondary HA and then supply the HA Authen key.

CreatePlease to create content
Content for Community-Ad
July's Community Spotlight Awards