In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Some time ago, when archiving and collating historical data in MySQL, I found that a lot of SQL could not be executed. At first, I thought there was something wrong with the SQL statement I wrote. When I took out all the executing SQL, I found that the syntax was not wrong, but there was an error in the execution of the INSERT statement:
There is no problem with inserting the INSERT statement LIMIT 1. The preliminary estimate is that the transaction of INSERT is too large. After checking the information, we know that when creating temporary tables, MySQL will default to put the data files under the / tmp directory of the system. If the system's / tmp directory space is not large, the temporary table cannot be created. The path is controlled by the tmpdir parameter of MySQL. Because this is historical data, every INSERT statement to be inserted is followed by a large SELECT table, which is bound to create a temporary table. However, the / tmp directory of the system is not enough, so we can only modify tmpdir. This parameter cannot be directly modified. It needs to be written to the configuration file to restart and take effect. Create a tmp folder under a large space directory to modify permissions (777) and give it to tmpdir to use.
[mysqld] tmpdir = / data/tmp
Then restart MySQL to take effect, so that the problem is solved.
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