Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Do I need to compact my Exchange 2003 database?

Posted on 2010-11-08
6
Medium Priority
?
636 Views
Last Modified: 2012-06-27
I have an Exchange 2003 server which has been in service for about 5 years so far. The database size has been growing steadily, as expected. It is currently about 85GB in size. It never seems go get smaller, just bigger. Sometimes when people leave the company and their email is archived off the server, I expect that the database size would shrink at least a little within a few weeks, but it does not. Even when we had a big layoff a couple years ago.
Is their something I need to do? I understand that it may just be converting to white space when I archive and delete an account, but if that was the case then the size would at least remain steady for a while after deleting a user as the white space gets re-used instead of the database growing, but it still seems to grow regardless. Is it recommended that I do some sort of offline compaction of the database, or should I just leave it alone if there are not really any problems? I still have more space to grow into, but it won't last forever. I am hoping to get another 2 years out of it.
0
Comment
Question by:robw24
[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
6 Comments
 
LVL 49

Accepted Solution

by:
Akhater earned 2000 total points
ID: 34084424
As you have stated the database will never shrink without an offline defrag.

however offline defrag is useless starting exchange 2003 SP2

>>"I understand that it may just be converting to white space when I archive and delete an account,"

perfectly true

>>"but if that was the case then the size would at least remain steady for a while after deleting a user as the white space gets re-used instead of the database growing"

in theory yes however the space used is not always contiguous it is random, the white space will be reused however not necessary directly

if you are running enterprise version of exchange just create another mailbox database and move all the users to it.

if you decide you still want to do an offline defrag this is how to do it
http://www.petri.co.il/defragment_exchange_2000_2003_server_databases.htm
0
 
LVL 15

Expert Comment

by:JBond2010
ID: 34084431
You can do an offline defrag of the database.

Defragmenting an Exchange 2000 or Exchange 2003 database
Note Defragmenting a database requires free disk space equal to 110 percent of the size of the database being processed.
In Exchange System Manager, right-click the information store that you want to defragment, and then click Dismount Store.
At the command prompt, change to the Exchsrvr\Bin folder, and then type the eseutil /d command, a database switch, and any options that you want to use.
For example, the following command runs the standard defragmentation utility on a mailbox store database:
C:\program files\exchsrvr\bin> eseutil /d c:\progra~1\exchsrvr\mdbdata\priv1.edb
Use the following database switch to run Eseutil defragmentation on a specific database:
eseutil /d <database_name> [options]
Defragmentation/Compaction
Performs off-line compaction of a database.

Syntax: eseutil /d <database_name> [options]

Parameters: <database_name> is the file name of the database that you want to compact.

You are not required to use any of the following options, but you can use one or more (separated by a space) to specify the operations that you want to perform on the database.
Option         Description
----------------------------------------------------------------
/b<database>   Make a backup copy under the specified name

/t<database>   Set the temporary database name (the default is
               Tempdfrg.edb)

/s<file>       Set the streaming file name (the default is NONE)

/f<file>       Set the temporary streaming file name (the default
               is Tempdfrg.stm)

/p             Preserve the temporary database (in other words,
               do not instate)

/o             Suppress logo

/i             Do not defragment streaming file
                              

Note If instating is disabled (for example, if you use the /p option), the original database is preserved uncompacted, and the temporary database contains the defragmented version of the database.

For more information about Exchange Server versions 4.0 and 5.0, click the following article number to view the article in the Microsoft Knowledge Base:
163627  (http://support.microsoft.com/kb/163627/ ) How to defrag an EDB file on a non-Exchange server
For more information about how to run Eseutil on a computer without Exchange Server, click the following article number to view the article in the Microsoft Knowledge Base:
244525  (http://support.microsoft.com/kb/244525/ ) How to run Eseutil on a computer without Exchange Server
The Tempdfrg.edb file is created on the logical drive from which the eseutil /d command is run unless you use the /t switch. For example, to create a Tempdfrg.edb on the root of drive D, run the following command:
D:\>eseutil /d /ispriv
You can also use the /t switch to set the name for the temp database and for a different location. For example, to create a Sample.edb on the root of drive D when you are running the eseutil command from drive C, run the following command:
C:\>eseutil /d /ispriv /td:\Sample.edb
0
 
LVL 6

Expert Comment

by:evanmcnally
ID: 34084504
Exchange will never automatically shrink the file.  You are correct about the white space being reused later, as to why is grows again sooner than you think...the thing is email boxes to all tend to keep growing.

I would say compaction is not necessary, except that since you'll need 110% of the .mdb file size as free space to do a compaction, you may want to do it now rather than later--like if it grows more you will no longer have enough free space to compact.

If in fact the space is simply used and that's why the IS keeps growing, then you won't get back anything significant from a compaction, but it should not hurt anything to try

Have you considered looking at individual mailbox size?  Maybe go to your top users and make them delete/archive some things?  Every email server I have supported tends to have a pattern something like the top 10% of users are consuming 80% of the space.  You can get bad loads of space with better policing of usage.  Users hate this, but I usually explain to the big boss that they'll either need to spend however many thousands of dollars on a new server or else support you in having users clean up.  Once a dollar figure is put on the cost of not cleaning, the size starts to go down a lot!
0
Office 365 Training for IT Pros

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

 
LVL 1

Author Comment

by:robw24
ID: 34084634
Akhater: Good idea regarding creating another database/store and moving the users. Not sure if I will do this but I will keep it in mind. Also thanks for the link on offline defrag.

JBond2010: Thanks for the details on the offline defrag.

evanmcnally: So you think that there is nothing wrong, it's just the whitespace getting re-used quickly? That is what I was thinkng but wasn't sure. It just seemed to get used quickly. I do have limits in place and if they go over they will not be able to send mail (can still receive). So it's not like they are going crazy with their mailbox sizes.  

I do not have enough space (110%) to do a compaction. Would need to be an offline defrag, but I am thinking now that I am probably fine without doing that.
0
 
LVL 49

Expert Comment

by:Akhater
ID: 34084668
You can use any disk for the temp database it can be a usb disk, the bad thing about offline defrag is that it takes time and all your users will be down during this time that's why it is much better to just create a new database and move users to it.


However defrag is not a requirement

0
 
LVL 1

Expert Comment

by:zerocool9669
ID: 34084700
Yes, you will need to do an offline defrag of the mail stores one thing that i have found useful from a performance and maintenance stand point is to departmentalize your exchange stores like create a mail store for sales one for costumer service ect. this way you can take down one store at a time and run a defrage with out disturbing other people. this will also make the exchange environment perform a little quicker.
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

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

This article will help to fix the below error for MS Exchange server 2010 I. Out Of office not working II. Certificate error "name on the security certificate is invalid or does not match the name of the site" III. Make Internal URLs and External…
Know the reasons and solutions to move/import EDB to New Exchange Server. Also, find out how to recover an Exchange .edb file and to restore the file back.
In this video we show how to create an email address policy in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Mail Flow…
how to add IIS SMTP to handle application/Scanner relays into office 365.
Suggested Courses

721 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