Articles in this section

How to stop/cancel VPS migration in SolusVM 2?

Applicable to:

  • SolusVM 2

Question

How to stop/cancel VPS migration in SolusVM 2?

Answer

It is not possible to stop migrations in SolusVM 2 UI/admin panel. 
However, it is possible to stop a migration manually via command line. 

Note: The best practice is to wait until the migration task is finished automatically.

  1. Connect to CR via SSH
  2. Find the VPS image path:

    # virsh domblklist UUID | grep sda | awk {'print $2'}

  3. Restart solus-agent:

    # systemctl restart solus-agent

  4. Find the other processes holding the VPS image using the image path from step 2:

    # lsof path-to-VPS-image

  5. Kill all the processes(if any) holding the VPS image:

    # kill PID


    Where PID is the PID of the corresponding process

  6. Connect to Management node via SSH
  7. Create database backup:
    How-to-create-SolusVM-2-database-backup 
  8. Access database with the command:

    # docker exec -it $(docker ps -q -f name=solus_postgres | head -n1) psql -U$(docker exec $(docker ps -q -f name=solus_postgres | head -n1) env | grep POSTGRES_USER | awk -F "=" {'print $2'}) $(docker exec $(docker ps -q -f name=solus_postgres | head -n1) env | grep POSTGRES_DB | awk -F "=" {'print $2'})

  9. Change the migration task status to 'failed':

# update tasks set status='failed' where id=MIGRATION_TASK_ID;

Replace "MIGRATION_TASK_ID" with the migration task ID. 

It could be found at "SolusVM 2 admin page > Virtual Servers > Chose the VPS > Tasks tab"

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.