Reputation: 10914
I am not using my Cloud SQL since last 7 days and there is no query I am firing. Then why this graph shows I am making 10 queries per second. What does this graph signify ?
Upvotes: 2
Views: 252
Reputation: 1068
That graph signifies the number of statements executed by the server. This variable includes statements executed within stored programs.
To have a wider vision of what queries you Cloud SQL server is executing you can: 1. Enable Cloud SQL flag general_log=ON and log_output=FILE[1] 2. Go to [2], select your Cloud SQL instance and All logs=cloudsql.googleapis.com/mysql-general.log
You will see in the stackdriver logs the queries your server is executing behind. You can further look up these queries in the mysql reference manual.
If you have Cloud Audit logs enabled then the latter could be the reason why you are seeing these results in the graph. To disable Audits logs, you need to go to[3] and uncheck the Cloud SQL row.
Important: 1. When you set, remove, or modify a flag for a database instance, the database might be restarted. The flag value is then persisted for the instance until you remove it. If the instance is the source of a replica, the replica will also restart to align with the current configuration of the instance[1].
[1] https://cloud.google.com/sql/docs/mysql/flags#config
[2] https://console.cloud.google.com/logs/viewer
[3] https://console.cloud.google.com/iam-admin/audit
[4] https://cloud.google.com/sql/docs/mysql/flags#tips
Upvotes: 2