MariaDBã®ãã®å¾ã®åããã¾ã¨ãã¦ã¿ã - 2024å¹´4æç
æ¥æ¬ã§ãæ°å°ãªãMariaDB社ã®æ ªä¾¡ã¦ã©ããã£ã¼ã¨ãã¦ä»¥åã®è¨äºã®ç¶ããæ¸ãã¦ããã
2023å¹´5æã«ã¯æ¬å½ã®Penny Stockã«ãªã£ãMariaDB社ãã¡ãªã¿ã«Penny Stocksã¨ã¯SEC(ç±³å½è¨¼å¸åå¼å§å¡ä¼)ã®å®ç¾©ã§ã¯1æ ªããã$5æªæºã§åå¼ããããã®ãæããããããMariaDB社ãã¨MariaDB PLCã®æ ªä¾¡ã¯é·ãã$1æªæºã®ã¾ã¾ã¨ãªã£ã¦ãããNYSEã®ä¸å ´å»æ¢åºæºã«ãããããã ãã©ããã§ãä¸å ´ãç¶ãã¦ããããã®ã¯ä¸æè°ã ãã©ãããããã®ãªã®ã§ãããã
Penny stock - Wikipedia
Â
è¨äºå·çæç¹ã§ã®ææ°ã®åãã¯3æ26æ¥ã«ãæ§ã ãªè£½åãè²·åãã¦æ¡å¤§ãã¦ããããã°ã¬ã¹ã»ã½ããã¦ã§ã¢ç¤¾ãMariaDB社ã®è²·åã®è¨ç»ãçºè¡¨ã1æ ªããã$0.60ã§ç·é¡ç´$40.6Mã¨ã®ãã¨ãç¾æç¹ã§ã¯è²·åã¯å®äºãã¦ããªãã
Â
æç³»åãå°ãé¡ãã¨âãã£ãããããªæãã
- 2023å¹´10æ è³é調é(ãã¼ã³)ã®çºè¡¨ã¨åæã«ç¤¾å¡84åãç´28%ã®åæ¸ã¨SkySQLãXpandã¨ãã£ã製åã®åãé¢ããçºè¡¨
MariaDB plc Enters Into $26.5 Million Financing Agreement - 2023å¹´12æ SkySQLãã¹ãã³ã¢ã¦ãããµã¼ãã¹åã¨åãååã®ä¼ç¤¾ã¸ç§»ç®¡
MariaDB Finalizes Spinoff of SkySQL
Â
ãããªããã¿ãã¿ã®åãããã£ãã®ã2024å¹´2æã
2æ7æ¥ã1æã¯$0.20åå¾ã§åå¼ããã¦ãããã®ã2å以ä¸ã®$0.47ã«æ¥é¨°ãåå¼éãããã¾ã§10ä¸ã«ãæºããªãã£ã件æ°ããã®æ¥ã ã3,700ä¸ä»¶ãIRã®æ
å ±ãªã©ã¯ä¸åçºè¡¨ããªãã«ããããããæ ªä¾¡ã¨ãã¦ã¯ä¸èªç¶ãªåãã«è¦ãããåãªãããã¼ã²ã¼ã ãªã®ãããªã«ããã£ããã§ãããããã次ã«åããåºãã®ã¯ç´10æ¥å¾ã
Â
2æ16æ¥ããã©ã¤ãã¼ãã¨ã¯ã¤ãã£ã®K1 Investment Managementã$37.7Mã®ãªãã¡ã¼ãææ¡ãéä¸å ´åã®æ¹åã§ãããã¨ãçºè¡¨ã1æ ªãããã¯$0.55ã§2æ5æ¥ã®çµå¤ãã189%ã®ãã¬ãã¢ã ã3ææ«ã¾ã§ã®å®äºãç®æãã¨ããã¦ãããä¸ç¬$0.40è¶
ã®å¤ãä»ããã$0.30å°ã«è½ã¡çãã
2æ23æ¥ãããã¾ã§åºè³ãã¦ããå欧ã®æè³ä¼ç¤¾RP Ventures社ããã®K1社ã®çºè¡¨ã«æ¿ãããK1社ã®çºè¡¨ã«ãã$0.55ãã«ãå®è³ªçã«å¤©äºã¨ãªã£ã¦ãã¾ããã¨ãä¸æã ã£ã模æ§ãåµåä¸å±¥è¡éç¥ãéä»ãã¦MariaDB社ã®å£åº§ããç¾éãå¼ãä¸ãã¦è²¸ãæã¨ãã¦ã®RP社ã®è¿æ¸ã«å ã¦ãã¨ãã"Sweep"ã¨å¼ã°ããåããèµ·ããã¨è¦åãããäºæ ã«ã
ãã®ç¶æ³ãé観ãã¦ããããªãã£ãããã§ãå
MySQL社ã§ã³ãã¥ããã£ãã¼ã ãçããMariaDB社ã®ç«ã¡ä¸ãã«ãåç»ãã¦ããMariaDB Foundationã®CEOã®Kaj Arnöã声æãçºè¡¨ããã¡ã¼ã¸ã³ã³ããã¼ã«ãå³ã£ã¦ããã
3æ26æ¥ããã°ãããã¥ã¼ã¹ãé¢é£ããIRã®çºè¡¨ãé³æ²æ±°ãç¡ãã¾ã¾K1社ã®è²·åå¤æã®æéã¨ãªã3æ29æ¥ãè¿«ã£ã¦ããã¨ããã«ãããã°ã¬ã¹ã»ã½ããã¦ã§ã¢ç¤¾ã決ç®çºè¡¨ã®ã¿ã¤ãã³ã°ã§MariaDB社ã®è²·åã®æåãçºè¡¨ããã¤ã®éã«ã$0.20å°ã«æ»ã£ã¦ããMariaDB社ã®æ ªä¾¡ã¯ãã¥ã¼ã¹ãåãã¦åã³æ¥é¨°ãã¦$0.50å¼±ã«å°éãã¦ããã¨ããã
MariaDBã®é¡æ«ãæ¸ãçãã¦ãã
MariaDBã®éçºã³ãã¥ããã£MariaDB Foundationã§ã¯ãªãããµãã¼ããæåãã¼ã«ã販売ãã¦ããMariaDB Corporationã12ã¶æã®éã«ä¸æ°ã«ã°ãã°ãããããã¨ã«ãªã£ã¦ããã®ã§ã¾ã¨ãã¦ããã
MariaDB Foundationã¯è¤æ°ã®ä¼æ¥ãã¹ãã³ãµã¼ããã¦ãããã®ã®ããã¡ããMariaDB Corporationãçé ã®ã¹ãã³ãµã¼ã§ãããã³ã¢ã¡ã³ãã¼ã«MariaDB Corporationã®ç¤¾å¡ãããã
ä¸é£ã®äºæ¡ããã¥ã¼ã¹ã¨ãã¦ã®ããªã¥ã¼ããªãã®ãMariaDBèªä½ã追ã£ã¦ã人ãããªãã®ããä¸å ´ããã¨ã®çºè¡¨ä»¥å¤ã¯æ¥æ¬ã®ITç³»ã¡ãã£ã¢ã§ã¯ã»ã¨ãã©ã¹ã«ã¼ããã¦ããç¶æ ã§ããã
é¡æ«Â
- 2022å¹´2æ1æ¥ NYSEä¸å ´ã®SPAC(ç¹å¥è²·åç®çä¼ç¤¾)ã¨åä½µããå½¢ã§NYSEã«ä¸å ´ããã¨çºè¡¨
ãâ»SPAC: https://smbiz.asahi.com/article/14622436 - 2022å¹´5æ-6æ JPã¢ã«ã¬ã³ã¨ã´ã¼ã«ããã³ããã®æ¡ä»¶ã®äºåå¹¹äºä¼ç¤¾ãéãã (ãã®æç¹ã§ããããã¤ãã)
ãâ» https://www.thedeal.com/spacs/jpm-goldman-cut-ties-with-angel-pond-mariadb-deal/ - 2022å¹´12æ19æ¥ SPACã¨ã®çµ±åã§çæ¿ãæãæ¿ãMariaDBãä¸å ´ãã¦ãããã¨ã«
ãåå¤ã¯$11.55ã ãåæ¥çµå¤ã¯$6.75 ãã®å¾æ°æ¥ã§åå¤ã®1/3以ä¸ã«ä¸è½ - 2023å¹´1æ18æ¥ åºè³è
ã®99%ãè³éæ¤éã®æ¹åæ¸ã¿Â 6æã¾ã§ã«è³éã·ã§ã¼ãã®ãªã¹ã¯ãåºã
ãâ» https://twitter.com/ElinaLappalaine/status/1615655206460481537 - 2023å¹´2æ1æ¥ å¾æ¥å¡ã®8%ããªã¹ãã©ããã¨çºè¡¨
ãâ» https://www.marketscreener.com/quote/stock/MARIADB-PLC124600271/news/MARIADB-PLC-Regulation-FD-Disclosure-form-8-K-42872884/
ããã12ã¶æ足ããã®åºæ¥äºã§ããããã®å¾ã§å ã ã®æè³å®¶ã®ä¸è§ã ã£ãä¸å½ã®ã¢ãªããã7%å¼±ã®æ ªãåå¾ãã¦ãããå¥ã®æè³å®¶ã°ã«ã¼ãã«ããåããå¤å°ã¯ãããæ ªä¾¡ã¯$3å°ã®æå®å¤ãä»ãã¦ãããããã
Â
ãªãSPACã使ã£ãä¸å ´ã¯ããã³ãã£ã¼ä¼æ¥ã®è³é調éãæ¯æ´ãã¦æé·ãå éãããå¯è½æ§ãç§ãã¦ãããã®ã®ãæ¬æ¥ã®ä¸å ´ã®åºæºã«ã¯ããã«æºããªããããªä¼æ¥ã¾ã§ä¸å ´ããããã¨ã«ãªã£ã¦ãã¾ããã¨ãããããè£å£ä¸å ´ã¨å¼ã°ããããã¦ããã±ã¼ã¹ããä¸è¨ã¨åããããªäºæ¡ããã§ã«å¤çºãã¦ãã¦2022å¹´3ææ«ã«SPACæ¡ä»¶ãæ å½ãã証å¸ä¼ç¤¾ãæè³éè¡ã¸ã®è¦å¶ã®å¼·åãããã2社ã®ã¢ããã¤ã¶ã¼å¼ãåãããã®æ¤éã«ã¤ãªãã£ã¦ããã
2023å¹´2æ15æ¥è¿½è¨
2æ13æ¥ä»ã§12æ31æ¥ç· ãã®ç¬¬ä¸ååæ決ç®ãå ¬éãããã売ãä¸ãã®1.5åããã販管費ã«ãããç¶æ ã¯å¤ãããã決ç®æ¸ã®èªã¿æ¹ãééãã¦ãã¨æããããåµåè¶ éç¶æ ã«è¦ãããç¾é éã売æéããããªãã«ãããã®ã®ããã®ç¶æ ã®å¾ã§åºè³è ãæ¤éã¨ãªãã¨è³éã·ã§ã¼ãã®ãªã¹ã¯ãç¾å®å³ã帯ã³ã¦ããã
2023å¹´4æ9æ¥è¿½è¨
ä¸è¨ã®1æ18æ¥é¨åãä¿®æ£ãå è¨äºã翻訳ãã¤ã¤èªãã§ããã©èª¤ãããã£ã模æ§ãåºè³è ã®è³éå¼ãä¸ãã¯ã¾ããã®ä¸å ´çãªãã®ã®åæ¥ããã
2023å¹´5æ30æ¥è¿½è¨
4æä¸æ¬ã«ãã°ãã空å¸ã ã£ãCFOãæ¡ç¨ãããããã¤ããã¬ã¹ãªãªã¼ã¹ãæã£ã¦æ½åã試ã¿ããã®ã®ã5æã®ä¸æ¬ã«ã¯ã¤ãã«æ ªä¾¡ã1ãã«ãåã£ã¦ãã¾ã£ãã
2023å¹´5æ31æ¥è¿½è¨
ä»åº¦ã¯CEO, CRO, CTO交代ã®è¨äºãCRO (chief revenue officer)ããã¨ãã¨ãã¦äº¤ä»£ãªã®ãã¯ç¥ãããã©ã
finance.yahoo.com
ã¡ãªã¿ã«6æ5æ¥ä»ãã§å°±ä»»ããCTOã¯PostgreSQLã®ã³ã³ããªãã¥ã¼ã¿ã¼ã ã£ããOracle DBã®è¨äºæ¸ãã¦ãããã§MySQLãMariaDBè²ãè¦ãããªãã®ãèå³æ·±ãã¨ããã
Jupyter Notebookã¨MySQL X DevAPI
Pythonã®ã³ã¼ãã試ãã®ã«ä¾¿å©ãªJupyter Notebookã使ã£ã¦ãConnector/PythonããMySQL X DevAPIã試ãç°å¢ãä½ã£ã¦ã¿ã¾ãããJupyter Notebookã®å©ç¨ã«ã¯ Anaconda ã«å«ã¾ããPythonã¨Jupyter ã使ããã¨ãå¼·ãæ¨å¥¨(strongly recommend)ããã¦ãã¾ãã
https://jupyter.org/install.html
ã¡ãªã¿ã«Anacondaã¯ããã¼ã¿ãµã¤ã¨ã³ã¹åãã«ä½æããã Pythonããã±ã¼ã¸ã㨠Python.jp ã§ç´¹ä»ããã¦ãã¾ããWindowsã§ãmacOSã§ãGUIã®ã¤ã³ã¹ãã¼ã©ã§ããããã¤ã³ã¹ãã¼ã«ã§ãã¾ãã
Anacondaã¸ã®Connector/Pythonã®ã¤ã³ã¹ãã¼ã«
Anaconda.orgã«ããã±ã¼ã¸ãã¤ã³ã¹ãã¼ã«ããå ´å㯠conda install ã³ãã³ãã使ãã¨ããã¦ãã¾ãã
https://conda.io/docs/user-guide/tasks/manage-pkgs.html#installing-packages-from-anaconda-org
ã¨ãããAnaconda.orgã«ã¯ãæ¨æºã®anacondaãã£ã³ãã«ã§ã¯Connector/Python 2.0.4ãããã®ä»ã®ãã£ã³ãã«ã§ã8.0ç³»ã«ãã¼ã¸ã§ã³çªå·ããªã·ã¼ãå¤æ´ãããåã®2.2.3ãææ°ã¨ããç¶æ
ã§ãConnector/Python 8.0ãã¤ã³ã¹ãã¼ã«ãããã¨ãã§ãã¾ããã
https://anaconda.org/anaconda/mysql-connector-python
ããã§non-condaããã±ã¼ã¸ã®ã¤ã³ã¹ãã¼ã«ã¨ããæé ã使ãã¾ãã
https://conda.io/docs/user-guide/tasks/manage-pkgs.html#installing-non-conda-packages
pipããã±ã¼ã¸ç®¡çãã¼ã«ã§mysql-connector-pythonããã±ã¼ã¸ããã¼ã¸ã§ã³çªå·ãæå®ãã¦ãConnector/Python 8.0.6ãã¤ã³ã¹ãã¼ã«ãã¾ãã
https://pypi.python.org/pypi/mysql-connector-python
# Anacondaã®ä»®æ³ç°å¢ã®ç¢ºèª sakila:~ sakila$ conda info --envs # conda environments: # root * /Users/sakila/anaconda3 # ä»®æ³ç°å¢rootãã¢ã¯ãã£ãã¼ã # Windowsã§ã¯ãã®ã³ãã³ãã§ã¨ã©ã¼ãªãã¢ã¯ãã£ãã¼ãã§ãã # macOSã§ã¯ã¨ã©ã¼ã«ãªãã®ã§ã¨ã©ã¼ã¡ãã»ã¼ã¸ã®sourceä»ãã³ãã³ããå®è¡ sakila:~ sakila$ activate root Error: activate must be sourced. Run 'source activate envname' instead of 'activate envname'. sakila:~ sakila$ source activate envname CondaEnvironmentNotFoundError: Could not find environment: envname . You can list all discoverable environments with `conda info --envs`. sakila:~ sakila$ source activate root # pipã³ãã³ãã§Connector/Python 8.0.6ãã¤ã³ã¹ãã¼ã« (root) sakila:~ sakila$ pip install mysql-connector-python==8.0.6 Collecting mysql-connector-python==8.0.6 Downloading mysql_connector_python-8.0.6-cp36-cp36m-macosx_10_12_x86_64.whl (3.2MB) 100% |======================================| 3.2MB 413kB/s Installing collected packages: mysql-connector-python Successfully installed mysql-connector-python-8.0.6
ããã§Jupyter NotebookããConnector/Python 8.0.6ãå©ç¨ã§ããããã«ãªãã¾ããã
MySQL 8.0.4ã®ã¤ã³ã¹ãã¼ã«ã¨X Pluginã®ç»é²
MySQL 8.0.4ã«é¢ãã¦ã¯Windowsã¯ZIP, LinuxãmacOSã¯TARãå±éããã®ãæã£åãæ©ãã§ããã¡ãªã¿ã«Windowsç¨ã®MySQL Installerã¯8.0.4ãç¨æããã¦ãã¾ããã§ããã--initializeã¾ãã¯--initialize-insecureãªã©ã§åæåããèµ·åãã¦ããã¾ãã
X DevAPIããµãã¼ãããããã«X Pluginãç»é²ãã¾ãã
https://dev.mysql.com/doc/refman/8.0/en/document-store-setting-up.html
MySQL Shellãã¤ã³ã¹ãã¼ã«ãã¦ããã°ä¸è¨ã®ã³ãã³ãã§X Pluginãç»é²ã§ãã¾ãã
mysqlsh -u user -h localhost --classic --dba enableXProtocol
MySQL Shellããªããã°mysqlã¯ã©ã¤ã¢ã³ããããµã¼ãã¼ã«æ¥ç¶ããä¸è¨ã®ã³ãã³ããå®è¡ãã¾ãã
mysql> INSTALL PLUGIN mysqlx SONAME 'mysqlx.so';
ãªãWindowsä¸ã§ã¯mysqlx.soã ã¨ãã¡ã¤ã«ãè¦ã¤ãããªãããã¨ã©ã¼ã¨ãªãã®ã§ãmysqlx.dllã«å¤æ´ãã¾ãã
X DevAPIã®åä½ç¢ºèªã®ããJSONãã¼ã¿ãå«ãã ãµã³ãã«ãã¼ã¿ãã¼ã¹world_xãã¼ã¿ãã¼ã¹ãä¸è¨ãããã¦ã³ãã¼ãããå±éãã¦ãã¼ããã¦ããã¾ãã
https://dev.mysql.com/doc/index-other.html
mysql -uroot < /foo/bar/world_x-db/world_x.sql
Jupyter Notebookããã®åä½ç¢ºèª
Anaconda Navigatorãèµ·åãJupyter Notebookãé¸æãã¾ããèµ·åç´å¾ã®Jupyter Notebookã¯Webãã©ã¦ã¶ä¸ã«ãã©ã«ãã®ä¸è¦§ã表示ãããç¶æ
ã¨ãªã£ã¦ãã¾ããå¿
è¦ã«å¿ãã¦ãã¼ãä½æã®ãã©ã«ããä½æãããé¸æãããã®å¾ãç»é¢å³ä¸ã®Newã®ãã«ãã¦ã³ããPython 3ãé¸æããNotebookãæ°è¦ä½æãã¾ãã
Notebookã§ã¯In [1]:ã®æ¨ªã®ããã¹ãããã¯ã¹ã«Pythonã®ã³ã¼ããè¨è¼ããShift + Enterã§å®è¡ãããã¨ãã§ãã¾ãã
ã¾ãã¯åä½ç¢ºèªãå
¼ãã¦ãConnector/Pythonã®ãªãã¡ã¬ã³ã¹ããã¥ã¢ã«ã®ãµã³ãã«ã³ã¼ããçµã¿åããã¦ã稼åä¸ã®MySQLãµã¼ãã¼ã®ãã¼ã¸ã§ã³ãVERSION()é¢æ°ã§ç¢ºèªãã¦ã¿ã¾ãã
from mysql.connector import (connection) cnx = connection.MySQLConnection(user='root', host='127.0.0.1') cur = cnx.cursor(buffered=True) cur.execute("SELECT VERSION()") print(cur.fetchone()) cur.close() cnx.close()
ç¶ãã¦SQLãå¤æ´ãã¦å®éã®ãã¼ã¿ã¨ãã¦å ã»ã©ã¤ã³ãã¼ãããworld_xã¹ãã¼ãã®countryinfoãã¼ãã«ã®ãã¼ã¿ãåå¾ãã¦ã¿ã¾ãããã®ãã¼ãã«ã¯Collectionã¨ãªããã¼ãã«æ§é (JSONåã®åã¨JSONããã¥ã¡ã³ãå ã®_idè¦ç´ ãæ½åºããGenerated Columnã®_idåã®ã¿ã_idåã¯ä¸»ãã¼)ã¨ãªã£ã¦ãã¾ãã
mysql> desc world_x.countryinfo; +-------+-------------+------+-----+---------+------------------+ | Field | Type | Null | Key | Default | Extra | +-------+-------------+------+-----+---------+------------------+ | doc | json | YES | | NULL | | | _id | varchar(32) | NO | PRI | NULL | STORED GENERATED | +-------+-------------+------+-----+---------+------------------+ 2 rows in set (0.02 sec)
from mysql.connector import (connection) cnx = connection.MySQLConnection(user='root', host='127.0.0.1') cur = cnx.cursor(buffered=True) cur.execute("SELECT * FROM world_x.countryinfo") print(cur.fetchone()) cur.close() cnx.close()
Jupyter Notebookããã®X Dev APIã§ã®ã¢ã¯ã»ã¹
å
ã»ã©ã¨åæ§ã«ããªãã¡ã¬ã³ã¹ããã¥ã¢ã«ã®ãµã³ãã«ã³ã¼ããå°ãå¤æ´ãã¦ãSQLæã§ãã¢ã¯ã»ã¹ããCollectionã§ããcountryinfoãã¼ãã«ã«X Dev APIã§ã¢ã¯ã»ã¹ãã¦ã¿ã¾ããããã§ã¯10ããã¥ã¡ã³ã(=10è¡)åå¾ãã¦é
ådocã«æ ¼ç´ããã®å
é ã¬ã³ã¼ãã®ãã¡Nameè¦ç´ ãåå¾ãã¦è¡¨ç¤ºãã¦ãã¾ããã¤ã³ãã¼ã対象ããã±ã¼ã¸ã¯mysqlxã«ãªã£ã¦ãã¾ãã
import mysqlx # Connect to server on localhost session = mysqlx.get_session({ 'host': 'localhost', 'port': 33060, 'user': 'root', 'password': '' }) schema = session.get_schema('world_x') # Use the collection 'my_collection' collection = schema.get_collection('countryinfo') # Specify which document to find with Collection.find() result = collection.find().limit(10).execute() # Print document docs = result.fetch_all() print('Name: {0}'.format(docs[0]['Name'])) session.close()
ã¡ãªã¿ã«MySQLãµã¼ãã¼ã®ã¦ã¼ã¶ã¼ã«ãã¹ã¯ã¼ãããªãå ´åããã¼ã3306ã使ç¨ããMySQLæ¨æºãããã³ã«ã®ä¾ã§ã¯æ¥ç¶æ å ±ã«ãã¹ã¯ã¼ãã«é¢ãã表è¨ã¯ãªãã¦ãåé¡ããã¾ããããX Dev APIã®å ´åã¯ç©ºæåãæå®ããªãã¨æ¥ç¶æã«ã¨ã©ã¼ã¨ãªãã¾ãã
ããããã¦æ°ã¥ããã¦ããªãããç¥ããªãMySQLã®ãã¹ã¯ã¼ãé¢é£ã®æ©è½
validate_passwordãã©ã°ã¤ã³
MySQL 5.6ã§ç»å ´ããMySQL 5.7.8ããã¯Yumã¾ãã¯SLESã¬ãã¸ããªããã®ã¤ã³ã¹ãã¼ã«ããããã¯rpmããã±ã¼ã¸ã§ã¤ã³ã¹ãã¼ã«ããå ´åã«æå¹ã«ãªã£ã¦ããã®ãvalidate_passwordプラグインã§ããvalidate_passwordãã©ã°ã¤ã³ã¯ãã¹ã¯ã¼ã強度ã®æ¤è¨¼ãè¡ããã©ã°ã¤ã³ã§ãã「初心者殺しの罠」ã ã®「クソ機能→速攻削除」ã ã®è¨ããã¡ããããããããªããããããªæ©è½ã ã£ãããã¾ããtarã§å
¥ããã°ããã©ã«ãã§ã¯ç¡å¹ãªã®ã§rpmãããªãã¦tarã§å
¥ãããã
æ©è½ã¨è¨å®ã®æ¦è¦ã¯MySQL 5.6の日本語リファレンスマニュアルãåèã«ãã¦ã¿ã¦ä¸ããã
validate_passwordãã©ã°ã¤ã³ã§ã¯ä»¥ä¸ã®é
ç®ãæ¤è¨¼ãã¾ãã
https://dev.mysql.com/doc/refman/8.0/en/validate-password-options-variables.html
validate_password_check_user_name | ãã¹ã¯ã¼ãã¨ã¦ã¼ã¶åãæ¯è¼ |
validate_password_dictionary_file | ç¦æ¢ããããã¹ã¯ã¼ãã®ãªã¹ããæ ¼ç´ããè¾æ¸ãã¡ã¤ã«å |
validate_password_length | æä½æåæ° |
validate_password_mixed_case_count | 大æåã¨å°æåãå«ãããã¨ãå¼·å¶ |
validate_password_number_count | æ°åã®æ° |
validate_password_special_char_count | ç¹æ®æåã®æ° |
validate_password_policy | ããªã·ã¼ã®å¼·åº¦ |
validate_password_check_user_nameã¯MySQL 5.7.15 (= GAå¾) ã«ã¦è¿½å ããããªãã·ã§ã³ã§ãããã®ãã©ã¡ã¿ã ON ã«è¨å®ããã¨ããã¹ã¯ã¼ãã®è¨å®ãå¤æ´ã®éã«ã¦ã¼ã¶ã¼åããããã¯éã«ãªã£ã¦ããªããã®æ¤è¨¼ãè¡ããã¾ããããã§ã®ã¦ã¼ã¶ã¼å㯠USER()ããã³CURRENT_USER()ã®ã¦ã¼ã¶ã¼åé¨åã§ã(ãã¹ãåã¯æ¤è¨¼ã«å©ç¨ãããªã)ãã¾ããã¤ãåã§ã®ã¦ã¼ã¶ã¼åã¨ã®æ¯è¼ã¨ãªãã¾ãã
ãã¹ã¯ã¼ãåå©ç¨ããªã·ã¼
以å使ã£ããã¹ã¯ã¼ããåå©ç¨ãããªãé¢åãããããªã·ã¼ãè¨å®ã§ããæ©è½ãMySQL 8.0.3 RCã§è¿½å ããã¾ãããã¾ã「速攻削除」ã¨ãè¨ããã¡ããã®ããªãããã¨ããããããã©ã«ãã§ã¯ãªãã«ãªã£ã¦ããã®ã§å®å¿ãã¦ä¸ããã
https://dev.mysql.com/doc/refman/8.0/en/password-management.html#password-reuse-policy
è¨å®é ç®ã¯ä¸è¨ã®2ã¤ã§ãã
password_history | ä½ä¸ä»£ã®ãã¹ã¯ã¼ããå©ç¨ä¸å¯ã¨ããã |
password_reuse_interval | åããã¹ã¯ã¼ãã¯ã©ãã ãçµããªãã¨åå©ç¨ã§ããªãã |
ãã®ãã©ã¡ã¼ã¿ã¯ãµã¼ãã¼å ¨ä½ã®è¨å®å¤ã¨ãªãã¾ããMySQL 8.0ã®æ°æ©è½ SET PERSIST 文 ã§ãè¨å®ã§ãã¾ãã
CREATE USERæãALTER USERæã§ã¦ã¼ã¶ã¼ãã¨ã«è¨å®ãããã¨ãã§ãã¾ãã
mysql> CREATE USER 'yoku0825'@'localhost' PASSWORD HISTORY 825; mysql> ALTER USER 'soudai1025'@'localhost' PASSWORD REUSE INTERVAL 1025 DAY;
ããæãã®è¨å®ãã§ãã¾ããã
å¤æ´ãããã¹ã¯ã¼ãã¯æ°ãã«è¿½å ãããpassword_historyãã¼ãã«ã«æ ¼ç´ããã¦ããã¾ãã
mysql> DESC password_history; +--------------------+--------------+------+-----+----------------------+-------+ | Field | Type | Null | Key | Default | Extra | +--------------------+--------------+------+-----+----------------------+-------+ | Host | char(60) | NO | PRI | | | | User | char(32) | NO | PRI | | | | Password_timestamp | timestamp(6) | NO | PRI | CURRENT_TIMESTAMP(6) | | | Password | text | YES | | NULL | | +--------------------+--------------+------+-----+----------------------+-------+ 4 rows in set (0.00 sec)
ä¾ãã°ãã¹ã¯ã¼ããå¤æ´ãã確èªãã¦ã¿ãã¨ä¸è¨ã®ãããªç¶æ ã¨ãªãã¾ãã(ãã¹ã¯ã¼ãã®æååã¯ããã¼ã§ãããã¶ã)
mysql> ALTER USER 'yoku0825'@'localhost' IDENTIFIED BY 'ConoHa'; mysql> ALTER USER 'yoku0825'@'localhost' IDENTIFIED BY 'Anzu'; mysql> SELECT * FROM password_history; +-----------+----------+----------------------------+-------------------------------------------+ | Host | User | Password_timestamp | Password | +-----------+----------+----------------------------+-------------------------------------------+ | localhost | yoku0825 | 2017-12-06 00:02:22.120225 | *01234567890123456789A1FB252ADCCED23DHOGE | | localhost | yoku0825 | 2017-12-06 00:01:45.514278 | *9876543210987654321006CDBDBBE5538249FUGA | +-----------+----------+----------------------------+-------------------------------------------+
ã¡ãªã¿ã«MySQL 5.7.9 GAã§è©±é¡ã¨ãªããMySQL 5.7.11ã§ããã©ã«ãå¤ã360æ¥ãã0 (= ç¡å¶é) ã«å¤æ´ããã default_password_lifetime ã¯MySQL 8.0.3 RCã®æç¹ã§ã®ããã©ã«ãå¤ã¯0ã¨ãªã£ã¦ãã¾ãã
https://dev.mysql.com/doc/refman/8.0/en/server-system-variables.html#sysvar_default_password_lifetime
GAã§ã©ããªããã¯èª°ãç¥ãã¾ããã
MySQL Fabric? ç¥ããªãåã§ããã ã¨ããããå¯ç¨æ§é¢é£ã®è£½åãåä¸é害ç¹ãæã£ã¦ãããéçºã¨ã³ã¸ãã¢ãåä¸é害ç¹ã¨ãæªãåè«ã§ãããã
MySQLã®å ¬å¼Dockerã¤ã¡ã¼ã¸ã使ããã¨ããã¨ãã®ã¡ã¢
(追è¨) MySQLçãèªãåªç§ãªå¤é¨APIã«ãã£ã¦ãææããã ããã®ã§ãã¹ã¯ã¼ãå¨ããè¨æ£
`-e MYSQL_ALLOW_EMPTY_PASSWORD=1` ã§rootã®ãã¹ã¯ã¼ã空ã£ã½ã«ã§ããã¾ãã;) @RKajiyama
— yoku0825 (@yoku0825) August 21, 2017
MySQLã®å ¬å¼Dockerã¤ã¡ã¼ã¸ã使ããã¨ããã¨ãã®ã¡ã¢ - rkajiyamaã®æ¥è¨https://t.co/hqEWOTdxID
MySQLãµã¼ãã¼ã®ã³ãã¥ããã£çãã¤ããªãå«ã¾ããå ¬å¼Dockerã¤ã¡ã¼ã¸ã®ããã¥ã¢ã«ã¯ãã¡ãã
https://hub.docker.com/r/mysql/mysql-server/
ããã¥ã¢ã«ã«æ¸ãã¦ããåºæ¬ã®èµ·åããã³ãã³ã
docker run --name my-container-name -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mysql/mysql-server:tag
ãªãã·ã§ã³ | è¨å®é ç® |
---|---|
--name | my-container-nameã¯ä»»æã®å称 |
-d | 対象ã¤ã¡ã¼ã¸ ã¿ã°ã§MySQLã®ãã¼ã¸ã§ã³çãæå® |
-e | ç°å¢å¤æ° ããã¥ã¢ã«ä¸æ®µã®Environment Variables |
-p | ãã¼ããã©ã¯ã¼ãã£ã³ã°è¨å® ãã¹ãå´:ã³ã³ããå´ |
-v | ãã£ã¬ã¯ããªã®ãããã³ã° ãã¹ãå´:ã³ã³ããå´ |
ãã¼ã¸ã§ã³çãæå®ããããã®ã¿ã°ã®ä¸è¦§
5.5ãã8.0ã®ãã¤ãã¼ãã¼ã¸ã§ã³ãæå®å¯è½(å
¨ã¦ã§ã¯ãªã)
https://hub.docker.com/r/mysql/mysql-server/tags/
èµ·åã³ãã³ãä¾
docker run --name my80 -d mysql/mysql-server:8.0 -e MYSQL_ROOT_PASSWORD=mysql -p 6603:3306 -v /Users/mysql/mysql-docker/data:/var/lib/mysql
ã¡ãã£ã¨ãããããã©ãã
MySQLãµã¼ãã¼ã®ãã¹ã¯ã¼ãè¨å®ã¯å¿
é å¿
é ã§ã¯ãªãããã©ãªãã·ã§ã³å¿
é
åæåãªãã·ã§ã³ --initialize-insecure ã«è©²å½ããè¨å®ã¯ãªããããããã©ãªãã·ã§ã³ã®æå®ãå¿
è¦ããã¹ã¯ã¼ãé¢é£ã®ç°å¢å¤æ°ãè¨å®ãããã¦ããªãã¨ã³ã³ãããèµ·åããªããMYSQL_RANDOM_ROOT_PASSWORDã¨MYSQL_ONETIME_PASSWORDãè¨å®ãã㨠--initialize ã¨åæ§ã®åãã«ãªã模æ§ãMYSQL_ALLOW_EMPTY_PASSWORDã使ã㨠--initialize-insecure ã¨åæ§ã«ã
MYSQL_ROOT_PASSWORD | æ示çã«ãã¹ã¯ã¼ããè¨å® |
MYSQL_RANDOM_ROOT_PASSWORD | ã©ã³ãã ãã¹ã¯ã¼ããè¨å® |
MYSQL_ONETIME_PASSWORD | ååãã°ã¤ã³æã«ãã¹ã¯ã¼ãã®å¤æ´ãå¼·å¶ |
MYSQL_ALLOW_EMPTY_PASSWORD | --initialize-insecureã¨åæ§ã«ãã¹ã¯ã¼ãç¡ãã許容 |
ã©ã³ãã ãã¹ã¯ã¼ãã¯ä¸è¨ã³ãã³ãã§è¡¨ç¤ºããããã°ã«ã¦ç¢ºèªå¯è½
docker logs my-container-name
ä¸ç¬ã§ã¯èµ·åããªã(ãã¤èµ·åãå®äºãããåãããªã)
ã³ã³ããã®èµ·åã³ãã³ããæã¤ã¨ä¸ç¬ã§å¿çãè¿ã£ã¦ãã¦åºåããããã¦ã·ã³ãã«ãMySQLãµã¼ãã¼ããã§ã«èµ·åãã¦ããã®ãã¨æã£ããã¾ã ã ã£ããããã
docker psã®STATUS表示ãhealth: startingãªãèµ·åä¸ãhealthyãªãèµ·åæ¸ã¿ã
(docker runã³ãã³ãã®ãªãã·ã§ã³ã§ãã°ãã³ã³ã½ã¼ã«ã«åºãããã«ããã°ããããªè©±ã ãã©)
ãã¼ããã©ã¯ã¼ãã£ã³ã°è¨å®æããã¹ãå´ããã®æ¥ç¶ã®ããã«ã¯ã¦ã¼ã¶ã¼å¿ è¦
MySQLãµã¼ãã¼å´ã§ã¦ã¼ã¶ã¼ãä½ã£ã¦ãªã段éã§ãã¹ãå´ã®mysqlããæ¥ç¶ãã«è¡ãã¨ä»¥ä¸ã®ã¨ã©ã¼ãã¨ã©ã¼ã«åºåãããIPã¢ãã¬ã¹172.17.0.1ã¯Dockerã³ã³ããã®ãããã¯ã¼ã¯ã®ãã®ã
ERROR 1130 (HY000): Host '172.17.0.1' is not allowed to connect to this MySQL server
MySQL 5.7.17ã§è¿½å ããããã®ãã©ã°ã¤ã³ã«ã¤ãã¦
ãã®è¨äºã¯ MySQL Casual Advent Calendar 2016 ã®13æ¥ç®ã®è¨äºã§ãï¼
MySQL 5.7.17がリリースãããããã§ãããみなさん待望のあの機能ãã¤ãã«è¿½å ããã¾ããããªã®ã§æ©é試ãã¦ã¿ã¾ãããã
ãã©ã°ã¤ã³ã¨ãã¦ã®æ©è½è¿½å ãªã®ã§ãã¾ãã¯ãã©ã°ã¤ã³ãã¤ã³ã¹ãã¼ã«ãã¾ãã
ãhttp://dev.mysql.com/doc/refman/5.7/en/connection-control-plugin-installation.html
mysql> INSTALL PLUGIN connection_control SONAME 'connection_control.so'; Query OK, 0 rows affected (0.02 sec) mysql> INSTALL PLUGIN connection_control_failed_login_attempts SONAME 'connection_control.so'; Query OK, 0 rows affected (0.00 sec) mysql> SELECT PLUGIN_NAME, PLUGIN_STATUS FROM INFORMATION_SCHEMA.PLUGINS -> WHERE PLUGIN_NAME LIKE 'connection%'; +------------------------------------------+---------------+ | PLUGIN_NAME | PLUGIN_STATUS | +------------------------------------------+---------------+ | CONNECTION_CONTROL | ACTIVE | | CONNECTION_CONTROL_FAILED_LOGIN_ATTEMPTS | ACTIVE | +------------------------------------------+---------------+ 2 rows in set (0.00 sec)
ãã©ã°ã¤ã³ã®ã¤ã³ã¹ãã¼ã«æã«ã·ã¹ãã å¤æ°ãªãã³ã«ã¹ãã¼ã¿ã¹å¤æ°ã追å ããã¾ãã
mysql> SHOW GLOBAL VARIABLES LIKE 'connection_control%'; +-------------------------------------------------+------------+ | Variable_name | Value | +-------------------------------------------------+------------+ | connection_control_failed_connections_threshold | 3 | | connection_control_max_connection_delay | 2147483647 | | connection_control_min_connection_delay | 1000 | +-------------------------------------------------+------------+ 3 rows in set (0.01 sec) mysql> SHOW GLOBAL STATUS LIKE 'connection_control%'; +------------------------------------+-------+ | Variable_name | Value | +------------------------------------+-------+ | Connection_control_delay_generated | 0 | +------------------------------------+-------+ 1 row in set (0.01 sec)
ã·ã¹ãã å¤æ°ã«ã¤ãã¦ã¯ä»¥ä¸ã®éãã§ãã
connection_control_failed_connections_threshold | æ¥ç¶ã«å¤±æããå ´åã«é 延ãé©ç¨ããã¾ã§ã®åæ°ã®é¾å¤ |
connection_control_min_connection_delay | å½åã®é 延æé(ããªç§) |
connection_control_max_connection_delay | æ大ã®é 延æé(ããªç§) |
é¾å¤ãè¶
ãã¦æ¥ç¶ã«å¤±æãããã³ã«connection_control_min_connection_delayåã®é
延ã追å ããã¾ãã
ã§ã¯ããã©ã«ãå¤ã®ã¾ã¾è©¦ãã¦ã¿ã¾ãããã
$ while true; do time ./mysql -uscott -ptiger; done mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m0.014s user 0m0.007s sys 0m0.004s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m0.014s user 0m0.007s sys 0m0.003s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m0.010s user 0m0.006s sys 0m0.003s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m1.017s user 0m0.006s sys 0m0.003s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m2.015s user 0m0.007s sys 0m0.004s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m3.017s user 0m0.007s sys 0m0.004s mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'scott'@'localhost' (using password: YES) real 0m4.018s user 0m0.006s sys 0m0.005s mysql: [Warning] Using a password on the command line interface can be insecure.
4åç®ã®å¤±æããé
延ã1ç§ãã¤è¿½å ããã¦ããã®ãåããã¾ãã
ãã®Connection-Controlãã©ã°ã¤ã³ã«ãã£ã¦ç·å½ããæ»æ(ãã«ã¼ããã©ã¼ã¹ã¢ã¿ãã¯)ãªã©ã®å¯¾çã¨ãããã¨ãã§ãããã§ãã
MySQL 5.7.17ã§ã¯ãã«ããã¹ã¿ã¼åã¬ããªã±ã¼ã·ã§ã³ã®グループレプリケーション プラグインがGAã«ãªãã¨ãã大ããªæ©è½è¿½å ãããã¾ãããã°ã«ã¼ãã¬ããªã±ã¼ã·ã§ã³ã¨é¡ä¼¼ããGalera Clusterとの機能の比較ã性能比較ãå ¬éããã¦ãã¾ããã°ã«ã¼ãã¬ããªã±ã¼ã·ã§ã³ã¯ãã£ã¨誰かãæ¸ãã¦ãããã¨æãã®ã§ãæ°ã¥ãã¦ããªã人ãå¤ãããªConnection-Controlãã©ã°ã¤ã³ã«ã¤ãã¦æ¸ãã¦ã¿ã¾ããã
MySQL 5.7ã®GeoHash
MySQL 5.7ã§è¿½å ãããæ©è½ä¸ã¤ã«Boost.Geometryとの統合ã«ããGISã®å¼·åãããã¾ããããã«GeoHashã¨ããæ©è½ã追å ããã¦ãã¾ããGeoHashã¯å°ç¹ã®æ å ±ãããã·ã¥å¤ã¨ãã¦æ ¼ç´ããæ©è½ã§ãããã·ã¥é·ã«ãã£ã¦ç²¾åº¦ãå¤ãããã¨ãã§ãã¾ãã緯度çµåº¦ã®å¤ããé·ãã®ç°ãªãGeoHashãçæããããããå度緯度çµåº¦ã®å¤ãç®åºãã¦ã¿ã¾ããä»åã®ä¾ã§ã¯ç´ç·è·é¢ã§ç´3kmé¢ãã2å°ç¹ã®ç·¯åº¦çµåº¦ãå©ç¨ãã¦ãã¾ãã
ãªã緯度çµåº¦ã®æ
å ±ããã³åé²è¡¨è¨ã¯ä¸è¨ã®ãµã¤ãã®æ
å ±ã使ãã¾ãã
http://user.numazu-ct.ac.jp/~tsato/webmap/sphere/coordinates/advanced.html
é¢æ° | å 容 |
ST_GeoHash() | 緯度çµåº¦ã®å¤ã¾ãã¯POINTåã®å¤ããGeoHashå¤ãçæ |
ST_LatFromGeoHash() | GeoHashå¤ãã緯度ãç®åº |
ST_LongFromGeoHash() | GeoHashå¤ããçµåº¦ãç®åº |
ST_PointFromGeoHash() | GeoHashå¤ãã緯度çµåº¦ãç®åºãPOINTåã®å¤ãè¿ã |
# 横æµã¹ã¿ã¸ã¢ã ãã¼ã ãã¼ã¹ä»è¿ åç·¯35°26â²35â³ æ±çµ139°38â²25â³ # åé²è¡¨è¨ åç·¯35.442972 æ±çµ139.640223 mysql> SELECT -> ST_GeoHash(139.640223, 35.442972, 4) AS GeoHash4, -> ST_GeoHash(139.640223, 35.442972, 32) AS GeoHash32; +----------+------------------------+ | GeoHash4 | GeoHash32 | +----------+------------------------+ | xn73 | xn739s4ym0c53e0pys2c9g | +----------+------------------------+ 1 row in set (0.01 sec) mysql> SELECT -> ST_LatFromGeoHash(ST_GeoHash(139.640223, 35.442972, 4)) AS GeoHash4, -> ST_LatFromGeoHash(ST_GeoHash(139.640223, 35.442972, 32)) AS GeoHash32; +----------+-----------+ | GeoHash4 | GeoHash32 | +----------+-----------+ | 35.4 | 35.442972 | +----------+-----------+ 1 row in set (0.00 sec) mysql> SELECT -> ST_LongFromGeoHash(ST_GeoHash(139.640223, 35.442972, 4)) AS GeoHash4, -> ST_LongFromGeoHash(ST_GeoHash(139.640223, 35.442972, 32)) AS GeoHash32; +----------+------------+ | GeoHash4 | GeoHash32 | +----------+------------+ | 139.7 | 139.640223 | +----------+------------+ 1 row in set (0.01 sec)
# 横æµé§ ããè¥¿å£ åç·¯35°28â²2â³ æ±çµ139°37â²23â³ # åé²è¡¨è¨ åç·¯35.467360 æ±çµ139.623148 mysql> SELECT -> ST_GeoHash(139.623148, 35.467360, 4) AS GeoHash4, -> ST_GeoHash(139.623148, 35.467360, 32) AS GeoHash32; +----------+----------------------------------+ | GeoHash4 | GeoHash32 | +----------+----------------------------------+ | xn73 | xn73c0wkr5j52nh2eub7y5bpbpbpbpbp | +----------+----------------------------------+ 1 row in set (0.00 sec) mysql> SELECT -> ST_LatFromGeoHash(ST_GeoHash(139.623148, 35.467360, 4)) AS GeoHash4, -> ST_LatFromGeoHash(ST_GeoHash(139.623148, 35.467360, 32)) AS GeoHash32; +----------+-------------------+ | GeoHash4 | GeoHash32 | +----------+-------------------+ | 35.4 | 35.46736000000001 | +----------+-------------------+ 1 row in set (0.01 sec) mysql> SELECT -> ST_LongFromGeoHash(ST_GeoHash(139.623148, 35.467360, 4)) AS GeoHash4, -> ST_LongFromGeoHash(ST_GeoHash(139.623148, 35.467360, 32)) AS GeoHash32; +----------+--------------------+ | GeoHash4 | GeoHash32 | +----------+--------------------+ | 139.7 | 139.62314800000001 | +----------+--------------------+ 1 row in set (0.00 sec)
ããã·ã¥é·ã4æ¡ã«ããå ´åã¯æ å ±ã丸ããããåã緯度çµåº¦ã®æ å ±ã«ãªã£ã¦ãã¾ãããã©ã¤ãã·ã¼ä¿è·ãªã©ã®è¦³ç¹ãããæ£ç¢ºãªä½ç½®ãå©ç¨ããã®ã§ã¯ãªã大ã¾ããªå ´æãã¨ãªã¢ã§è¡¨ç¤ºããããªã©ã«å©ç¨ã§ãããã§ãã