Wiki

Clone wiki

jummp / MySQL

Configuring MySQL

Open a terminal and run the commands below.

$>mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 17
Server version: 5.5.21-log Source distribution

Copyright (c) 2000, 2011, 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> show variables like '%ssl';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| have_openssl  | YES   |
| have_ssl      | YES   |
+---------------+-------+
2 rows in set (0.00 sec)
mysqlselect sha2('abc',256);
+------------------------------------------------------------------+
| sha2('abc',256)                                                  |
+------------------------------------------------------------------+
| ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad |
+------------------------------------------------------------------+
1 row in set (0.00 sec)
If you don't have SSL support, the variables have_ssl and have_openssl will be set to NO and the function sha2() will return null. To fix this, you will need to recompile mysql using

$>cmake . -DWITH_SSL=bundled

or

$>cmake . -DWITH_SSL=system

See the friendly manual for details. If you're not running MySQL version 5.5.5 or later, please upgrade.

Updated