Showing posts with label article. Show all posts
Showing posts with label article. Show all posts

Sunday, February 19, 2012

Backup log With Truncate Only (Log Shipping)

SQL Server 2000 Standard Edition running on Win2k
I've setup log shipping according to an article I found here.
http://www.sql-server-performance.c...og_shipping.asp
Which truncates the log before doing the database backup then does the backu
p
and
subsequent log backups without truncating. Of course the truncate causes an
error
to be shown in the event viewer.
Since books describes the default behavior of log backups to be an automatic
truncate
after backup my initial thought is to drop the log backup before the db back
up
and just let
the truncate happen automatically with the normal log shipping backups.
Remove This -- BACKUP LOG database_name WITH TRUNCATE_ONLY
Remove This -- WAITFOR DELAY '00:00:05'
BACKUP DATABASE database_name TO database_name_backup_device WITH INIT
Remove the NO_TRUNCATE and let the log truncate automatically.
BACKUP LOG database_name TO log_backup_device WITH INIT, NO_TRUNCATE
They do mention in the article that you don't want to truncate the log after
you do
your normal log shipping backups because you might need them later. Would yo
u
possibly
need them later? I archive all my log and db backups each time they run.Brad <seveni7@.yahoo.com> wrote:
quote:

>SQL Server 2000 Standard Edition running on Win2k
>I've setup log shipping according to an article I found here.
>http://www.sql-server-performance.c...og_shipping.asp
>Which truncates the log before doing the database backup then does the back
up
>and
>subsequent log backups without truncating. Of course the truncate causes an
>error
>to be shown in the event viewer.
>Since books describes the default behavior of log backups to be an automati
c
>truncate
>after backup my initial thought is to drop the log backup before the db bac
kup
>and just let
>the truncate happen automatically with the normal log shipping backups.
>

My bad!
Found it on MS Knowledge Base Article - 818202
Just a warning.

Backup log With Truncate Only (Log Shipping)

SQL Server 2000 Standard Edition running on Win2k
I've setup log shipping according to an article I found here.
http://www.sql-server-performance.com/sql_server_log_shipping.asp
Which truncates the log before doing the database backup then does the backup
and
subsequent log backups without truncating. Of course the truncate causes an
error
to be shown in the event viewer.
Since books describes the default behavior of log backups to be an automatic
truncate
after backup my initial thought is to drop the log backup before the db backup
and just let
the truncate happen automatically with the normal log shipping backups.
Remove This -- BACKUP LOG database_name WITH TRUNCATE_ONLY
Remove This -- WAITFOR DELAY '00:00:05'
BACKUP DATABASE database_name TO database_name_backup_device WITH INIT
Remove the NO_TRUNCATE and let the log truncate automatically.
BACKUP LOG database_name TO log_backup_device WITH INIT, NO_TRUNCATE
They do mention in the article that you don't want to truncate the log after
you do
your normal log shipping backups because you might need them later. Would you
possibly
need them later? I archive all my log and db backups each time they run.Brad <seveni7@.yahoo.com> wrote:
>SQL Server 2000 Standard Edition running on Win2k
>I've setup log shipping according to an article I found here.
>http://www.sql-server-performance.com/sql_server_log_shipping.asp
>Which truncates the log before doing the database backup then does the backup
>and
>subsequent log backups without truncating. Of course the truncate causes an
>error
>to be shown in the event viewer.
>Since books describes the default behavior of log backups to be an automatic
>truncate
>after backup my initial thought is to drop the log backup before the db backup
>and just let
>the truncate happen automatically with the normal log shipping backups.
>
My bad!
Found it on MS Knowledge Base Article - 818202
Just a warning.

Thursday, February 16, 2012

Backup Llast log - Primary crashed

HAs any one backed up the log when data files are damaged? I am
following KB article Q253817. It is not working. When I run the backup
command , it gives mdf not exists in sql server 2000. Any one has
success?If you show us the BACKUP LOG command and the exact error message (including
error number etc) we can
hopefully comment. Easiest s to execute these commands from Query Analyzer a
nd not try to drive the UI in EM.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
"tram" <tram_e@.hotmail.com> wrote in message news:26ee1067.0404010502.2f64ff17@.posting.goog
le.com...
> HAs any one backed up the log when data files are damaged? I am
> following KB article Q253817. It is not working. When I run the backup
> command , it gives mdf not exists in sql server 2000. Any one has
> success?|||Thanks for your reply. The first scenario was master was intcact, lost
the datafile of DB. Then the backup log with no_truncate worked
fine.(though it giving errors with MSDE version).
The second scenario, master was intact. The datafile of DB lost. I've
created another db and dropped both daat and log of newly created db.
Copy the crashed DB log to new DB as per KB article except using the
same master. When sql server starts up, that is making the new DB
offline. When run the backup log with no_truncate, it gives error.
Could not open FCB for invalid file ID 0 in database 'test1'
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in message news:<#
#mDbq#FEHA.3540@.TK2MSFTNGP09.phx.gbl>...
> If you show us the BACKUP LOG command and the exact error message (includi
ng error number etc) we can
> hopefully comment. Easiest s to execute these commands from Query Analyzer
and not try to drive the UI in EM.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
>
> "tram" <tram_e@.hotmail.com> wrote in message news:26ee1067.0404010502.2f64
ff17@.posting.google.com...

Backup Llast log - Primary crashed

HAs any one backed up the log when data files are damaged? I am
following KB article Q253817. It is not working. When I run the backup
command , it gives mdf not exists in sql server 2000. Any one has
success?
If you show us the BACKUP LOG command and the exact error message (including error number etc) we can
hopefully comment. Easiest s to execute these commands from Query Analyzer and not try to drive the UI in EM.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
"tram" <tram_e@.hotmail.com> wrote in message news:26ee1067.0404010502.2f64ff17@.posting.google.c om...
> HAs any one backed up the log when data files are damaged? I am
> following KB article Q253817. It is not working. When I run the backup
> command , it gives mdf not exists in sql server 2000. Any one has
> success?
|||Thanks for your reply. The first scenario was master was intcact, lost
the datafile of DB. Then the backup log with no_truncate worked
fine.(though it giving errors with MSDE version).
The second scenario, master was intact. The datafile of DB lost. I've
created another db and dropped both daat and log of newly created db.
Copy the crashed DB log to new DB as per KB article except using the
same master. When sql server starts up, that is making the new DB
offline. When run the backup log with no_truncate, it gives error.
Could not open FCB for invalid file ID 0 in database 'test1'
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in message news:<##mDbq#FEHA.3540@.TK2MSFTNGP09.phx.gbl>...
> If you show us the BACKUP LOG command and the exact error message (including error number etc) we can
> hopefully comment. Easiest s to execute these commands from Query Analyzer and not try to drive the UI in EM.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
>
> "tram" <tram_e@.hotmail.com> wrote in message news:26ee1067.0404010502.2f64ff17@.posting.google.c om...