Showing posts with label backups. Show all posts
Showing posts with label backups. Show all posts

Tuesday, March 27, 2012

deleting old backups/trn files.

i have a maintenance plan running on my database, in which I told the wizard, on creation, to "remove files older than 4 week" and yet it doesn't seem to be doing so, as on checking this morning, diskspace was getting low, due to over 300gb of backups and trn' dating back to september.

Anyone have ny problems with maintenance plans not cleaning up when told?

ano because I do not use them. I create my own jobs.|||Maintenance plans are nothing but wizards that create SQL Agent jobs. If the job is modified, the maintenance plan has no clue that anything has changed, and if the maintenance plan is re-edited it will overwrite any other changes made to the jobs.
Maintenance plans are top candidates for the most confusing and misleading functionality within SQL server. I avoid them, except as a means of defining groups of databases for administrative purposes.
Open up the job in SQL Agent and check the code that is being run. It should be something like "EXEC xp_sqlmaint '-PlanID 02A52657-D546-11D1-9D8A-00A0C9054212...".
Post it here.|||here you go...

EXECUTE master.dbo.xp_sqlmaint N'-PlanID 2A998DBD-3F5D-4685-ACCA-70354638C8C5 -Rpt "D:\mssql\REPORTS\live DB Maintenance4.txt" -WriteHistory -VrfyBackup -BkUpOnlyIfClean -CkDBRepair -BkUpMedia DISK -BkUpDB "D:\mssql\BACKUP" -DelBkUps 4WEEKS -CrBkSubDir -BkExt "BAK"'|||There is an additional parameter for specifying deletion of reports, and for some reason this parameter is left out of the sql_maint documentation in Books Online. I am thinking it is "-DelRpts 4WEEKS", but I am not sure. I will look it up for you once I get back to my office.

Deleting old backups

Hi,
I'd like to set up a job SQL Server agent which will delete backup files
older than several months once a backup has succeeded. How can I write a
step to do this?
Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
(them)
As you see I have no idea as to where I begin with this. Can it be done?
Thanks very much for any ideas on this
Ant
On Mar 9, 2:11 am, Ant <A...@.discussions.microsoft.com> wrote:
> Hi,
> I'd like to set up a job SQL Server agent which will delete backup files
> older than several months once a backup has succeeded. How can I write a
> step to do this?
> Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
> (them)
> As you see I have no idea as to where I begin with this. Can it be done?
> Thanks very much for any ideas on this
> Ant
http://realsqlguy.blogspot.com/2007/02/cleaning-up-old-files.html
sql

Deleting old backups

Hi,
I'd like to set up a job SQL Server agent which will delete backup files
older than several months once a backup has succeeded. How can I write a
step to do this?
Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
(them)
As you see I have no idea as to where I begin with this. Can it be done?
Thanks very much for any ideas on this
AntOn Mar 9, 2:11 am, Ant <A...@.discussions.microsoft.com> wrote:
> Hi,
> I'd like to set up a job SQL Server agent which will delete backup files
> older than several months once a backup has succeeded. How can I write a
> step to do this?
> Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
> (them)
> As you see I have no idea as to where I begin with this. Can it be done?
> Thanks very much for any ideas on this
> Ant
http://realsqlguy.blogspot.com/2007...-old-files.html

Deleting old backups

Hi,
I'd like to set up a job SQL Server agent which will delete backup files
older than several months once a backup has succeeded. How can I write a
step to do this?
Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
(them)
As you see I have no idea as to where I begin with this. Can it be done?
Thanks very much for any ideas on this
AntOn Mar 9, 2:11 am, Ant <A...@.discussions.microsoft.com> wrote:
> Hi,
> I'd like to set up a job SQL Server agent which will delete backup files
> older than several months once a backup has succeeded. How can I write a
> step to do this?
> Bascially, it will be: if *.BAK > dateadd(m, -2, getdate()) then delete
> (them)
> As you see I have no idea as to where I begin with this. Can it be done?
> Thanks very much for any ideas on this
> Ant
http://realsqlguy.blogspot.com/2007/02/cleaning-up-old-files.html

Wednesday, March 21, 2012

Deleting database backups and logs

