• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question MySQL - Active transactions and operations?

Servus

Basic Pleskian
Hi at all,
I want to optimize my MySQL database for example InnoDB Buffer Pool Size.
Therefor I performed this test:
Code:
mysql> SELECT CONCAT(ROUND(KBS/POWER(1024,
    -> IF(PowerOf1024<0,0,IF(PowerOf1024>3,0,PowerOf1024)))+0.49999),
FROM (SELECT SUM(data_length+index_length) KBS FROM information_schema.tables
    -> SUBSTR(' KMG',IF(PowerOf1024<0,0,
    -> IF(PowerOf1024>3,0,PowerOf1024))+1,1)) recommended_innodb_buffer_pool_size
    -> FROM (SELECT SUM(data_length+index_length) KBS FROM information_schema.tables
    -> WHERE engine='InnoDB') A,
    -> (SELECT 3 PowerOf1024) B;
+-------------------------------------+
| recommended_innodb_buffer_pool_size |
+-------------------------------------+
| 1G                                  |
+-------------------------------------+
1 row in set (0.20 sec)

mysql> \q
Bye

But it's strictly recommended to be sure that there are no active transactions and operations!

Could you please help me to find out if there are active transactions and operations?
I don't know how to find this out.
Greets
 
You can check TRANSACTIONS and ROW OPERATIONS in the output of command

mysql> SHOW ENGINE INNODB STATUS;
 
Thanks for help, @IgorG. The command prints tons of informations, also for section transactions.
Which value(s) give me the correct information if there pending transactions or not?
From my point of view there are no pending transactions, I'm not sure.

Code:
------------
TRANSACTIONS
------------
Trx id counter 347848
Purge done for trx's n:o < 0 undo n:o < 0 state: running but idle
History list length 0
LIST OF TRANSACTIONS FOR EACH SESSION:
---TRANSACTION 421698644977504, not started
0 lock struct(s), heap size 1136, 0 row lock(s)
--------
FILE I/O
--------
 
Back
Top