Author |
Message |
Eagle
Site Owner
Joined: Wed Sep 15, 2004 1:09 pm Posts: 14631 Location: Pittsburgh
|
 DB Issue
What a mess!
Should be fixed now ... basically the posts table and it's 1.5 million records crashed, had an index error and wasn't recovering properly. Spent all yesterday working on it and a process I ran overnight seems to have fixed it, thank goodness.
Sorry for the downtime.
_________________
|
Fri Aug 28, 2009 6:24 am |
|
 |
Argos
Z
Joined: Sat May 13, 2006 2:20 pm Posts: 7952 Location: Wherever he went, including here, it was against his better judgment.
|
 Re: DB Issue
Did torrino bring you coffee?
_________________ "Der Lebenslauf des Menschen besteht darin, dass er, von der Hoffnung genarrt, dem Tod in die Arme tanzt." - Arthur Schopenhauer
|
Fri Aug 28, 2009 6:50 am |
|
 |
Bradley Witherberry
Extraordinary
Joined: Sat Oct 30, 2004 1:13 pm Posts: 15197 Location: Planet Xatar
|
 Re: DB Issue
Sounds like sabotage. I wonder who has sufficient admin privileges to pull such a stunt...
|
Fri Aug 28, 2009 8:11 am |
|
 |
Eagle
Site Owner
Joined: Wed Sep 15, 2004 1:09 pm Posts: 14631 Location: Pittsburgh
|
 Re: DB Issue
Nah, nothing like that. Looks like the DB crashed partly through an insert, and because the record was partly inserted, indexes were out of wack and everything went bonkers.
_________________
|
Fri Aug 28, 2009 8:17 am |
|
 |
Jedi Master Carr
Extraordinary
Joined: Fri Nov 11, 2005 9:51 pm Posts: 11637
|
 Re: DB Issue
That really sucks, I really appreciate your work. I am sorry you had to spend so much time fixing it though.
|
Fri Aug 28, 2009 9:37 am |
|
 |
Jiffy
Forum General
Joined: Sat Dec 18, 2004 2:27 pm Posts: 6152 Location: New York
|
 Re: DB Issue
Thanks for all your work to fix it!
|
Fri Aug 28, 2009 10:22 am |
|
 |
dolcevita
Extraordinary
Joined: Tue Oct 12, 2004 11:24 pm Posts: 16061 Location: The Damage Control Table
|
 Re: DB Issue
Eagle wrote: Nah, nothing like that. Looks like the DB crashed partly through an insert, and because the record was partly inserted, indexes were out of wack and everything went bonkers. What the hell does that even mean? Thanks for all the (unexpected) hours of working through partially inserted indexes and whatnot.
|
Fri Aug 28, 2009 10:53 am |
|
 |
Eagle
Site Owner
Joined: Wed Sep 15, 2004 1:09 pm Posts: 14631 Location: Pittsburgh
|
 Re: DB Issue
Heh, I'll try and explain better for anyone interested ... basically ... each post has a unique number:
Post 1, Post 2, Post 3, etc. When someone makes a post, the database will automatically give that post the next unique number. Unfortunatly, something happened in the middle of an insert, meaning a record was entered into the database as Post 4, but the database got amnesia and doesn't remember inserting it. Well, the next time someone tried to post, the database again tried to insert the new post as Post 4 and was like "Hey, who the hell are you! There's not supposed to be a Post 4 here!"
That's the basic issue, and fixing that issue isn't as simple as you'd expect. Each time a post is made, the posts table is LOCKED temporarily, and UNLOCKED when the insert completes. Well, since it never finished inserting correctly, the table remained LOCKED, which causes all kinds of headaches. All attempts to unlock the table resulted in the fail whale.
The only way to fix these two problems is a series of repairs on the database, but because the table is so huge (~1.5 million records), attempts to repair it were causing the HTTP service to crash. To get around that, I had to run the repair via command line, but part of the repair process is to build a temporary index file which was too big for the directory it builds in. Meaning it ran out of space and couldn't fully rebuild the database. To give the specific partition more space, I'd have to reformat the entire server, and I didn't want to do that. So I then decided to rebuild the index in memory, which was very SLOW, but seemed to be working. Unfortunatly, when that process finished, it threw an error saying the database was still marked as crashed, and rebuilding the index wasn't sufficient to repair it. Yeesh!!!
So I had to rebuild not only the table indexes, but also the file holding all the data of the database. I kicked that process off before bed, it finished early this morning. Ta Da!
Bet you wish you hadn't asked, heh.
_________________
|
Fri Aug 28, 2009 11:12 am |
|
 |
torrino
College Boy T
Joined: Mon Oct 11, 2004 7:52 pm Posts: 16020
|
 Re: DB Issue
Thanks Karl-izzle!
|
Fri Aug 28, 2009 11:13 am |
|
 |
