Solved

Database 'model' transaction logs are full and I can't start SQL...

Posted on 2010-08-31
1
273 Views
Last Modified: 2012-06-22
SQL will start right now and then stop about 3 seconds after and I see the following entry in the event viewer:

The transaction log for database 'model' is full. To find out why space in the log cannot be reused, see the log_reuse_wait_desc column in sys.databases

However, I can't go into the management studio or anything because it's won't allow it to start long enough for me to connect. How can I empty the transaction logs for 'model' without being in SQL management studio to run a query?

This is SQL 2005 by the way...
0
Comment
Question by:willlandymore
1 Comment
 
LVL 28

Accepted Solution

by:
Ryan McCauley earned 500 total points
ID: 33568383
The "Model" database is what SQL Server uses as the baseline for creating new databases - it doesn't have any actual data in it. If you have another copy of SQL Server elsewhere on your network (as long as it's the same version or lower), you can just replace the model.MDF and model.LDF files with the ones from the other server, and then SQL should start without a problem.

If you don't have another SQL Server instance handy, you'll need to rename the log file, then start SQL Server (which will flag the model database as "Suspect", since the log is missing). Once it does that, you can ask SQL Server to recreate the log file from scratch. See this link for instructions on recreating a log file when it's missing:

http://www.tech-recipes.com/rx/1867/sql_server_2005_how_to_attach_or_reattach_a_database_missing_the_ldf/
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

There are some very powerful Data Management Views (DMV's) introduced with SQL 2005. The two in particular that we are going to discuss are sys.dm_db_index_usage_stats and sys.dm_db_index_operational_stats.   Recently, I was involved in a discu…
by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now