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 > Database >
Share
Shulou(Shulou.com)06/01 Report--
Accident background: still on the road early in the morning, some people in the group reported an error "Unknown error 258" one after another, and later inquired about the log and found the error log.
Is the first reaction that there are not enough database connections? Causing a timeout? However, through the sql query, there were only about 40 connections at that time, so we continued to troubleshoot the problem and found that the disk io operation of the dbserver machine was very high and abnormal during this period of time. See the following figure for details.
If you find a disk io problem, continue to check the sqlserver log and find the reason: "Autogrow of file 'xxxx_log' in database' xxxx' was cancelled by user or timed out after 3398 milliseconds. Use ALTER DATABASE to set a smaller FILEGROWTH value for this file or to explicitly set a new file size."
This problem is found because the log log file is too large and has not been compressed, and when creating the database, 10% increment is selected by default to expand the log incremental file, so that 10% of the log file will become larger and larger, resulting in timeout and high io operations.
Solution:
1. Clean log files regularly to prevent log files from getting bigger and bigger.
USE [master] GO ALTER DATABASE database name SET RECOVERY SIMPLE WITH NO_WAIT GO ALTER DATABASE database name SET RECOVERY SIMPLE GO USE database name GO DBCC SHRINKFILE (N' database name _ Log', 11, TRUNCATEONLY) GO USE [master] GO ALTER DATABASE database name SET RECOVERY FULL WITH NO_WAIT GO ALTER DATABASE database name SET RECOVERY FULL GO
2. Modify the default database log increment of 10% to 500m (depending on the specific situation, it is generally enough)
Summary
The above is the whole content of this article. I hope the content of this article has a certain reference and learning value for everyone's study or work. Thank you for your support.
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.