"Database ' tempdb ' log is full" latest workaround

Source: Internet
Author: User

The log for database ' tempdb ' is full
Execute SQL statement, no temporary table is used in the middle


Prompt server: Msg 9002, Level 17, State 2, line 1
The log for database ' tempdb ' is full. Back up the transaction log for the database to free up some log space.


On the net to find the next solution, is generally to expand the size of the temporary library log file resolution


Resolution process:
View the properties of the following database, which is autogrow and does not specify a maximum file size.
Baidu on the internet for a long time, tried some methods are not, the database disk has a lot of free space, try to take the heavy medicine.
Change the size of the tempdb data file and log file directly to 3000M,
Problem solving.


Record the command to empty the log:
DUMP TRANSACTION dbname with no_log
Truncate the transaction log command:
BACKUP LOG dbname with no_log
Shrink Log operations:
Right-click Database-Properties-All Tasks-Shrink database-file-select File-ok.





Although the log of tempdb is emptied with the empty log command, it does not resolve the issue. The data file and log file size of tempdb is enlarged,


ALTER DATABASE [tempdb] MODIFY FILE (NAME = N ' Templog ', MAXSIZE = UNLIMITED)
ALTER DATABASE [tempdb] MODIFY FILE (NAME = N ' Templog ', filegrowth = 10%)
ALTER DATABASE [tempdb] MODIFY FILE (NAME = N ' Templog ', SIZE = 1000)


ALTER DATABASE [tempdb] MODIFY FILE (NAME = N ' Tempdev ', SIZE = 1000)

"Database ' tempdb ' log is full" latest workaround

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.