The SQL Server transaction log is full and the 'primary'

Source: Internet
Author: User

The SQL Server transaction log is full and the 'primary'

1. This problem occurs because the log file reaches the limit of a single file. There are two ways to solve this problem.

1. log deletion: The solution is as follows:Dump TransactionDatabase NameWithNo_log executes this SQL statement

You can also contract the log file of the database: Right-click the database node and click[Task (t)] -> [Shrinkage (s)] -> [File (f)] After all, this is not a long-term solution.

2. Add data files

Solution: You can also add new data files to the primary group to solve this problem.
Alter database name Add file (name = logical file name, filename = 'C: \ filename. ndf'

Or select database> Properties> file to add a new file.

The first method is recommended because the SQL server log is too large, so it should be cleared frequently and save space.

This is the solution

SQL Server transaction log full and 'Primary'


 



 

Related Article

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.