Intel,Altiris Group

  • 1.  SQL Fragmentation

    Posted Jul 10, 2009 03:16 PM
    We just recently upgraded our server to SQL 2005 and Altiris 7.0. After running a SQL defragmentation job, several of the tables are still 70 or 80% fragmented. The next day the tables will be up to 80 or 99% fragemented. We are using the SQL script from KB article 25784. Is anyone using a script that is more succesful?

    Thank you,


  • 2.  RE: SQL Fragmentation

    Posted Jul 10, 2009 08:25 PM
    It is a pretty standard SQL script. Any of the SQL DBA websites would have similar scripts. If you recently upgraded, I would expect large levels of fragmentation, depending on the situation. You could run the defrag more often, however eventrually I would believe it should return to 'normal"'.


  • 3.  RE: SQL Fragmentation
    Best Answer

    Trusted Advisor
    Posted Jul 11, 2009 02:57 AM
     Hi Leisuretech,

    These scripts are really intended for quick-fix defragmentations. I tend to keep fragmentation under control in the long term by using SQL maintenance plans. In SQL 2005  you can use the maintenance plan designer to quickly create pretty thorough plans.

    I suggest using adding to your nightly backup SQL maintenance plans the task to reorganise your indexes, and once a week to perform a full rebuild. The full rebuild is pretty resource intensive, hence why just once a week. And the maintenance plans should always be scheduled for execution at night... ;-)

    Kind Regards,
    Ian./