Cb Response: The source cluster was not shut down cleanly during cbupgrade
search cancel

Cb Response: The source cluster was not shut down cleanly during cbupgrade

book

Article ID: 287935

calendar_today

Updated On:

Products

Carbon Black EDR (formerly Cb Response)

Issue/Introduction

Error message when running /usr/share/cb/cbupgrade
Success. You can now start the database server using: 

/usr/pgsql-10/bin/pg_ctl -D /var/cb/data/pgsql.10 -l logfile start 

Migrate configuration... 
Old postgresql.conf saved to /var/cb/data/pgsql/postgresql.conf.old 
Upgrade db to pgsql 10... 
Performing Consistency Checks 
----------------------------- 
Checking cluster versions ok 

The source cluster was not shut down cleanly. 
Failure, exiting 

-------------------------------------------------------------------------------- 
UPGRADE ABORTED 
-------------------------------------------------------------------------------- 
'sudo PGPASSFILE=/tmp/tmpkHrZLs -u cb /usr/pgsql-10/bin/pg_upgrade --old-datadir=/var/cb/data/pgsql --new-datadir=/var/cb/data/pgsql.10 --old-bindir=/usr/pgsql-9.3/bin/ --new-bindir=/usr/pgsql-10/bin/ --retain' failed(1)

 

Environment

  • Carbon Black Response Server: 6.2.4 and above
  • Postgres9.3
  • Postgres10

Cause

Postgres 9.3 did not shut down cleanly

Resolution

  1. Open an SSH/Terminal session
  2. Run the following commands
    • killall -KILL -u cb
    • sudo -u cb /usr/pgsql-9.3/bin/pg_ctl start -D /var/cb/data/pgsql
    • sudo -u cb /usr/pgsql-9.3/bin/pg_ctl stop -D /var/cb/data/pgsql
  3. Complete the upgrade
    • /usr/share/cb/cbupgrade

Additional Information

  • Postgres was upgraded from version 9.3 to version 10.
  • The services may not start due to RabbitMQ being out of sync. Run the following article to correct this.