From MySQL Shell 8.0.24, it’s possible to log all the SQL statements issued in MySQL Shell.
Everything is well documented in the dedicated manual section: System Logging for SQL Statements.
  Let’s see it in action. We will first start MySQL Shell with
  --syslog option:
$ mysqlsh --syslog --sql root@localhost
We enter a statement:
MySQL  localhost:33060+   2021-04-30 09:18:39  SQL  show databases; +-------------------------------+ | Database | +-------------------------------+ | bookstore | | clusterdemo | ...
And we can verify in syslog if something has been logged. I use Systemd and Journald therefor I will …
[Read more]