• Hello there, I hope you can help me because I’m in real trouble.

    I’ve been using WP for years, and I only have the greatest praises for it. A few years back I upgraded it from v1.5 (I think!) to v2.1 and everything went smoothly.

    Last night I decided it was time to upgrade again and tried to install v2.6.2

    I read the instructions carefully. I didn’t first delete the WP files off the website, but overwrote them all with the v2.6.2 ones via FTP.

    When done, I launched the blog. It looked fine. I then logged in as admin, and I got a message telling me the database needed upgrading, so I clicked OK.

    Within seconds I got the following error messages:
    ————-
    Warning: is_writable() [function.is-writable]: Unable to access /cache/php.err in /mnt/125/sdb/a/2/ppblog/wp-includes/wp-db.php on line 500

    Warning: is_writable() [function.is-writable]: Unable to access /cache/php.err in /mnt/125/sdb/a/2/ppblog/wp-includes/wp-db.php on line 500

    Fatal error: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /mnt/125/sdb/a/2/ppblog/wp-includes/wp-db.php on line 635

    Fatal error: ob_end_flush() [ref.outcontrol]: failed to delete and flush buffer. No buffer to delete or flush. in /mnt/125/sdb/a/2/ppblog/wp-includes/functions.php on line 1986
    ————
    Now I have tried to “reverse” the upgrade by FTP’ing my previous version of WP (which I saved last night), overwriting the “new” files with the “old” ones. Alas the result is worse than ever:

    1. The blog doesn’t show properly. Every blog entry title is followed by the following message:
    —-
    WordPress database error: [Table ‘ppblog.wp_post2cat’ doesn’t exist]
    SELECT post_id, category_id FROM wp_post2cat WHERE post_id IN (798)
    —–
    Also, at the very top of the page, above the title of the blog itself, this error message:
    —-
    WordPress database error: [Table ‘ppblog.wp_post2cat’ doesn’t exist]
    SELECT post_id, category_id FROM wp_post2cat WHERE post_id IN (798)
    @import url( https://ppblog.free.fr/wp-content/themes/fasttrack/style.css );
    —–
    (does it mean one of my tables has disappeared off the SQL database?)

    2. The right-had column has similar messages, but the “Meta” section is visible and therefore the “Login” item too. However, if I click on it and try to log in, it tells me my password is INVALID.

    In other words, it seems that v2.6.2 has tried to “upgrade” the database, couldn’t do it, but still managed to tamper with it in such a way that it won’t work with WP v2.1 any longer.

    Conclusion: as it is, the blog is completely screwed. Please tell me what to do, this is really depressing.

    Philippe

Viewing 11 replies - 1 through 11 (of 11 total)
  • I’d first consider deleting the WordPress files, then reupload the 2.6.2 file, per Steps 7 and 8 in Upgrading_WordPress_Extended.

    You are getting that error about post2cat because your database was upgraded to 2.6.2 but you reloaded the 2.1 files.

    Thread Starter whynot

    (@whynot)

    Michael H,

    Thank you for your fast response and the link to the “Upgrading_WordPress_Extended” – which I’m reading right now.

    When you say “You are getting that error” I assume you mean after I “downgraded” back to v2.1, right?

    Regarding “upgrading the database”, I took a look at it via phpmyadmin, and here is what I found:

    The upgrade to v 2.6.2 deleted 3 tables from the SQL server database and modified the WP-Users table (which is why I couldn’t log in).

    Restoring from a one-year old backup of the tables, I am now luckily able to run the blog with v2.1 as I used to. Thankfully, the WP-comments and WP-posts tables were left intact, and as a result the blogs appears functional.

    2 questions please:

    1. you say “the database was upgraded”. Well, the thing is it seems it wasn’t upgraded properly since it gave me those error messages.

    2. What is the difference between “deleting all the old files first” and overwriting them with the new ones? I mean, when I did the reverse downgrade, I used the same FTP trick, i.e. overwrite all the “new” WP files with the old ones and WP works fine (it first looked all screwed up but that’s because of the missing tables and the WP-Users table altered by v2.6.2, and now that I have restored the tables, it seems ok).

    1. I meant the database tables were upgraded from the 2.1 structure to the 2.6.2 structure.
    2. It really is better to delete files then upload rather that overwriting. Some will argue that overwriting should be okay but there are times when overwriting files just DOES NOT work properly so better to delete the files first, then upload.

    You are commended for having backups!!!!!

    Thread Starter whynot

    (@whynot)

    Ok, thank you MichaelH, I will try to do the whole thing as per the book.

    In the meantime, after having restored the missing database tables, I see one little hickup which I don’t know whether it can be fixed or not.

    It’s to do with the categories (as in: when you post an article, you tag which category{ies) it belongs to.

    As it is now (after restoring all I could EXCEPT the wp-comments and wp-posts tables since they are both one year old), I have this strange thing by which all the articles posted show with no category, or rather more exactly:

    Title of Article
    Posted by XXX under Uncategorized …

    The “uncategorized” word is not marked as a hyperlink. I mention this because in the “categories” available, there is an “Uncategorized” one.

    The page itself listing the categories available is still there, which I was able to verify by “editing” an article and assigning it 2 categories, with the result that it “works”, meaning those 2 categories show as hyperlinks in the “Posted by XXX under Politics, News…).

    In other words, it’s as if the WP-posts table got modified somehow and the row (or is it column) referring to WHICH category(ies) each article was assigned to has gone into lala-land.

    Is this possible? If this is the case, I’m screwed because I can’t restore the WP-Posts table since it would mean that any article posted within the last year would disappear.

    The WP-categories table looks fine, and for good measure I restored it, but alas no difference.

    This is not very important, I can live with it, but I would very much like to understand the mechanism by which all articles have lost every assigned “category” and yet it is possible to modify them right now and assign them again manually.

    I am sorry if this sounds really messy. I hope you understand what I am saying.

    Thank you again for your help.
    Philippe
    PS; doing backups of the SQL database is a real pain. On my ISP you are limited to a certain amount of MB, which means it is impossible to back up the WP-posts and WP-comments tables. ??

    I am afraid that kind of “selective” backup/restore as you did with only certain tables is not an ideal solution. Tables are inter-related, e.g. the relation between a post (entry) and the categories (i.e. which category the post belongs to) is stored in another table – different one in 2.1 and 2.6. Same goes for the posts/comments.

    And I’d contradict MichaelH regarding your backup habits: having only a year old backup is not something to be commended for…

    Thread Starter whynot

    (@whynot)

    Moshu,

    Thank you for trying to help. I don’t know it the following can help in turn, but I’lll try anyway:

    First I’m sorry that I only back up the SQL database once a year. I’ve been back on a 56K modem afer a few years of ADSL, and it’s very painful to backup the database via phpmyadmin. Not only because of how slow it is but because there are limits to the size of the tables one can back up on my ISP.

    It is all very nice to say I should do an entire backup rather than individual tables one at a time, but the reality is that it cannot be done. My ISP sets a MB limit on SQL tables backup sizes (I’m not sure whether it is due to their version of phpmyadmin or some other internal limitation), therefore I can only back up tables other than WP-Comments and WP-posts because both exceed the size limit.

    Regarding cross references between tables I am well aware of this factor. This is why after I restored the missing tables that WP v2.6.2 deleted, the blog is now more or less working as it used to – i.e. under WP 2.1.

    Regarding the missing cross-references to articles posted but with a “blank” entry concerning their “categories” I found that after restoring the “missing” “post2cat” table which WP 2.6.2 caused, the missing entries only applied to the 6 months or so of articles prior to the restauration of that table.

    In other words, ALL articles posted previous to that DO have the correct cross-table-link to the category(ies) originally entered.

    I understand about tables being cross related by other tables. This is why I restored the “Post2cat” table, with the above mentioned results, clearly showing that somehow, the information passed on by that “in-between” table is not lost, but somehow recent posts HAVE lost it.

    I am sorry that my problem is such a pain.

    moshu is correct in contradicting me about the backups–I missed the fact your only database backup was a year old. I take back that commend!

    With that said, I’d recommend you take your backups and run to a new host that doesn’t restrict backups.

    I’ve recently upgraded my WP2.5 to WP2.6.2 & to my worst nightmare, my SMF forum doesn’t work as soon as I post a new topic. The SMF forum is currently running on version 1.1.6. I’ve reloaded my backup copy of the forum, still it doesn’t show anything at all….any idea how to go about this?

    zigzagler – that question probably deserves it’s own thread.

    @whynot: A possible reason your newer posts might not be reporting their categories correctly is that you may have modified or added categories since your last backup.

    I’ve been experiencing a similar issue while trying to upgrade my blog from WP2.1 but I get error messages after I click the ‘upgrade’ button already. Fortunately I have recent backups and try all potentially breaking changes on a local copy of my blog before rolling it out to my live site.

    After running the upgrade I was presented with a long list of database errors mostly taking the form of Table not found errors. This was for the 3 tables WP2.6 replaces categories, post2cat, and link2cat with. Obviously the creation of the replacement tables (terms, term_taxonomy, and term_relationships) fails at some point during the upgrade and causes the remainder of the upgrade to fail but doesn’t stop the original category tables from being dropped.

    While I’ve not been able to delve too deeply into the real cause of the issue, I seemed to have prevented this problem from occurring (and having the upgrade complete without an error message) by disabling my plugins (as instructed in the upgrade manual/page/wiki in the first place). In my case this was just Akismet.

    After some delving I believe I’ve discovered my problem but I don’t know if it’s relevant to yours. It’s definitely not the plugin thing. I’ve posted in another thread: https://www.ads-software.com/support/topic/190524 and have also blogged about it, but I’ve already linked to my blog post from the above thread and don’t want to be too opportunistic ??

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Disaster upgrading from v2.1 to v2.6.2’ is closed to new replies.