さんをつけろよデコ助野郎 from yoku0825
やってることはシンプルに単なるネタ。
書き上げたパッチをMySQL 5.6.12に適用してやると、mysqlコマンドラインクライアントに"さん"をつけないと怒る様にできます。
ここから
$ cd mysql-5.6.12 $ wget https://gist.github.com/yoku0825/5932320/raw/d715a496707357a220e5ebde34866cc2af656686/decosuke.patch $ patch -p0 < decosuke.patch patching file client/mysql.cc $ cmake . .. $ make mysql .. Scanning dependencies of target mysql [100%] Building CXX object client/CMakeFiles/mysql.dir/mysql.cc.o Linking CXX executable mysql [100%] Built target mysql
使い方。
"さん"をつけずにログインすると(mysqldは何でも良い)「さんをつけろよデコ助野郎!」と言われます。
exitくらいは通すようにしとくべきでしたが、exitですら言われます。
mv, cp, ln(ハードリンクでもシンボリックリンクでも)で"さん"をつけて、実行ファイル名を"mysql-san"にするとまともに動きます。
ただし、"さん"を間違って"mysql-sun"にするとやっぱり怒られます。
$ client/mysql -uroot -p -S /usr/mysql/5.6.12/data/mysql.sock Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 46 Server version: 5.6.12-log Source distribution Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> status _人人人人人人人人人人人人人人人_ > さんをつけろよデコ助野郎! <  ̄Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y ̄ mysql> mysql> ^DBye $ cp -ip client/mysql client/mysql-sun $ client/mysql-sun -uroot -p -S /usr/mysql/5.6.12/data/mysql.sock Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 47 Server version: 5.6.12-log Source distribution Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> status _人人人人人人人人人人人人人人人人人人_ > 黙れ小僧! お前にSunを救えるか! <  ̄Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y ̄ mysql> ^DBye $ cp -ip client/mysql client/mysql-san $ client/mysql-san -uroot -p -S /usr/mysql/5.6.12/data/mysql.sock Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 48 Server version: 5.6.12-log Source distribution Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> status -------------- client/mysql-san Ver 14.14 Distrib 5.6.12, for Linux (x86_64) using EditLine wrapper Connection id: 48 Current database: Current user: root@localhost SSL: Not in use Current pager: stdout Using outfile: '' Using delimiter: ; Server version: 5.6.12-log Source distribution Protocol version: 10 Connection: Localhost via UNIX socket Server characterset: utf8 Db characterset: utf8 Client characterset: utf8 Conn. characterset: utf8 UNIX socket: /usr/mysql/5.6.12/data/mysql.sock Uptime: 3 days 5 hours 27 min 13 sec Threads: 1 Questions: 599170 Slow queries: 0 Opens: 121 Flush tables: 1 Open tables: 72 Queries per second avg: 2.148 --------------
楽しんでください。
0 件のコメント :
コメントを投稿