New to SQL server. During my 'experimental' phase I created backups plans
to back up databases. Missed the part where the data would be removed after
XX time/days, can I safely delete the old TRN and BAK up file in the backup
folder located in the MSSQL directory directly from Windows Explorer?
The short answer is yes.
Rick Sawtell
MCT, MCSD, MCDBA
<msnews.microsoft.com> wrote in message
news:uZCO4EclEHA.1712@.TK2MSFTNGP09.phx.gbl...
> New to SQL server. During my 'experimental' phase I created backups plans
> to back up databases. Missed the part where the data would be removed
after
> XX time/days, can I safely delete the old TRN and BAK up file in the
backup
> folder located in the MSSQL directory directly from Windows Explorer?
>
|||You can also modify the Maintenance Plan once it has been created. In SQL
Enterprise Manager, open the "Maintenance" node. Select Maintenance Plans,
then double-click the maintenance plan that you created. In here you can
modify the properties for the maintenence plan (including the property to
delete old backups). However the answer to your question is - yes you can
delete the files manually through Explorer. These are backup files and SQL
does not hold a lock on these files once it has completed writing them out.
Thank you for using Microsoft newsgroups.
Sincerely
Pankaj Agarwal
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

Deleting database backups and logs

New to SQL server. During my 'experimental' phase I created backups plans
to back up databases. Missed the part where the data would be removed after
XX time/days, can I safely delete the old TRN and BAK up file in the backup
folder located in the MSSQL directory directly from Windows Explorer?The short answer is yes.
Rick Sawtell
MCT, MCSD, MCDBA
<msnews.microsoft.com> wrote in message
news:uZCO4EclEHA.1712@.TK2MSFTNGP09.phx.gbl...
> New to SQL server. During my 'experimental' phase I created backups plans
> to back up databases. Missed the part where the data would be removed
after
> XX time/days, can I safely delete the old TRN and BAK up file in the
backup
> folder located in the MSSQL directory directly from Windows Explorer?
>|||You can also modify the Maintenance Plan once it has been created. In SQL
Enterprise Manager, open the "Maintenance" node. Select Maintenance Plans,
then double-click the maintenance plan that you created. In here you can
modify the properties for the maintenence plan (including the property to
delete old backups). However the answer to your question is - yes you can
delete the files manually through Explorer. These are backup files and SQL
does not hold a lock on these files once it has completed writing them out.
Thank you for using Microsoft newsgroups.
Sincerely
Pankaj Agarwal
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

deleting backups older than X days?

Hello,
I've written a number of scripts for custom maintenance and backups on our
server, the last problem I have is I don't know how to delete backup files o
lder
than x amount of days. Can anyone tell me how to do this?
Thanks,
Craig.Why don't you use database maintenance plans? They do this (delete old
files) for you...
--
Carlos E. Rojas
SQL Server MVP
Co-Author SQL Server 2000 programming by Example
"Craig H." <spam@.[at]thehurley.[dot]com> wrote in message
news:O7PJ2aTBEHA.2768@.tk2msftngp13.phx.gbl...
> Hello,
> I've written a number of scripts for custom maintenance and backups on our
> server, the last problem I have is I don't know how to delete backup files
older
> than x amount of days. Can anyone tell me how to do this?
> Thanks,
> Craig.|||If you have a look at the delete code in this proc it should give you the
right idea
http://www.sql-server-performance.c...sp?TOPIC_ID=864
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Craig H." <spam@.[at]thehurley.[dot]com> wrote in message
news:O7PJ2aTBEHA.2768@.tk2msftngp13.phx.gbl...
> Hello,
> I've written a number of scripts for custom maintenance and backups on our
> server, the last problem I have is I don't know how to delete backup files
older
> than x amount of days. Can anyone tell me how to do this?
> Thanks,
> Craig.|||Which should cause you to go stright for the Maint. Plan Wizard
Neil MacMurchy
"Jasper Smith" <jasper_smith9@.hotmail.com> wrote in message
news:OwfUuAUBEHA.1236@.TK2MSFTNGP11.phx.gbl...
> If you have a look at the delete code in this proc it should give you the
> right idea
> http://www.sql-server-performance.c...sp?TOPIC_ID=864
> --
> HTH
> Jasper Smith (SQL Server MVP)
> I support PASS - the definitive, global
> community for SQL Server professionals -
> http://www.sqlpass.org
>
> "Craig H." <spam@.[at]thehurley.[dot]com> wrote in message
> news:O7PJ2aTBEHA.2768@.tk2msftngp13.phx.gbl...
our
files
> older
>|||It's not pretty is it, what was I thinking :-)
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Neil MacMurchy" <neilmcse@.hotmail.com> wrote in message
news:%23CzFYMUBEHA.1700@.TK2MSFTNGP12.phx.gbl...
> Which should cause you to go stright for the Maint. Plan Wizard
> Neil MacMurchy
> "Jasper Smith" <jasper_smith9@.hotmail.com> wrote in message
> news:OwfUuAUBEHA.1236@.TK2MSFTNGP11.phx.gbl...
the
> our
> files
>|||Thanks for that link Jasper... but I think I'll stick with the maintenance p
lan
wizard for backups.
Jasper Smith wrote:

