Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Db just get bigger and bigger and bigger
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Db just get bigger and bigger and bigger

 Post Reply Post Reply
Author
pvillaca View Drop Down
Newbie
Newbie


Joined: 03 June 2004
Status: Offline
Points: 34
Post Options Post Options   Thanks (0) Thanks(0)   Quote pvillaca Quote  Post ReplyReply Direct Link To This Post Topic: Db just get bigger and bigger and bigger
    Posted: 02 August 2004 at 1:09pm

Dear friends,

I'm very worried about my forum and I'm desperate for any help you guys can offer me (just don't tell me I'll have to reinstall the forum and lose all msgs, because the users would kill me - I lost everything when I changed from Access to SQL Server and they were pretty pissed).

The thing is: I have 782 members, 44418 messages, 1377 topics. But my SQL Server DB size is 1493.19 MB; my Log file size is 1441.31 Mb and my Database file size is 51,88 Mb. It's nos proportional.

And the worst thing is: I've batch delected topics a few times now, but the db sizes never decreases. It keeps growing, growing, growing.

Help!!!!!!!!!!!!!!

Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 02 August 2004 at 2:25pm
SQL server if setup wrong will store every change ever made for recovery purposes this makes your log file get stupidly large as it will grow each time someone even looks at the forum.

Set the recovery model to 'simple' for the database and sellect 'auto shrink'. These can be found under the options tab for the database.


Edited by -boRg-
Back to Top
pvillaca View Drop Down
Newbie
Newbie


Joined: 03 June 2004
Status: Offline
Points: 34
Post Options Post Options   Thanks (0) Thanks(0)   Quote pvillaca Quote  Post ReplyReply Direct Link To This Post Posted: 02 August 2004 at 4:30pm

Ok, Borg, thanks.

I did just as you said, but the DB remained huge, it didn't shrink. AND after that I deleted 175 topics (older than a month without any new post) and it didn't decrease a single byte.

What can I do?????

Back to Top
michael View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 April 2002
Location: United States
Status: Offline
Points: 4670
Post Options Post Options   Thanks (0) Thanks(0)   Quote michael Quote  Post ReplyReply Direct Link To This Post Posted: 02 August 2004 at 4:49pm

You don't need to delete Topics, they don't really take a lot of space. After you did what Borg said, run the following 2 commands to first truncate the log file as you should not need it provided you got a backup...
backup log yourdbnamehere with truncate_only
and then run optionally the shrink command to get it to the default growth:
dbcc shrinkdatabase (yourdbnamehere)

Back to Top
pvillaca View Drop Down
Newbie
Newbie


Joined: 03 June 2004
Status: Offline
Points: 34
Post Options Post Options   Thanks (0) Thanks(0)   Quote pvillaca Quote  Post ReplyReply Direct Link To This Post Posted: 02 August 2004 at 5:01pm

Yes! It worked!

SQL Server db: BEFORE: 1493.19 MB   
                      AFTER 43.56 MB     (wow!)

Log file size:  BEFORE: 1441.31 Mb 
                   AFTER: 1 MB                       (woooow!!!!)

DB file size: BEFORE: 51,88 Mb
                 AFTER: 42.56 MB

Last question? Could those old settings and huge DB size be responsible for slowing the forum (and, consequently, my whole server) down?

Thanks, you guys!

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.