Skip to main content

Posts

Showing posts with the label SQL

How to restore bacpac file in SQL server for Sitecore?

Do you know how to restore a bacpac file in SQL Server? You may wonder why you ever need to do it. Well, if you are working in Sitecore, then there are high chances at some point of time in your career, you may be asked to take backup of Sitecore databases in a higher environment and then restore them in lower environment. Recently, a friend  of mine was trying to do the same. He was trying to use restore database option as in snapshot below but it did not work out as expected -  It turned out that Restore Database method is used for restoring .bak files but the backup files he had were bacpac files which have a slightly different restore process. So, I thought other fellow sitecorians may also face similar issue. Why not share it with the community as well.  Bacpac vs Bak file Lets first understand what is the difference between bacpac and bak file. Why there are 2 different types if we are trying to achieve the same goal to restore database? Bacpac is a dacpac file but ...

SQL timeouts in Sitecore instance due to High Index Fragmentation

Sitecore server performance depends a lot on underlying SQL server performance. If SQL server performance decreases, Sitecore server performance will decrease too. That's why its important to have SQL server maintenance plans.  Maintenance plans create a workflow of the tasks required to make sure that your database is optimized, regularly backed up, and free of inconsistencies. You can learn more about maintenance plans here . We observed that a poor maintenance plan can lead to SQL timeout errors in application and the high fragmentation level in the SQL indexes can have major role to play in it. Sitecore recommends keeping index fragmentation below 10% If you see error in your logs which read something like below, its time for you to check your index fragmentation levels and revisit your SQL server maintenance plans -  Execution Timeout Expired. The timeout period elapsed prior to completion of the operation or the server is not responding. How to know if index fragmentatio...