Solved

Urgent! Help! How to dump the transaction log?

Posted on 2003-10-22
5
34,170 Views
Last Modified: 2012-06-27
God!   I allocate not enough space for temp database, now it is full, I do not know the exact use of system procedure and so on, but I need to solve the problem soon. I need to know how to dump transaction log. Can you write the statement for me?   THANK YOU!
0
Comment
Question by:happyeveryday
5 Comments
 
LVL 5

Assisted Solution

by:amitpagarwal
amitpagarwal earned 20 total points
ID: 9604962
dump transaction DATABASE_NAME with no_log
0
 
LVL 15

Assisted Solution

by:namasi_navaretnam
namasi_navaretnam earned 20 total points
ID: 9609531
0
 
LVL 2

Accepted Solution

by:
mansoor_a_khan earned 20 total points
ID: 9625233
NO_LOG is not a good option to use, it may corrupt ur database.
I would suggest.

dump transaction DATABASE_NAME with truncate_only
checkpoint

Cheers,
MAK

0
 

Expert Comment

by:rooksmith
ID: 11015417
I second that !  Dump transaction with no_log is the same as a dump transaction with truncate_only, with the exception that "no log record is written to the log" - In other words - it truncates the inactive portion of your log and does not write the log records to a file. In short it will invalidate your subsequent dump transaction commands.

So if the author of the message simply wants to back up the log, he should be doing something like this:

Time 1: dump database dbname to "dbdumpfilename"
Time 2: dump transaction dbname to "transfile1"
Time3: dump transaction dbname to "transfile2"

etc...

Recovery is the same list with the word load instead of dump..

Good luck and RTFM!   ;-)
0
 

Expert Comment

by:rooksmith
ID: 11015528
Whoops - my appologies. I should always read the entire question before posting and answer!

Your question was about Tempdb which is a different breed of cat.With Tempdb the thing to realize is that it gets created (ie, the model database is literally copied to the tempdb) from scratch each time you restart the server. So go ahead and use the "dump tran with truncate_only" command to clear out the log. If that doesnt work use "dump tran with no_log". IF all else fails reboot... In fact if you have the time reboot first.

Another option is to alter the tempdb and add more space. This is often the only solution if this keeps happening over and over again. I would caution against altering it on the master device. Master gets a lot of I/O and so does the tempdb. I would create a new device fragment on a "fast disk" somehwere (note- you might be using RAID - go for Raid level 0, or "striped only", higher throughput and no redundancy for the tempdb)....

0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Sybase sample database 13 663
SyBase SQL Query 7 143
SQL Query Syntax 12 63
Converting some Sql server syntax to Sybase Syntax. 8 21
Never store passwords in plain text or just their hash: it seems a no-brainier, but there are still plenty of people doing that. I present the why and how on this subject, offering my own real life solution that you can implement right away, bringin…
Scam emails are a huge burden for many businesses. Spotting one is not always easy. Follow our tips to identify if an email you receive is a scam.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

705 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

20 Experts available now in Live!

Get 1:1 Help Now