Solved

SQL Management

Posted on 2014-10-03
7
667 Views
Last Modified: 2014-10-16
I'm not very familiar with SQL therefore I apologize for my ignorance. I'm looking through a server and I'm trying to figure out hot to shrink mdf and ldf files. The problem is that I can't find the databases related to those files. The server has a weird setup with SQL 2005 and 2008 installed. I found one instance of SQL Management Studio Express(version 10.0.5520) but it doesn't have that database. I'm actually looking for the SharePoint database so I can shrink it.

Any help would be appreciated.
0
Comment
Question by:Alan Dala
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 23

Assisted Solution

by:Thomas Grassi
Thomas Grassi earned 250 total points
ID: 40360781
Goto central administration for sharepoint

then go to the application management tab  then select content databases

that will show you the sql server and database name
0
 
LVL 25

Assisted Solution

by:jogos
jogos earned 250 total points
ID: 40361176
If you are not familiar with sql please take time to have some background on what you want to do
http://www.straightpathsql.com/archives/2009/01/dont-touch-that-shrink-button/
http://www.straightpathsql.com/archives/2009/01/shrinking-is-a-popular-topic/

And having read that. Witch database files do you want to shrink (data/log, fro, which db), how you want to do that (shrink/truncate), do you know possible consequences of that shrink ?  And answer the question why is that file to large, how it became so and how long will it take after the shrink before it will grow again.
0
 
LVL 23

Assisted Solution

by:Thomas Grassi
Thomas Grassi earned 250 total points
ID: 40361275
How many sql instances you have?

Is SQl running on only one server?

Is SharePoint on the same server as SQL?

On the server that is running sql by default it resides in this folder C:\Program Files\Microsoft SQL Server

You will see folders

80
90
100

Then instance name folders

you will find your databases there
0
PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

 

Author Comment

by:Alan Dala
ID: 40362850
Thank you for your answers!

Since this is a SBS 2011 server, it came with SharePoint already installed. Although not in use, the Sharepoint database keeps growing, filling up the server. I don't want to just delete the .mdf and ldf files since I heard it can cause other issues in the server(true?). I was looking for a way to shrink the database but when I open Management Studio, I don't see the database. I see just the system databases ( master, model, etc)
0
 
LVL 23

Expert Comment

by:Thomas Grassi
ID: 40362862
This article will help you move he databases

By default they are located in c:\program files\microsoft SQL server\mssql$sharepoint\data


Support.microsoft.com/kb/843580

You can move the databases to a larger drive
0
 

Author Comment

by:Alan Dala
ID: 40363839
Thank you all for your responses.

I don't want to move the databases. I just want to shrink the ldf file since it's running out of control. We don't even use that instance of SharePoint. I don't want to just delete the file cause I'm not sure if the server needs it for something else. For now I found this Microsoft tool that shrinks the SharePoint files. It was pretty effective in lowering the size considerably. It's not exactly how I wanted to do this but at least it took care of the problem for now.

http://support.microsoft.com/kb/2000544
0
 
LVL 25

Accepted Solution

by:
jogos earned 250 total points
ID: 40366791
"We don't even use that instance of SharePoint"
And you probably don't do a transaction log backup of that instance.  The growing database will be in FULL recovery model and then logfile will full up (and eventualy grow) until the next transactionlog backup is taken so the space can be freed.

http://msdn.microsoft.com/en-us/library/ms189275.aspx

And don't try to just delete a database file
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

728 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