In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "the specific process of configuring Mysql coding in Ubuntu". In the daily operation, I believe that many people have doubts about the specific process of configuring Mysql coding in Ubuntu. The editor consulted all kinds of materials and sorted out simple and easy-to-use methods of operation. I hope it will be helpful to answer the doubts of "configuring Mysql coding in Ubuntu". Next, please follow the editor to study!
Find the configuration file
I installed it through sudo apt-get install mysql. The configuration file for mysql is in / etc/mysql/my.cnf
If you cannot find this file, you can run sudo find /-iname'* .cnf'to find all the cnf files
Modify the configuration file
Add under [mysqld]
Default-character-set=utf8
Add under [client]
Default-character-set=utf8
Restart mysql
Sudo service mysql restart
Log in to mysql to see if it is successful.
# mysql-u root
Mysql > SHOW VARIABLES LIKE 'char%'
+-+
| | Variable_name | VALUE |
+-+
| | character_set_client | utf8 |
| | character_set_connection | utf8 |
| | character_set_database | utf8 |
| | character_set_filesystem | BINARY |
| | character_set_results | utf8 |
| | character_set_server | utf8 |
| | character_set_system | utf8 |
| | character_sets_dir | / usr/share/mysql/charsets/ |
+-+
8 ROWS IN SET (0.00 sec)
Restart mysql
Depending on the way you install mysql, restart your mysql with unused commands. If you have configured to use mysqld self-startup mode, you can execute the
# / etc/rc.d/init.d/mysql restart
To restart.
Or the way you configure mysql as a system service, you can execute
# service mysql restert
At this point, the study of "the specific process of configuring Mysql coding in Ubuntu" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.