Print Page | Close Window

Compacting DB

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=11859
Printed Date: 09 April 2026 at 3:03am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Compacting DB
Posted By: Muskan
Subject: Compacting DB
Date Posted: 19 September 2004 at 4:31am

I encountered this error while trying to compact the forum db.

Active Server Pages error 'ASP 0113'

  1. Script timed out
  2. /admin/compact_access_db.asp
  3. The maximum amount of time for a script to execute was exceeded. You can change this limit by specifying a new value for the property Server.ScriptTimeout or by changing the value in the IIS administration tools.

We have a huge db with thousands of members and posts. Can't I just chnage the script time out property in the script itself instead of asking the server admin to ask for chnaging their standard.




Replies:
Posted By: dj air
Date Posted: 19 September 2004 at 6:21am
you can over ride the script time out by adding the following to the top of the asp page

server.ScriptTimeout = x

(x = secounds)



Posted By: Muskan
Date Posted: 19 September 2004 at 8:58am

Any idea what would be the ideal time for compating that db

 



Posted By: dpyers
Date Posted: 19 September 2004 at 4:43pm

With that size of a db in particular, make sure you lock the forums before compacting.



-------------

Lead me not into temptation... I know the short cut, follow me.


Posted By: typhoon
Date Posted: 20 September 2004 at 5:14am
with that many users i wouldnt go with an Access DB as backend :-)


Posted By: Phat
Date Posted: 20 September 2004 at 6:51am
Originally posted by dpyers dpyers wrote:

With that size of a db in particular, make sure you lock the forums before compacting.



The only problem with this is the pages need to access the db to see if the db is locked anyway. There must be a better way to do this like a text file or something.



Posted By: dpyers
Date Posted: 20 September 2004 at 8:59am
Originally posted by Phat Phat wrote:

Originally posted by dpyers dpyers wrote:

With that size of a db in particular, make sure you lock the forums before compacting.



The only problem with this is the pages need to access the db to see if the db is locked anyway. There must be a better way to do this like a text file or something.

The best way is to lock the db, download it, back it up, and compact+repair it locally. When you upload it back again, ater the c+r, delete the .ldb file then unlock it. The .ldb file tracks who (not a wwf userid - it's a generic session-based who) is currently doing what on the db.

People often report problems with the db being corrupted after doing a compact+repair and they have to do another c+r. I think the main reason that happens is that people are trying to do adds, changes, and deletes - or had an updatein progress while an unlocked db is being compacted. After you lock an access db, you need to wait a minute to let it quiesce - allow the access engine time to complete transactions in progress.

Just trying to read a db being c+r'd doesn't affect the internal indexes like updates/deletes will. I think Access is supposed to dis-allow updates while a c+r is in progress, but I don't believe that's 100% reliable and results may vary depending upon the access engine specified in the connection string and the connection method used - better off to lock the db and allow it time to quiesce if you can't download it.



-------------

Lead me not into temptation... I know the short cut, follow me.


Posted By: Muskan
Date Posted: 20 September 2004 at 11:06pm

Thanks everyone. We would be migrating to SQL Server in a couple of weeks.

For the time being, I did lock the forums before compacting it. Also raised the script timeout to 300. The standard given for the admin pages in 90.

It still does not work!

Any Ideas?



Posted By: xeerex
Date Posted: 21 September 2004 at 9:24am
When you C/R it using the script, it creates a xxx-bak.mdb file as teh backup then deletes that backup after success. If you had problems the first time, the backup is still on the server and will give errors the next time.

FTP into your site and delete the backup.
Lock teh forums.
Run the script again.
Unlock the forums after success.

If it fails again, lock the forums, download the database, do a C/R locally, upload the database and unlock it.

BTW, you can read some of my other posts about the number of users AND concurrent connections that I keep on my Access powered forum. Is MSSQL better? Yep. Can you run a forum on access with a decent amount of traffic? Yep.


-------------
http://webspacegeeks.com - Need Hosting, Domains, Dedicated Servers?
http://www.smartergeek.com - web design | pc support | training | podcasts | video production


Posted By: dpyers
Date Posted: 21 September 2004 at 1:49pm
Also, check with your isp. Some have disabled the ability to alster the script timeout value in code. IIRC, you won't see any message indicating that your script timeout value is to high.

-------------

Lead me not into temptation... I know the short cut, follow me.


Posted By: Muskan
Date Posted: 21 September 2004 at 11:29pm
Thanks everyone. will try again!



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net