> If you have a look at the delete code in this proc it should give you the
> right idea
> http://www.sql-server-performance.c...sp?TOPIC_ID=864
>|||I KNEW IT! I must be an Oracle (ooooo bad pun....)
;-)
Neil
"Craig H." <spam@.[at]thehurley.[dot]com> wrote in message
news:eFrTuvUBEHA.3748@.TK2MSFTNGP11.phx.gbl...
> Thanks for that link Jasper... but I think I'll stick with the maintenance
plan
> wizard for backups.
>
> Jasper Smith wrote:
>
the|||It does look scary but rest assured we have been running this in production
for a long time and its got tens of thousands of backups under its belt. It
is getting to be a bit of a monster procedure though :-)
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Craig H." <spam@.[at]thehurley.[dot]com> wrote in message
news:eFrTuvUBEHA.3748@.TK2MSFTNGP11.phx.gbl...
> Thanks for that link Jasper... but I think I'll stick with the maintenance
plan
> wizard for backups.
>
> Jasper Smith wrote:
>
the

Monday, March 19, 2012

deleting a sql backup file

My backups job are failing at the delete old backup step
because of not being to delete a backup file. When I try
to manually delete this file I get the sharing violation
error message - that someone or something process may be
using the file. I know for a fact that it is not someone
and I need to delete this file. I take ownership of the
file with full control permissions but still can't delete
this file. I hate to bounce a server just to be able to
delete a file. Does anyone know what I can do to delete
this file? Is there a way to have sql server or agent
take control of the files I want the jobs to delete? I
appreciate your help. Thanks
LisaLisa,
This happened to me once a while ago and it was because sql server was still
verifying the backup file. When you use database maintenance plans, one of
the options is to verify the file after the backup is taken. If this is not
the case you're going to have to find a windows utility to find which
windows process has the file locked, i think i found one of these utilities
at www.sysinternals.com a while ago, but i'm not sure.
--
Carlos E. Rojas
SQL Server MVP
Co-Author SQL Server 2000 Programming by Example
"Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
news:45b601c3e428$8930b000$a001280a@.phx.gbl...
> My backups job are failing at the delete old backup step
> because of not being to delete a backup file. When I try
> to manually delete this file I get the sharing violation
> error message - that someone or something process may be
> using the file. I know for a fact that it is not someone
> and I need to delete this file. I take ownership of the
> file with full control permissions but still can't delete
> this file. I hate to bounce a server just to be able to
> delete a file. Does anyone know what I can do to delete
> this file? Is there a way to have sql server or agent
> take control of the files I want the jobs to delete? I
> appreciate your help. Thanks
> Lisa|||Thank you so much Carlos. The "verify integrity of backup
upon completion" was checked. If this is locking the
files and uncheck that box, isn't that a bad thing? What
is the impact on the integrity of my backups. I will
check the winternals website also. Thanks.
Lisa.
>--Original Message--
>Lisa,
>This happened to me once a while ago and it was because
sql server was still
>verifying the backup file. When you use database
maintenance plans, one of
>the options is to verify the file after the backup is
taken. If this is not
>the case you're going to have to find a windows utility
to find which
>windows process has the file locked, i think i found one
of these utilities
>at www.sysinternals.com a while ago, but i'm not sure.
>--
>Carlos E. Rojas
>SQL Server MVP
>Co-Author SQL Server 2000 Programming by Example
>
>"Lisa Trueman" <anonymous@.discussions.microsoft.com>
wrote in message
>news:45b601c3e428$8930b000$a001280a@.phx.gbl...
>> My backups job are failing at the delete old backup step
>> because of not being to delete a backup file. When I
try
>> to manually delete this file I get the sharing violation
>> error message - that someone or something process may be
>> using the file. I know for a fact that it is not
someone
>> and I need to delete this file. I take ownership of the
>> file with full control permissions but still can't
delete
>> this file. I hate to bounce a server just to be able to
>> delete a file. Does anyone know what I can do to delete
>> this file? Is there a way to have sql server or agent
>> take control of the files I want the jobs to delete? I
>> appreciate your help. Thanks
>> Lisa
>
>.
>|||That option is IMO not that useful. To check out what it does, read about
the VERIFYONLY option to the RESTORE in Books Online.
--
Tibor Karaszi, SQL Server MVP
Archive at:
http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
> Thank you so much Carlos. The "verify integrity of backup
> upon completion" was checked. If this is locking the
> files and uncheck that box, isn't that a bad thing? What
> is the impact on the integrity of my backups. I will
> check the winternals website also. Thanks.
> Lisa.
>
> >--Original Message--
> >Lisa,
> >This happened to me once a while ago and it was because
> sql server was still
> >verifying the backup file. When you use database
> maintenance plans, one of
> >the options is to verify the file after the backup is
> taken. If this is not
> >the case you're going to have to find a windows utility
> to find which
> >windows process has the file locked, i think i found one
> of these utilities
> >at www.sysinternals.com a while ago, but i'm not sure.
> >
> >--
> >Carlos E. Rojas
> >SQL Server MVP
> >Co-Author SQL Server 2000 Programming by Example
> >
> >
> >"Lisa Trueman" <anonymous@.discussions.microsoft.com>
> wrote in message
> >news:45b601c3e428$8930b000$a001280a@.phx.gbl...
> >> My backups job are failing at the delete old backup step
> >> because of not being to delete a backup file. When I
> try
> >> to manually delete this file I get the sharing violation
> >> error message - that someone or something process may be
> >> using the file. I know for a fact that it is not
> someone
> >> and I need to delete this file. I take ownership of the
> >> file with full control permissions but still can't
> delete
> >> this file. I hate to bounce a server just to be able to
> >> delete a file. Does anyone know what I can do to delete
> >> this file? Is there a way to have sql server or agent
> >> take control of the files I want the jobs to delete? I
> >> appreciate your help. Thanks
> >>
> >> Lisa
> >
> >
> >.
> >|||agree completely...
--
Carlos E. Rojas
SQL Server MVP
Co-Author SQL Server 2000 Programming by Example
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:eX6x4AD5DHA.1596@.TK2MSFTNGP10.phx.gbl...
> That option is IMO not that useful. To check out what it does, read about
> the VERIFYONLY option to the RESTORE in Books Online.
> --
> Tibor Karaszi, SQL Server MVP
> Archive at:
>
http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
>
> "Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
> news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
> > Thank you so much Carlos. The "verify integrity of backup
> > upon completion" was checked. If this is locking the
> > files and uncheck that box, isn't that a bad thing? What
> > is the impact on the integrity of my backups. I will
> > check the winternals website also. Thanks.
> >
> > Lisa.
> >
> >
> > >--Original Message--
> > >Lisa,
> > >This happened to me once a while ago and it was because
> > sql server was still
> > >verifying the backup file. When you use database
> > maintenance plans, one of
> > >the options is to verify the file after the backup is
> > taken. If this is not
> > >the case you're going to have to find a windows utility
> > to find which
> > >windows process has the file locked, i think i found one
> > of these utilities
> > >at www.sysinternals.com a while ago, but i'm not sure.
> > >
> > >--
> > >Carlos E. Rojas
> > >SQL Server MVP
> > >Co-Author SQL Server 2000 Programming by Example
> > >
> > >
> > >"Lisa Trueman" <anonymous@.discussions.microsoft.com>
> > wrote in message
> > >news:45b601c3e428$8930b000$a001280a@.phx.gbl...
> > >> My backups job are failing at the delete old backup step
> > >> because of not being to delete a backup file. When I
> > try
> > >> to manually delete this file I get the sharing violation
> > >> error message - that someone or something process may be
> > >> using the file. I know for a fact that it is not
> > someone
> > >> and I need to delete this file. I take ownership of the
> > >> file with full control permissions but still can't
> > delete
> > >> this file. I hate to bounce a server just to be able to
> > >> delete a file. Does anyone know what I can do to delete
> > >> this file? Is there a way to have sql server or agent
> > >> take control of the files I want the jobs to delete? I
> > >> appreciate your help. Thanks
> > >>
> > >> Lisa
> > >
> > >
> > >.
> > >
>|||Thank you very much.
>--Original Message--
>agree completely...
>--
>Carlos E. Rojas
>SQL Server MVP
>Co-Author SQL Server 2000 Programming by Example
>
>"Tibor Karaszi"
<tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
>message news:eX6x4AD5DHA.1596@.TK2MSFTNGP10.phx.gbl...
>> That option is IMO not that useful. To check out what
it does, read about
>> the VERIFYONLY option to the RESTORE in Books Online.
>> --
>> Tibor Karaszi, SQL Server MVP
>> Archive at:
>http://groups.google.com/groups?
oi=djq&as_ugroup=microsoft.public.sqlserver
>>
>> "Lisa Trueman" <anonymous@.discussions.microsoft.com>
wrote in message
>> news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
>> > Thank you so much Carlos. The "verify integrity of
backup
>> > upon completion" was checked. If this is locking the
>> > files and uncheck that box, isn't that a bad thing?
What
>> > is the impact on the integrity of my backups. I will
>> > check the winternals website also. Thanks.
>> >
>> > Lisa.
>> >
>> >
>> > >--Original Message--
>> > >Lisa,
>> > >This happened to me once a while ago and it was
because
>> > sql server was still
>> > >verifying the backup file. When you use database
>> > maintenance plans, one of
>> > >the options is to verify the file after the backup is
>> > taken. If this is not
>> > >the case you're going to have to find a windows
utility
>> > to find which
>> > >windows process has the file locked, i think i found
one
>> > of these utilities
>> > >at www.sysinternals.com a while ago, but i'm not
sure.
>> > >
>> > >--
>> > >Carlos E. Rojas
>> > >SQL Server MVP
>> > >Co-Author SQL Server 2000 Programming by Example
>> > >
>> > >
>> > >"Lisa Trueman" <anonymous@.discussions.microsoft.com>
>> > wrote in message
>> > >news:45b601c3e428$8930b000$a001280a@.phx.gbl...
>> > >> My backups job are failing at the delete old
backup step
>> > >> because of not being to delete a backup file.
When I
>> > try
>> > >> to manually delete this file I get the sharing
violation
>> > >> error message - that someone or something process
may be
>> > >> using the file. I know for a fact that it is not
>> > someone
>> > >> and I need to delete this file. I take ownership
of the
>> > >> file with full control permissions but still can't
>> > delete
>> > >> this file. I hate to bounce a server just to be
able to
>> > >> delete a file. Does anyone know what I can do to
delete
>> > >> this file? Is there a way to have sql server or
agent
>> > >> take control of the files I want the jobs to
delete? I
>> > >> appreciate your help. Thanks
>> > >>
>> > >> Lisa
>> > >
>> > >
>> > >.
>> > >
>>
>
>.
>Lis|||Thanks Tibor
>--Original Message--
>That option is IMO not that useful. To check out what it
does, read about
>the VERIFYONLY option to the RESTORE in Books Online.
>--
>Tibor Karaszi, SQL Server MVP
>Archive at:
>http://groups.google.com/groups?
oi=djq&as_ugroup=microsoft.public.sqlserver
>
>"Lisa Trueman" <anonymous@.discussions.microsoft.com>
wrote in message
>news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
>> Thank you so much Carlos. The "verify integrity of
backup
>> upon completion" was checked. If this is locking the
>> files and uncheck that box, isn't that a bad thing?
What
>> is the impact on the integrity of my backups. I will
>> check the winternals website also. Thanks.
>> Lisa.
>>
>> >--Original Message--
>> >Lisa,
>> >This happened to me once a while ago and it was because
>> sql server was still
>> >verifying the backup file. When you use database
>> maintenance plans, one of
>> >the options is to verify the file after the backup is
>> taken. If this is not
>> >the case you're going to have to find a windows utility
>> to find which
>> >windows process has the file locked, i think i found
one
>> of these utilities
>> >at www.sysinternals.com a while ago, but i'm not sure.
>> >
>> >--
>> >Carlos E. Rojas
>> >SQL Server MVP
>> >Co-Author SQL Server 2000 Programming by Example
>> >
>> >
>> >"Lisa Trueman" <anonymous@.discussions.microsoft.com>
>> wrote in message
>> >news:45b601c3e428$8930b000$a001280a@.phx.gbl...
>> >> My backups job are failing at the delete old backup
step
>> >> because of not being to delete a backup file. When I
>> try
>> >> to manually delete this file I get the sharing
violation
>> >> error message - that someone or something process
may be
>> >> using the file. I know for a fact that it is not
>> someone
>> >> and I need to delete this file. I take ownership of
the
>> >> file with full control permissions but still can't
>> delete
>> >> this file. I hate to bounce a server just to be
able to
>> >> delete a file. Does anyone know what I can do to
delete
>> >> this file? Is there a way to have sql server or
agent
>> >> take control of the files I want the jobs to
delete? I
>> >> appreciate your help. Thanks
>> >>
>> >> Lisa
>> >
>> >
>> >.
>> >
>
>.
>

