Re: Can anyone 'crash course' me in SQL maintenance?
- From: Ryan <mindflux98@xxxxxxxxx>
- Date: Sat, 16 Feb 2008 08:01:36 -0800 (PST)
On Feb 16, 7:43 am, "Paul Shapiro" <p...@xxxxxxxxxxxxxxxxxxxxxxx>
wrote:
a) The log file lets you backup data in smaller chunks while still having
the possibility of frequent backups. If you take a nightly full db backup,
that would leave you with 24 hours of vulnerability to data loss. If full
backups take 2 hours, you couldn't possibly do a full backup more than once
every two hours. Full backups take a lot of server resources, so you'd like
to avoid doing them while many users are working. The log file can be much
smaller than the data since it only records the transactions that occur. SO:
a typical plan is a nightly or weekly full backup, with log file backups
every hour, or maybe even every few minutes depending on how much data
you're willing to lose.
Paul,
Thanks. My current backup strategy is as follows:
Nightly backup at 3 AM.
Weekly Backup on Sunday at 5AM
transaction log backups hourly during business hours
I never shrink the database itself, as like you said it just
increases the log size. What I'm trying to figure out is why the free
space in both the log and the database is so large? The log file says
it contains 10G of data, but the actual size is 20G (10G of free
space), the data stats are much the same. 10G of data, 10g of free
space, or there about.
Obviously 20G of system resources being used to 'free' space is a
waste (or it is to me). Why does the log file not shrink
appropriately? After each transaction log backup the system should
mark it as complete and can be overwritten or erased .. but this
seemingly doesn't happen.
The log file space marked as "used" is holding the log data since the last
transaction log backup. Assuming your database is in Full logging mode, the
active portion of the backup log continues to grow until you backup the log.
A backup log with 10GB suggests either HUGE activity on a 20GB database. And
actually I'm not sure from what you show if the data is 20GB, or 2 GB? Does
your 20GB database size include the data file and the log file? In that case
if the log file is 18GB the data is only 2GB.
According to SQLEM my database is 10GB of data within it, but the file
size is 20GB. The log file says there's 10GB of data within it and
10GB of free space (20GB total). So the sum of my DB and LOG are 40GB,
but the free space between them is 20GB iteself!
Something with my plan must not be right. If the used portion of the
log is how much data has been written since the last Transaction
backup. There are 10 incremental T-LOG backups that occur throughout
the day, the last one at 8PM. After 8PM we have little to no
activity. I would think log would show that there is only a few
hundred megs(if that much even) of used log space after 8PM.
.
- Follow-Ups:
- Re: Can anyone 'crash course' me in SQL maintenance?
- From: Paul Shapiro
- Re: Can anyone 'crash course' me in SQL maintenance?
- References:
- Can anyone 'crash course' me in SQL maintenance?
- From: Ryan
- Re: Can anyone 'crash course' me in SQL maintenance?
- From: Kevin Weilbacher
- Re: Can anyone 'crash course' me in SQL maintenance?
- From: Paul Shapiro
- Can anyone 'crash course' me in SQL maintenance?
- Prev by Date: Re: LAN ip subnet is moving off from a bigger enterprise
- Next by Date: FTP/Hotmail Issues with XP Clients thru SBS2003 R2
- Previous by thread: Re: Can anyone 'crash course' me in SQL maintenance?
- Next by thread: Re: Can anyone 'crash course' me in SQL maintenance?
- Index(es):
Relevant Pages
|
Loading