Solved

database admin

Posted on 2012-04-03
6
231 Views
Last Modified: 2012-04-17
Can you guys give me some advice on backing up – clearing log files – rebuilding indexes.

In the past I have used maintenance plans but doing a bit of reading people say they are not really efficient.

Is this the case?
0
Comment
Question by:aneilg
6 Comments
 
LVL 17

Accepted Solution

by:
k_murli_krishna earned 133 total points
ID: 37800262
Go through the following:

A) Backup & Restore

SQL Server 2000 Backup and Restore
http://technet.microsoft.com/en-us/library/cc966495.aspx
Back Up and Restore of SQL Server Databases
http://msdn.microsoft.com/en-us/library/ms187048.aspx
Backup Overview (SQL Server)
http://msdn.microsoft.com/en-us/library/ms175477.aspx
SQL Server 2005 Backups
http://www.simple-talk.com/sql/backup-and-recovery/sql-server-2005-backups/

B) Clearing Log Files

How do you clear the transaction log in a SQL Server 2005 database?
http://stackoverflow.com/questions/56628/how-do-you-clear-the-transaction-log-in-a-sql-server-2005-database
How Can i clear log file in MS SQL SERVER 2005 Express Edition SP2
http://social.msdn.microsoft.com/Forums/en-US/sqlexpress/thread/5e9bfe22-24a4-4600-b735-73603841906f/

C) Rebuilding Indexes

Reorganize and Rebuild Indexes
http://msdn.microsoft.com/en-us/library/ms189858.aspx
Reorganise index vs Rebuild Index in Sql Server Maintenance plan
http://stackoverflow.com/questions/7579/reorganise-index-vs-rebuild-index-in-sql-server-maintenance-plan

You are correct. Following maintenance plans is somewhat inefficient. Instead, it is better to use in-built OR third party tools & instead even better use T-SQL OR DBCC operations. Cheers.
0
 
LVL 25

Assisted Solution

by:Lee Savidge
Lee Savidge earned 132 total points
ID: 37800341
Which version of SQL Server?

Backing up is fine on a maintenance plan. What you back up, how you back up is dependent on your requirements. Most of the time, in a full recovery mode I would do a full back up of the database once a day and then either daily, half daily or hourly backups of the transaction logs.

With rebuilding indexing etc., I would have a maintenance plan that you either run manually or maybe once a month. Much of the requirements here depend on how much usage the database has with regards to updates/deletes/inserts. Consider the indexes are like the ones in a book that is continually being written to or updated. They do go out of date so having a plan to manage this is good but it is pointless running daily unless you have massive record level changes or inserts and deletes.
0
 
LVL 25

Expert Comment

by:Lee Savidge
ID: 37800345
If you are in full recovery mode you must back the transaction logs up otherwise they will simply just grow and fill the disk. If you have simple recovery mode setup then you don't need to back them up.
0
Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

 
LVL 29

Expert Comment

by:Rich Weissler
ID: 37800893
One additional datapoint to toss out there.  I'm still rely heavily on the maintenance plan wizard, 'cause it's easy and does almost everything I need, and just tweak things to suit me when I finish.  The alternative I've looked at several times is Ola's maintenance plans -- http://ola.hallengren.com/
0
 

Author Comment

by:aneilg
ID: 37800995
thanks for the responce guys, all very gud tips.

thanks.
0
 

Author Closing Comment

by:aneilg
ID: 37855751
thanks.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Creating and Managing Databases with phpMyAdmin in cPanel.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

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

17 Experts available now in Live!

Get 1:1 Help Now