How To Alter The Transaction Logfile Size In MSDE 2000?
Dec 1, 2004
Hi there,
I recently saw that the transaction log files of user dbs grow undefinitely in SQL Server 2000 - one of our customers had a 11 GB log file which totally slowed down the server.
Another customer of ours uses one of my applications logging all actions in a MSDE database file and I fear that the corresponding transaction log file will grow and block the system too - is there any way that I could shrink and set the max size of the transaction log file through SQL?
I already know the command "SHRINK FILE ('filename')" but I haven't found a SQL command to set the max size.
It is assumed the max database size for MSDE 2000 is 2GB. But actually I am able to save more than 2 GB to an MSDE database, now its size is more than 5GB. I am confused. What is the actual size limit for MSDE?
I want to write a sql query (for SQL7 & 2K) that gives the size and space used of the log file for a given database. I can do it for data files using sysfiles/sysindexes, but can see how I can do it for the logfile.
I know I can use DMO or dbcc sqlperf(logspace), but I want to understand how and where the information is kept in system tables.
The size of my transaction log file is out of control. I've backed up the database and the transaction log went from 120 GB to 120 MB. Now, I can't reduce the size of the transaction log file. It's still at 120 GB (w/ almost all of that being held as Free Space). I get errors when I try to manually reduce the file size. Any tips?
Has anybody encountered a physical size limit for a sql server 2000 transaction log running on win2k?
Transaction log reached ~6Gb before rolling back the delete stating transaction log was full. There was 42Gb free on the server and the log was set to unlimited growth.
Is there a possibility to change the default instalation directory forthe logfiles for sql server 2000? I would like the default databasefiles to be placed on teh d: drive and the logfiles on the e: drive?Sjaak van Esdonk
We have 300+ databases on one sinlge server. If I need to change log size to "unlimited" for all of them, is there any way to do so? Please advice. -Julie
I have the next question, and i would like to hear what do you thinkabout, and if is there a better solution for "my problem"here is the question, I have a huge table with 60GB of data (imagefiles). The problem happen always when i try to ALTER the structure ofthe table. For example I change a field char(3) to char(4)...thesqlserver then performs the "alter table" command...that must besomething similar than "insert into the new table + drop the actualtable" and for that I need about 60GB o space for my LOG file, andtakes hours to complete the operation.Is this the only way to alter a single field in my table??I would like to heard you opinions...Thanks..ALberto
I have one db test with one .mdf and .ldf file...mdf file size is 100mb and for some reson i removed all the tablesfrom that .mdf file and transfer it into new secondary file so all thetables moved into secondary file now i want to reduce the first .mdffile from 100 mb to 50mb is that possible,it's showing 90mb is free.Please reply
Im working on Partition purge process, where I need to specify following statement:
SET @cmd = 'ALTER PARTITION FUNCTION ' + @function_name + '() MERGE RANGE (@range)' EXEC (@cmd); SET @cmd1 = 'ALTER DATABASE '+ db_name()+ ' REMOVE FILE ' + @partition_file EXEC (cmd1);
I want to put this statement in Begin Tran /Commit statement but getting error that it is not allowed. "ALTER DATABASE statement not allowed within multi-statement transaction"..what are my options to rollback in case there is a failure.
I have MSDE installed on my computer and I'm using Web Data Administrator to manage my databses. The problem is that whenever I add a column with a length of more than 8000, I get the following error:
Length must be between 0 and 8000
If I create the column programmatically then i get this error:
The following error occured while executing the query: Server: Msg 131, Level 15, State 2, Line 2 The size (8005) given to the column 'Article' exceeds the maximum allowed for any data type (8000).
I need several columns that can hold around 32,000 characters. What's the deal? Is this a limit with MSDE, or am I missing something?
Am very new to MS SQL adminstration Can anybody help me out how to work on Microsoft SQL Server 2000 Desktop Engine (MSDE 2000) Release A just for the practice.
The activity which am going to workout on MSDE is below.
How to install SQL(on XP) How the layout will be(like if i insall MSDE what are all Application will be and how they depends on each other) How to create/delete tables if so, how can we do it either by GUI or CUI
Hello! We have unusual situation. We increased the size of transaction log up to 100MB. After we run the transaction log backup the physical size of transaction log file getting smaller and smaller from 100 to 88 and then to 76 and so on. Do you now the reason? Thank you, Natalia
I have a very serious problem, if somebody can help me quickly. my transaction log file is getting bigger and bigger even after truncating. today morning when i checked, it was 1.5 GB, by evening it has gone upto 3GB, the total size of the database is 3.4 GB, out of which 3GB is Transaction log. why is it growing heavily!!!!!!!!. there is not much transaction happening. even after truncating the transaction log it is still showing 3gb.
I currently have an database that is 110 mb and grows on an average of 5mb a week. THe enviornment is IIS 5.0 /ASP /SQL 6.5. However I find myself continously increasing the log file since it frequently fills up. At this point it is 300mb and can be filled in less than an hour with an average of 35 users. I realize that this file has alot of overhead and is affected directly by the application making the updates. Last week on a busy day (time card app) I witnessed the log increase from below 75% to 100% in a minute, forcing me to truncate the log. This application is an administrative nightmare! Any ideas what could cause this type of activity in the trans log.
We have here a small database (around 400 MB) with simple recovery. Also autogrowth is active.
But why does the transactionlog also sized up, when it is not in use? Our TL is around 100 MB and filled with 5 MB. Everytime the DB gets bigger, the TL also....
This isin continuation with my previous query. If i cannot reduce th T Log size , how can i stop it from increasing further. Can i make secondary log files which can be deleted later on?
I need to create a script that would return the size of transaction logs for all databases. I ran a select statement against the sysfiles table but you can only run it against one db at a time. Any suggestions?
Hello dear friends, In my database i am not able to take the backup of transaction log. Even if i took the back up and then shrunk the file it doesnt make any change to my transaction log size. Still the size is same. So in every two weeks i am restarting my server. Once it is restarted then it is ok for another 2 weeks. After 2 weeks my transaction log size will be more than the size of my datafile. Can you suggest your openion. No replication or log shipping exist.
I need to create a script that would return the size of transaction logs for all databases. I ran a select statement against the sysfiles table but you can only run it against one db at a time. Any suggestions?
I have written an application which runs as a windows service. The application constantly requires to write data into the database.. pretty much every seond. Some of the tables have more than 800,000 rows.
the application works fine. Hoever I am noticing the transaction log grows very fast. All information added is handled through stored procedures. In one week the transaction log grew to 2GB. I assume a part of the reason was because I ran out of disk spae once. But generally this transaction log is growing fast. What could cause the transaction logs to grow fast, What could I do to keep the log file size down....I cant have the database down as the application needs to be running constantly.
I have a database whose recovery mode is FULL. I setup one maintenace plan do a backup for the database and another backup plan which backup the transaction log. The two maintenace plans runs daily.
However, the log file is still growing to a very large size. Should the log file be able to reuse after each backup of the transaction log ?
If I'd like to keep the database recovery mode as "FULL", what do I have to do to keep the transaction log within a reasonable size.
Thanks in advance. What is maximum SQL Server database (*.mdf) file size with SQL Server 2000 as part of Microsoft Small Business Server 2000? (Database files were limited to 10 GB in SBS 4.5 with SQLServer 7.0... has this changed?).
If I have a transaction log in a database of size 1GB ( space allocated is during creation of database) currently only 300 mb of its space is used i.e. nearly 700 mb is free. If I want to reduce physical file size of transaction log by 200 mb and release it for operating system then How can I do it???
I'm sure this question has been asked before but I need clarification on a couple of points.
I have a database (500 Mb) which is having a full backup every night at 2AM. I am doing a transaction log backup every 2 hours between 7AM and 7PM. I have noticed that the transaction log keeps growing bigger and bigger so I do a manual truncate.
- Will my transaction log keep growing bigger and bigger ? - How can I automate a task to reduce the log size ? - Does a full backup not truncate the log ?
I created a database and had its file size as automatic grow. Now the database file is of 17 MB and its transaction log file size is 230 MB. After checking transaction log file properties I came to that it is using 13 mb only and the rest of the 230 MB i.e 217 MB is free. I want that area in the transaction log to be freed and get the transaction file size to its actual size. Any help will be greatly appreciated.
My database's transaction log has become 1.7 GB. Can I reduce it's size? I have tried to shrink database and also set truncate on checkpoint option and also taken the backup after that. but nothing helps. Please advice.
A very quick (and probably simple to answer) question.
I have a database for which I used Enterprise Manager to set up a complete backup at 2AM every day and a transaction log backup every 2 hours between 8AM and 8PM.
I have noticed that the transaction log is growing huge but I thought that it is supposed to get truncated every complete database backup !!
What can I do to "manage" the log file size ? (preferably automatic task)