Unix Technical Forum

Scheduling a script

This is a discussion on Scheduling a script within the SQL Server forums, part of the Microsoft SQL Server category; --> I wish to run this script daily. Can this be scheduled? backup log shipmateDB with truncate_only G...


Go Back   Unix Technical Forum > Database Server Software > Microsoft SQL Server > SQL Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-29-2008, 08:33 AM
Myth of Sisyphus\).
 
Posts: n/a
Default Scheduling a script

I wish to run this script daily. Can this be scheduled?


backup log shipmateDB with truncate_only


G


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-29-2008, 08:33 AM
Mike Epprecht \(SQL MVP\)
 
Posts: n/a
Default Re: Scheduling a script

Hi

Look at SQL Server Agent in BOL. It can schedule jobs and run code.

Regards
--------------------------------
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland

IM: mike@epprecht.net

MVP Program: http://www.microsoft.com/mvp

Blog: http://www.msmvps.com/epprecht/

"Myth of Sisyphus)." <teller_117@hotmail.com> wrote in message
news:iqRFe.4700$q23.748061@news20.bellglobal.com.. .
>I wish to run this script daily. Can this be scheduled?
>
>
> backup log shipmateDB with truncate_only
>
>
> G
>
>



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-29-2008, 08:34 AM
Greg D. Moore \(Strider\)
 
Posts: n/a
Default Re: Scheduling a script


"Mike Epprecht (SQL MVP)" <mike@epprecht.net> wrote in message
news:42e7ed30$1_1@news.bluewin.ch...
> Hi
>
> Look at SQL Server Agent in BOL. It can schedule jobs and run code.
>


Can I add though that this script is probably not a good idea.

Either run the database in simple mode or perform actual log backups.


> Regards
> --------------------------------
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
>
> IM: mike@epprecht.net
>
> MVP Program: http://www.microsoft.com/mvp
>
> Blog: http://www.msmvps.com/epprecht/
>
> "Myth of Sisyphus)." <teller_117@hotmail.com> wrote in message
> news:iqRFe.4700$q23.748061@news20.bellglobal.com.. .
> >I wish to run this script daily. Can this be scheduled?
> >
> >
> > backup log shipmateDB with truncate_only
> >
> >
> > G
> >
> >

>
>



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-29-2008, 08:34 AM
Myth of Sisyphus\).
 
Posts: n/a
Default Re: Scheduling a script

Hi Greg,

I do have a log file backup scheduled along with my regular backup.
However, I do get sporatic log file full messages. I then have to run the
script through the query analyzer that appears to solve the problem untill
the next time.

regards

gilbert


"Greg D. Moore (Strider)" <mooregr_deleteth1s@greenms.com> wrote in message
news:J5VFe.10184$oZ.2845@newsread2.news.atl.earthl ink.net...
>
> "Mike Epprecht (SQL MVP)" <mike@epprecht.net> wrote in message
> news:42e7ed30$1_1@news.bluewin.ch...
> > Hi
> >
> > Look at SQL Server Agent in BOL. It can schedule jobs and run code.
> >

>
> Can I add though that this script is probably not a good idea.
>
> Either run the database in simple mode or perform actual log backups.
>
>
> > Regards
> > --------------------------------
> > Mike Epprecht, Microsoft SQL Server MVP
> > Zurich, Switzerland
> >
> > IM: mike@epprecht.net
> >
> > MVP Program: http://www.microsoft.com/mvp
> >
> > Blog: http://www.msmvps.com/epprecht/
> >
> > "Myth of Sisyphus)." <teller_117@hotmail.com> wrote in message
> > news:iqRFe.4700$q23.748061@news20.bellglobal.com.. .
> > >I wish to run this script daily. Can this be scheduled?
> > >
> > >
> > > backup log shipmateDB with truncate_only
> > >
> > >
> > > G
> > >
> > >

> >
> >

>
>



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-29-2008, 08:34 AM
Greg D. Moore \(Strider\)
 
Posts: n/a
Default Re: Scheduling a script


"Myth of Sisyphus)." <teller_117@hotmail.com> wrote in message
news:5y4Ge.5644$q23.914966@news20.bellglobal.com.. .
> Hi Greg,
>
> I do have a log file backup scheduled along with my regular backup.
> However, I do get sporatic log file full messages. I then have to run the
> script through the query analyzer that appears to solve the problem

untill
> the next time.


But then you've completely invalidated your log backup chain.

I think you need to revisit your disaster recovery scenario since once
you've done the truncate, you can no longer recover anything past the last
transaction back up or full backup.

You're either better of doing transaction log backups more often to avoid
filling up your log, making your log larger, or finding out what's filling
them up.


>
> regards
>
> gilbert
>
>
> "Greg D. Moore (Strider)" <mooregr_deleteth1s@greenms.com> wrote in

message
> news:J5VFe.10184$oZ.2845@newsread2.news.atl.earthl ink.net...
> >
> > "Mike Epprecht (SQL MVP)" <mike@epprecht.net> wrote in message
> > news:42e7ed30$1_1@news.bluewin.ch...
> > > Hi
> > >
> > > Look at SQL Server Agent in BOL. It can schedule jobs and run code.
> > >

> >
> > Can I add though that this script is probably not a good idea.
> >
> > Either run the database in simple mode or perform actual log backups.
> >
> >
> > > Regards
> > > --------------------------------
> > > Mike Epprecht, Microsoft SQL Server MVP
> > > Zurich, Switzerland
> > >
> > > IM: mike@epprecht.net
> > >
> > > MVP Program: http://www.microsoft.com/mvp
> > >
> > > Blog: http://www.msmvps.com/epprecht/
> > >
> > > "Myth of Sisyphus)." <teller_117@hotmail.com> wrote in message
> > > news:iqRFe.4700$q23.748061@news20.bellglobal.com.. .
> > > >I wish to run this script daily. Can this be scheduled?
> > > >
> > > >
> > > > backup log shipmateDB with truncate_only
> > > >
> > > >
> > > > G
> > > >
> > > >
> > >
> > >

> >
> >

>
>



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 11:08 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com