Riggs
We had our time together
Joined: Thu Oct 21, 2004 4:36 am Posts: 13299 Location: Vienna
|
 Re: DB Issue
Thanks, Eagle 
|
Fri Aug 28, 2009 11:14 am |
|
 |
Rev
Romosexual!
Joined: Tue Oct 19, 2004 3:06 am Posts: 32607 Location: the last free city
|
 Re: DB Issue
Thx Karl  I luv this place n don't ever want it to die.
_________________ Is it 2028 yet?
|
Fri Aug 28, 2009 11:40 am |
|
 |
Libs
Sbil
Joined: Tue Oct 12, 2004 3:38 pm Posts: 48678 Location: Arlington, VA
|
 Re: DB Issue
Yay it's back
|
Fri Aug 28, 2009 11:48 am |
|
 |
Box
Extraordinary
Joined: Sat Oct 16, 2004 12:52 am Posts: 25990
|
 Re: DB Issue
Thanks for your hard work fixing this Eagle!
_________________In order of preference: Christian, Argos MadGez wrote: Briefs. Am used to them and boxers can get me in trouble it seems. Too much room and maybe the silkiness have created more than one awkward situation. My Box-Office Blog: http://boxofficetracker.blogspot.com/
|
Fri Aug 28, 2009 12:29 pm |
|
 |
Excel
Superfreak
Joined: Sat Aug 20, 2005 12:54 am Posts: 22197 Location: Places
|
 Re: DB Issue
Thanks brosef
_________________Ari Emmanuel wrote: I'd rather marry lindsay Lohan than represent Mel Gibson.
|
Fri Aug 28, 2009 12:32 pm |
|
 |
Mr. Reynolds
Confessing on a Dance Floor
Joined: Tue Nov 23, 2004 12:46 am Posts: 5578 Location: Celebratin' in Chitown
|
 Re: DB Issue
Muchas gracias! I missed my KJ lurking yesterday and with all the threads about the site disappearing I was a bit worried. great that it's back up.
|
Fri Aug 28, 2009 12:48 pm |
|
 |
Riggs
We had our time together
Joined: Thu Oct 21, 2004 4:36 am Posts: 13299 Location: Vienna
|
 Re: DB Issue
Yeah I thought it's over now, I'm really glad it's not.
|
Fri Aug 28, 2009 12:55 pm |
|
 |
Passionate Thug
Top Poster
Joined: Sun Oct 17, 2004 1:01 am Posts: 5264 Location: Wakanda
|
 Re: DB Issue
Thanks Eagle! No matter how much guff you get sometimes from certain posters, I've always admired your hard work.
|
Fri Aug 28, 2009 1:35 pm |
|
 |
Riggs
We had our time together
Joined: Thu Oct 21, 2004 4:36 am Posts: 13299 Location: Vienna
|
 Re: DB Issue
Passionate Thug wrote: Thanks Eagle! No matter how much guff you get sometimes from certain posters, I've always admired your hard work. Seconded.
|
Fri Aug 28, 2009 2:13 pm |
|
 |
Korrgan
problem?
Joined: Tue Oct 19, 2004 6:52 am Posts: 15515 Location: Bait Shop
|
 Re: DB Issue
All lies. The truth of August 26th has been documented and made public knowledge.viewtopic.php?f=10&t=53274Never forget.
_________________
|
Fri Aug 28, 2009 3:29 pm |
|
 |
Dr. Lecter
You must have big rats
Joined: Sat Oct 16, 2004 4:28 pm Posts: 92093 Location: Bonn, Germany
|
 Re: DB Issue
Yeah, Karl, thanks a lot!
_________________The greatest thing on earth is to love and to be loved in return!
|
Fri Aug 28, 2009 9:45 pm |
|
 |
Argos
Z
Joined: Sat May 13, 2006 2:20 pm Posts: 7952 Location: Wherever he went, including here, it was against his better judgment.
|
 Re: DB Issue
Thank you very much, Eagle. I will dedicate my first daughter to you.
_________________ "Der Lebenslauf des Menschen besteht darin, dass er, von der Hoffnung genarrt, dem Tod in die Arme tanzt." - Arthur Schopenhauer
|
Sat Aug 29, 2009 2:37 am |
|
 |
STEVE ROGERS
The Greatest Avenger EVER
Joined: Fri Oct 29, 2004 4:02 am Posts: 18501
|
 Re: DB Issue
Eagle wrote: What a mess!
Should be fixed now ... basically the posts table and it's 1.5 million records crashed, had an index error and wasn't recovering properly. Spent all yesterday working on it and a process I ran overnight seems to have fixed it, thank goodness.
Sorry for the downtime. Hmmm.. Must've crashed from the AVATAR trailer Premiere and it's overwhelming popularity.. 
|
Sat Aug 29, 2009 9:33 pm |
|
|