deleting a sql backup file

My backups job are failing at the delete old backup step
because of not being to delete a backup file. When I try
to manually delete this file I get the sharing violation
error message - that someone or something process may be
using the file. I know for a fact that it is not someone
and I need to delete this file. I take ownership of the
file with full control permissions but still can't delete
this file. I hate to bounce a server just to be able to
delete a file. Does anyone know what I can do to delete
this file? Is there a way to have sql server or agent
take control of the files I want the jobs to delete? I
appreciate your help. Thanks
LisaLisa,
This happened to me once a while ago and it was because sql server was still
verifying the backup file. When you use database maintenance plans, one of
the options is to verify the file after the backup is taken. If this is not
the case you're going to have to find a windows utility to find which
windows process has the file locked, i think i found one of these utilities
at www.sysinternals.com a while ago, but i'm not sure.
Carlos E. Rojas
SQL Server MVP
Co-Author SQL Server 2000 programming by Example
"Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
news:45b601c3e428$8930b000$a001280a@.phx.gbl...
quote:

> My backups job are failing at the delete old backup step
> because of not being to delete a backup file. When I try
> to manually delete this file I get the sharing violation
> error message - that someone or something process may be
> using the file. I know for a fact that it is not someone
> and I need to delete this file. I take ownership of the
> file with full control permissions but still can't delete
> this file. I hate to bounce a server just to be able to
> delete a file. Does anyone know what I can do to delete
> this file? Is there a way to have sql server or agent
> take control of the files I want the jobs to delete? I
> appreciate your help. Thanks
> Lisa
|||Thank you so much Carlos. The "verify integrity of backup
upon completion" was checked. If this is locking the
files and uncheck that box, isn't that a bad thing? What
is the impact on the integrity of my backups. I will
check the winternals website also. Thanks.
Lisa.
quote:

>--Original Message--
>Lisa,
>This happened to me once a while ago and it was because

sql server was still
quote:

>verifying the backup file. When you use database

maintenance plans, one of
quote:

>the options is to verify the file after the backup is

taken. If this is not
quote:

>the case you're going to have to find a windows utility

to find which
quote:

>windows process has the file locked, i think i found one

of these utilities
quote:

>at www.sysinternals.com a while ago, but i'm not sure.
>--
>Carlos E. Rojas
>SQL Server MVP
>Co-Author SQL Server 2000 programming by Example
>
>"Lisa Trueman" <anonymous@.discussions.microsoft.com>

wrote in message
quote:

>news:45b601c3e428$8930b000$a001280a@.phx.gbl...
try[QUOTE]
someone[QUOTE]
delete[QUOTE]
>
>.
>
|||That option is IMO not that useful. To check out what it does, read about
the VERIFYONLY option to the RESTORE in Books Online.
Tibor Karaszi, SQL Server MVP
Archive at:
http://groups.google.com/groups?oi=...ublic.sqlserver
"Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
news:492101c3e42b$e9226d20$a501280a@.phx.gbl...[QUOTE]
> Thank you so much Carlos. The "verify integrity of backup
> upon completion" was checked. If this is locking the
> files and uncheck that box, isn't that a bad thing? What
> is the impact on the integrity of my backups. I will
> check the winternals website also. Thanks.
> Lisa.
>
> sql server was still
> maintenance plans, one of
> taken. If this is not
> to find which
> of these utilities
> wrote in message
> try
> someone
> delete|||agree completely...
--
Carlos E. Rojas
SQL Server MVP
Co-Author SQL Server 2000 programming by Example
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:eX6x4AD5DHA.1596@.TK2MSFTNGP10.phx.gbl...
quote:

