In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
This article is about the solution to the problem of garbled code in linux. The editor thought it was very practical, so I shared it with you as a reference. Let's follow the editor and have a look.
Linux Chinese garbled solution: for example, when log4j garbled, we can find the configuration file to set the character encoding to utf-8. If linux does not install the Chinese language pack, you can install the Chinese language pack to solve the problem.
We often encounter a lot of Chinese garbled problems under Linux.
Mysql Chinese garbled code
Vi / etc/my.cnf
Add under mysqld
[mysqld] character-set-server=utf8
Tomcat Chinese garbled code
Find tomcat/conf/sever.xml.
Insert URIEncoding= "UTF-8" in the tag below
Log4j garbled code
The profile used, insert in the configuration file
Log4j.appender.A1.Encoding=UTF-8
Linux has no Chinese language pack
View current language
Locale
Install simplified Chinese
Yum install kde-l10n-Chinese
Modify the configuration file etc/locale.conf
LANG= "zh_CN.UTF-8"
In addition, the time zone is not China by default, and it has suffered a loss, so the time zone has been changed to Asia and Shanghai.
Ln-sf / usr/share/zoneinfo/Asia/Shanghai / etc/localtime Thank you for your reading! On the linux Chinese garbled problem solutions to share here, I hope the above content can be of some help to you, so that you can learn more knowledge. If you think the article is good, you can share it and let more people see it.
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.