SharePoint - Database Log files are too big

Asked By Ashish kanoongo
13-Jun-07 01:20 PM
I am using MOSS 2007 with SQL 2000. I am having an issue on my  server. The
system disk is becoming full in every 2 week. I noticed that my sql server
ldf (log files) is very big specially wss-server-content database logfile it
is about 7 GB and there are other 2-3 databases, their log file sizes are
approx 3 gb. I reviewd in sql server enterprice manager and check the

Is this recommended if I fix the growth to 2 MB, should I loss any data
here? If I shrink the databse, again it is on going process everytimg I need
to shrink the databse.

Please suggest what should I do?

Ashish
  Todd Klindt [WSS MVP] replied...
13-Jun-07 04:02 PM
If your transaction logs (the LDF files) are getting large that means one
thing.  Your recovery mode is set to Full and you're either not backing them
up, or you're backing them up with something that doesn't know to truncate
them afterwards.

If you don't plan on doing point in time recovery of your databases then you
can change your database recovery mode to "Simple" and your transaction logs
won't get so large.  You'll still need to truncate them a time or two after
you switch to Simple as stuff gets committed.

For the most part, I never, ever recommend shrinking database files or
transaction logs.  Give them space to grow.  That's what databases do, they
get more data and they get larger.  Every time you make SQL expand a
database or transaction log you impact performance.

tk
  Ashish kanoongo replied...
14-Jun-07 07:54 AM
Hello Todd

Thanks for reply.

I am not a sql guy, can you tell me how can I set simple mode to database
recovery mode and how can truncate the existing database log?

I hope by doing this excercise I will not lose any data.

Ashish
  Todd Klindt [WSS MVP] replied...
14-Jun-07 12:05 PM
You will not lose any data.

Go into the properties of the database in SQL Enterprise Manager or
Management Studio.  Look around for "Recovery Model."  In 2005 it's in the
Options page.  Set the model to Simple.

Wait a few days, then go truncate your Transaction Logs.  That's under Tasks

tk
  Ashish kanoongo replied...
14-Jun-07 02:37 PM
Hello Todd

Thanks for the help. I checked recover model set as "FULL" thne I changed
to "Simple". Do I need to restart the SQL server again?

I also searched Shrink, did not find it anything.

FYI, I am using sql 2000.

Regards

Ashish
  Todd Klindt [WSS MVP] replied...
19-Jun-07 05:54 PM
You do not need to restart SQL for a change in the recovery mode to take
effect.


tk
  tammy rooks replied...
06-Sep-07 02:12 PM
I have been researching to figure out what to do with our Sharepoint SERV database log getting too large.  I currently do have sql backups running for the sharepoint databases, and i know they are set to FULL.  i see in the previous post to change it to Simple, does this affect performance at all?  I am running SQL 2000, not a DBA, how do I truncate the logs, i could not find the option under tasks, i may just be overlooking it.  any help would be greatly appreciated.



tammy
  Dave Tran replied...
03-Oct-07 10:01 AM
hi Tammy,



After you set your data to "simple" recovery mode, in your enterprise manager databases explorer, right-click on the database you want to shrink the log file, select "All Tasks", then select "Shrink Database..." Click on the "Files..." button (close to bottom right corner), then click on the drop down menu on the top of the next screen, choose your log file.  Select "Shrink file to" (middle of the screen)option then click on the up/down arrow to adjust the number for the desired size of the log file, then click OK.  This should shrink your log to the desired size.  Note:  You might have to run a database backup of that database prior to log shrinking, if you've already have a backup mechanism in place, you won't need to manually back it up.



Good luck,

Dave
help
It starts but hangs on second stage. Looks like something went wrong with creation AdminContent database. SQL Databases show following databases:Sharepoint_config and long one having Admin_content. Did I miss something details. The following information is part of the event: #50071: Unable to connect to the database SharePoint_AdminContent_6319df8d-b2ef-438d-89a1-c9e7fbeffde3 on machine \ instance. Check the database connection information and make sure that the database server is running. . - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 2) Event Type: Error Event Source: Windows SharePoint Services 3 Event Category Description: The site / could not be created. The following exception occured: Unable to connect to database. Check database connection information and make sure the database server is running. . For more information, see Help and Support Center at http: / / go.microsoft Wizard Event Category: None Event ID: 104 Computer: SERVER Description: Failed to create the configuration database. An exception of type Microsoft.SharePoint.SPException was thrown. Additional exception information: Unable to connect
EventID1000: #50070:Unable to Connect to Database - WSS 2.0 SharePoint I've got a WSS 2.0 server with lots of SharePoint Web applications on it. Intermittently the event log shows the following errors: Check the database connection information and make sure that the database server is running. Where the DatabaseName varies - always a content database - never the configuration database. (the config db is on a local SQL server, the content databases are on a a user accessing the affected site will get an error on their screen saying the database is unavailable. Yesterday I wrote a c# test app that constantly reads from one of it has been running nearly 24 hours and has shown no errors reading from the database, although the Event Log shows that SharePoint has thrown lots of errors reading from that same database several times. Any suggestions? this has been going on for about 1 week most recently
Moving content database and config database to another server SharePoint Hi, I want to move my config database and content database to another server. How can i do it? I have two SQL services( same server I am MOSS2007 and WSS3.0 . Thanks, Gopal. SharePoint Portal Server Discussions MOSS 2007 (1) Database (1) MOSS2007 (1) CQSH (1) As you can't have installations of both these products WSS FAQ http: / / www.wssfaq.com no questions by e-mail please keywords: Moving, content, database, and, config, database, to, another, server description: Hi, I want to move my config database and content database to another server. How can i do it I have two SQL
Error #50071: Unable to connect to the database SharePoint " / > We have a customer who is receiving this message sporadically throughout the day and would like us to help resolve the issue. - -- -- -- -- -- ecmdbdev. Check the database connection information and make sure that the database server is running. Unable to connect to database. Check database connection information and make sure the database server is running. Possible mismatch between the reported error with code = 0x8107053b and message: "Unable to connect to database. Check database connection information and make sure the database server is running." and the returned error with
SharePoint Content-Database goes empty SharePoint Hello, i have a problem, that every week between friday and saturday my content-database gets empts. only the content database. . . . config database where ok. we have updated from version 2 to 3 but the problems was the same. anyone an idea? regards, dirk SharePoint Windows Services Discussions SharePoint (1) Database (1) EventCache (1) Getsempty (1) Saturday (1) Friday (1) Week (1) Year (1) can you please put some more detail like your content database gets empty mean "all sites are deleted etc" how you confirm that it is empty version 2 and than by the updated version 3. Yes, all sites are deleted. The database-file has the same size, but now rows are in there. Only in the EventCache come back is to restore the databases from a backup. Regards, Dirk keywords: SharePoint, Content-Database, goes, empty description: Hello, i have a problem, that every week between friday and saturday