> That option is IMO not that useful. To check out what it does, read about
> the VERIFYONLY option to the RESTORE in Books Online.
> --
> Tibor Karaszi, SQL Server MVP
> Archive at:
>

http://groups.google.com/groups?oi=...ublic.sqlserver
quote:

>
> "Lisa Trueman" <anonymous@.discussions.microsoft.com> wrote in message
> news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
>
|||Thank you very much.
quote:

>--Original Message--
>agree completely...
>--
>Carlos E. Rojas
>SQL Server MVP
>Co-Author SQL Server 2000 programming by Example
>
>"Tibor Karaszi"

<tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
quote:

>message news:eX6x4AD5DHA.1596@.TK2MSFTNGP10.phx.gbl...
it does, read about[QUOTE]
>http://groups.google.com/groups?

oi=djq&as_ugroup=microsoft.public.sqlserver
quote:

wrote in message[QUOTE]
backup[QUOTE]
What[QUOTE]
because[QUOTE]
utility[QUOTE]
one[QUOTE]
sure.[QUOTE]
backup step[QUOTE]
When I[QUOTE]
violation[QUOTE]
may be[QUOTE]
of the[QUOTE]
able to[QUOTE]
delete[QUOTE]
agent[QUOTE]
delete? I[QUOTE]
>
>.
>Lis
|||Thanks Tibor
quote:

