How do I terminate Sessions in a RDS for MySQL instance?

Introduction

This article describes how to terminate Sessions in an apsaradb RDS for MySQL instance.

Run the kill command to the terminate

  1. Connect to an RDS for MySQL instance by using a MySQL CLI tool.

  2. Run the following command to view the current session and record the Id of the session to be terminated.

    1. show processlist;

  3. Run the following command to terminate a session:

    1. kill [$ID];