Solved

simple backup not available in management studio

Posted on 2009-07-07
3
175 Views
Last Modified: 2012-05-07
I have a database that is scheduled to backup once/day.  I would like to reduce the log file size. I tried doing transaction log backups but the trn file created was 37GB. I tried to change the scheduled backup to be a simple recovery model but Management Studio/Maintenance plan/backup only allows me to select Full, Differential or Transactional. We don't need hourly transaction backups on this problem database. A daily backup will suffice. Our most important database is larger and has hourly transaction backups. Here is a comparison of this problem database with our bigger production database.
Problem db file sizes               Production database file sizes
ldf  37                                         1
mdf  4                                         5
bak  3                                         5 (including trn files)    
There aren't a huge number of transactions going on in the problem database.
How can I schedule a simple backup in Management Studio?
0
Comment
Question by:dwiseman3
  • 2
3 Comments
 
LVL 15

Expert Comment

by:mcmonap
ID: 24796507
Hi dwiseman3,
>>>I tried to change the scheduled backup to be a simple recovery model but Management Studio/Maintenance plan/backup only allows me to select Full, Differential or Transactional <<<
It sounds as though you want to change the recovery model of your database as well as your backup method.  If you right click the database select "properties" and the select "options" you can see the recovery model  drop down list.  changing this to simple will mean that your log file autotruncates, this would mean you can no longer do transaction log backups and should help to maintain your log file size (depending on your application)
Once this is done you would need to change your backup maintenance plan to a full backup once per day - you can deselect transaction and differential options if you don't need them.
Do make sure you understand the consequences of changing these option before you proceed and make sure you have a good (tested) backup.  That said everything is pretty risk free if you know what you are doing
0
 

Author Comment

by:dwiseman3
ID: 24796582
I see what you're saying. Will changing the recovery model 'midstream' do any damage?
0
 
LVL 15

Accepted Solution

by:
mcmonap earned 500 total points
ID: 24798518
Nope, that will be fine - essentially all you are losing by moving to a simple recovery model is the facility to recover data to the second which you said is not important.  The database will carry on working as normal.  Assuming the application uses small transactions then you could also look at shrinking the log file to a smaller size to better conserve disk space, the snippet below will do this (it is best to do this straight after the log has been truncated), the code below is straight out of SQL BOL (books on-line).
You want to size the database files so they grow as little as possible, this will minimise file fragmentation on the disk - unless you know the growth rates already it easiest to note this over time.

USE yourDatabase;

GO

-- Truncate the log by changing the database recovery model to SIMPLE.

ALTER DATABASE yourDatabase

SET RECOVERY SIMPLE;

GO

-- Shrink the truncated log file to 1GB.

DBCC SHRINKFILE (yourDatabase_Log, 1024);

GO

Open in new window

0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I am showing a way to read/import the excel data in table using SQL server 2005... Suppose there is an Excel file "Book1" at location "C:\temp" with column "First Name" and "Last Name". Now to import this Excel data into the table, we will use…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
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…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

930 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

13 Experts available now in Live!

Get 1:1 Help Now