>--Original Message--
>That option is IMO not that useful. To check out what it

does, read about
quote:

>the VERIFYONLY option to the RESTORE in Books Online.
>--
>Tibor Karaszi, SQL Server MVP
>Archive at:
>http://groups.google.com/groups?

oi=djq&as_ugroup=microsoft.public.sqlserver
quote:

>
>"Lisa Trueman" <anonymous@.discussions.microsoft.com>

wrote in message
quote:

>news:492101c3e42b$e9226d20$a501280a@.phx.gbl...
backup[QUOTE]
What[QUOTE]
one[QUOTE]
step[QUOTE]
violation[QUOTE]
may be[QUOTE]
the[QUOTE]
able to[QUOTE]
delete[QUOTE]
agent[QUOTE]
delete? I[QUOTE]
>
>.
>

Wednesday, March 7, 2012

Deleted "old" transaction logs = (no items) in EM. How to recover?

A mistake was made and "old" transaction logs (and old backups) were
deleted. It appears that a long living transaction was living in one of
those logs. Now the EP shows (no items). The DBs themselves are still
functioning OK, just the EP shell that's not working.

What's the proper resolution?

Thank you in advance,

FBCK(optimistck@.gmail.com) writes:
> A mistake was made and "old" transaction logs (and old backups) were
> deleted. It appears that a long living transaction was living in one of
> those logs. Now the EP shows (no items). The DBs themselves are still
> functioning OK, just the EP shell that's not working.
> What's the proper resolution?

EP?

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

Friday, February 17, 2012

Delete previous backup in append mode sql 2000

i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to ove
rwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothi
ng.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>

Delete previous backup in append mode sql 2000

i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedure
writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data

Delete previous backup in append mode sql 2000

i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to overwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothing.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>|||writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data|||Using Append you will never be able to keep exactly three (or two, or
six) copies of your backup. Rather than using append modeUse a
different file name each day, perhaps with the date as part of the
file name.
Roy
On 10 Dec 2006 21:15:08 -0800, "Arejan" <areejan2000@.yahoo.com> wrote:
>writing the backup daily to hdd
>whats the better option so that the file size is maintained ,can only
>use append mode
>as i might want to restore to 2/ 3 days previous data