This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
master [localhost] {msandbox} ((none)) > ALTER TABLE d1.t1 ADD dummy_uuid VARCHAR(36) DEFAULT NULL UNIQUE; | |
Query OK, 0 rows affected (0.03 sec) | |
Records: 0 Duplicates: 0 Warnings: 0 | |
master [localhost] {msandbox} ((none)) > INSERT INTO d1.t1 VALUES (3, UUID()); | |
Query OK, 1 row affected (0.00 sec) | |
$ ./use_all -e "SELECT * FROM d1.t1" | |
# master | |
num dummy_uuid |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[mysqld] | |
binlog_row_image = MINIMAL ### バイナリログのエントリあたりの容量を削減 | |
default_authentication_plugin = mysql_native_password ### 5.7, MariaDBとかから載せ替えるなら | |
event_scheduler = OFF ### 使ってなければお好みで。メモリリークあり | |
information_schema_stats_expiry = 0 ### SHOW TABLE STATUSが更新されない件 | |
innodb_buffer_pool_size = ? | |
skip-innodb_doublewrite ### 永続性そっちのけならアリ | |
innodb_flush_log_at_trx_commit = 2 ### 実はこれより ALTER INSTANCE DISABLE INNODB REDO_LOGの方が効く。ALTER INSTANCE .. はib_logfileに書き込まれるので対応するオプションはない。あと、正常終了しなかったときに二度と起動しなくなる | |
innodb_flush_method = O_DIRECT_NO_FSYNC | |
innodb_log_writer_threads = OFF ### もしCPU性能が低いVMとかの場合、これをOFFにするとちょっと速くなることがある |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
----system---- ----total-cpu-usage---- -dsk/total- -net/total- ---paging-- ---system-- ------memory-usage----- --io/total- ---load-avg--- | |
time |usr sys idl wai hiq siq| read writ| recv send| in out | int csw | used buff cach free| read writ| 1m 5m 15m | |
21-02 10:01:24| 3 0 96 1 0 0| 0 5998k| 567k 1127k| 0 0 |3088 5277 |6573M 2392k 48.2G 8303M| 0 373 |0.19 0.16 0.19 | |
21-02 10:01:25| 2 0 96 1 0 0| 0 8285k| 425k 847k| 0 0 |2847 4928 |6573M 2392k 48.2G 8299M| 0 329 |0.19 0.16 0.19 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use utf8; | |
my $file= "./general_query.log"; | |
open(my $fh, "<", $file) or die; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql80 26> SELECT x'E8919BF3A08481', LENGTH(x'E8919BF3A08481'), CHARACTER_LENGTH(x'E8919BF3A08481'); | |
+-------------------+---------------------------+-------------------------------------+ | |
| x'E8919BF3A08481' | LENGTH(x'E8919BF3A08481') | CHARACTER_LENGTH(x'E8919BF3A08481') | | |
+-------------------+---------------------------+-------------------------------------+ | |
| 葛󠄁 | 7 | 7 | | |
+-------------------+---------------------------+-------------------------------------+ | |
1 row in set (0.00 sec) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ll /usr/mysql/5.7.36/data/d1/ | |
total 220 | |
-rw-r----- 1 yoku0825 yoku0825 67 Nov 15 17:50 db.opt | |
-rw-r----- 1 yoku0825 yoku0825 8586 Nov 15 17:57 t1.frm | |
-rw-r----- 1 yoku0825 yoku0825 98304 Nov 15 17:57 t1.ibd <--- innodb_file_per_table= ON | |
-rw-r----- 1 yoku0825 yoku0825 8586 Nov 15 17:56 t3.frm | |
-rw-r----- 1 yoku0825 yoku0825 98304 Nov 15 17:56 t3.ibd | |
mysql57 11> SET GLOBAL innodb_file_per_table= 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function t2_in_1_3($buff) | |
{ | |
if ($buff["t2"] == 1 || $buff["t2"] == 3) | |
return true; | |
return false; | |
} | |
$t1= array(1, 2, 3); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql> SELECT @@version; | |
+-----------+ | |
| @@version | | |
+-----------+ | |
| 8.0.25 | | |
+-----------+ | |
1 row in set (0.00 sec) | |
mysql> SHOW GRANTS; | |
+--------------------------------------+ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Breakpoint 1, Parallel_reader::parallel_read() () at /home/yoku0825/mysql-8.0.26/storage/innobase/row/row0pread.cc:1087 | |
1087 void Parallel_reader::parallel_read() { | |
(gdb) c | |
+c | |
Continuing. | |
[New Thread 0x7f2972ffd700 (LWP 1916)] | |
[New Thread 0x7f2971ffb700 (LWP 1917)] | |
[New Thread 0x7f2998ff9700 (LWP 1914)] | |
[New Thread 0x7f296b7fe700 (LWP 1920)] | |
[New Thread 0x7f2970ff9700 (LWP 1918)] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2038-01-19T03:14:16.025479Z 8 [Warning] [MY-010112] [Server] Current time has got past year 2038. Validating current time with 5 iterations before initiating the normal server shutdown process. | |
2038-01-19T03:14:16.025550Z 8 [Warning] [MY-010114] [Server] Iteration 1: Current time obtained from system is greater than 2038 | |
2038-01-19T03:14:16.025561Z 8 [Warning] [MY-010114] [Server] Iteration 2: Current time obtained from system is greater than 2038 | |
2038-01-19T03:14:16.025569Z 8 [Warning] [MY-010114] [Server] Iteration 3: Current time obtained from system is greater than 2038 | |
2038-01-19T03:14:16.025575Z 8 [Warning] [MY-010114] [Server] Iteration 4: Current time obtained from system is greater than 2038 | |
2038-01-19T03:14:16.025582Z 8 [Warning] [MY-010114] [Server] Iteration 5: Current time obtained from system is greater than 2038 | |
2038-01-19T03:14:16.025590Z 8 [ERROR] [MY-010115] [Server] This MySQL server doesn't support dates later then 2038 | |
2038-01-19T03:14:17.178509Z 0 [System] [MY-010910] [Server] /usr/sbin/ |