D7 upgrade call for help

Events happening in the community are now at Drupal community events on www.drupal.org.
Branjawn's picture

Just seeing if anyone sees something glaringly obvious here, I've been working on this since yesterday. Upgrading D6 to D7:

On non-update pages:
Fatal error: Call to undefined function decode_entities() in /home5/public_html/includes/common.inc on line 1552

On mysite.com/update.php?op=results I get the following:

    * Notice: Undefined index: update_success in update_results_page() (line 162 of /home5/public_html/update.php).
    * Warning: array_pop() [function.array-pop]: The argument should be an array in update_results_page() (line 166 of /home5/public_html/update.php).

The update process was aborted prematurely while running update # in .module. All errors have been logged.

When I ran the update, I got this result on that page:

system module
Update #7002
Failed: DatabaseSchemaObjectExistsException: Table <em class="placeholder">blocked_ips</em> already exists. in DatabaseSchema->createTable() (line 623 of /home5/public_html/includes/database/schema.inc).
contact module
Update #7002
Failed: PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'module' in 'where clause': SELECT 1 AS expression FROM {role_permission} role_permission WHERE ( (rid = :db_condition_placeholder_0) AND (permission = :db_condition_placeholder_1) AND (module = :db_condition_placeholder_2) ) FOR UPDATE; Array ( [:db_condition_placeholder_0] => 2 [:db_condition_placeholder_1] => access user contact forms [:db_condition_placeholder_2] => contact ) in contact_update_7002() (line 128 of /home5/public_html/modules/contact/contact.install).

Comments

fixed part of it

Branjawn's picture

I removed the table blocked_ips and re-ran upgrade.php

The following updates returned messages
system module
Update #7004

    * Failed: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'garland-node-syndicate' for key 'tmd': UPDATE {block} SET delta=:db_update_placeholder_0 WHERE (module = :db_condition_placeholder_0) AND (delta = :db_condition_placeholder_1) ; Array ( [:db_update_placeholder_0] => syndicate [:db_condition_placeholder_0] => node [:db_condition_placeholder_1] => 0 ) in update_fix_d7_block_deltas() (line 349 of /home5/public_html/includes/update.inc).

contact module
Update #7002

    * Failed: PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'module' in 'where clause': SELECT 1 AS expression FROM {role_permission} role_permission WHERE ( (rid = :db_condition_placeholder_0) AND (permission = :db_condition_placeholder_1) AND (module = :db_condition_placeholder_2) ) FOR UPDATE; Array ( [:db_condition_placeholder_0] => 2 [:db_condition_placeholder_1] => access user contact forms [:db_condition_placeholder_2] => contact ) in contact_update_7002() (line 128 of /home5/public_html/modules/contact/contact.install).

Process?

Screenack's picture

Bam; what process did you use for your migration? Do you have your backup? Upgrading from 6 to 7 is more like a major OS rev, and thoroughness matters. There's an excellent recipe for D5 to D6 migration, here: http://drupal.org/node/340073 I used it to save MUCH time when I saw that, in stepping through it, helped to uncover major stumbling blocks prior to making the switch.

Have you done something like that, or, like Nike, did you "just do it"?

Upgrade

Branjawn's picture

I pulled up 3 of the main guides for upgrading and followed them. Yes, I backed EVERYTHING up first. To note, the sites on this account aren't of great importance. It could erase everything and I'd only lose about a day or two of work.
So, back to your question... process.... I did backups using Backup and Migrate. Did some tarballing through CPanel of some other files. Unpacked D7 in root, then systematically replaced core. I did some other things, but that's the jist.
My secondary sites are working alright, but my main install isn't. Obviously, that one shares a db with Drupal, so the problem is in that db (wheres the other sites with their own dbs are working fine it seems).

BU: excellent

Screenack's picture

OK, so this one is essentially an academic exercise, which is a good place to be.

The guide I used had you:

  • Research issues related to migrating modules across major revisions. Proceeding here means, "Yes, no major issues discussed."
  • Note your module state prior to upgrading, disabling all modules, and then do an essentially core migration before migrating each module, and then enabling modules one-by-one, each time ensuring a successful result before continuing on.
  • Have you done that?

    Well...

    Branjawn's picture

    I packed up all my modules and moved the folders out of sites to make sure none of them were culprits. I did the same with themes in sites/all. Is this a bad method of elimination?

    Problem #1

    Branjawn's picture

    First of all, can I get help interpreting this?

    Failed: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'garland-node-syndicate' for key 'tmd': UPDATE {block} SET delta=:db_update_placeholder_0 WHERE (module = :db_condition_placeholder_0) AND (delta = :db_condition_placeholder_1) ; Array ( [:db_update_placeholder_0] => syndicate [:db_condition_placeholder_0] => node [:db_condition_placeholder_1] => 0 ) in update_fix_d7_block_deltas() (line 349 of /home5/aredlion/public_html/includes/update.inc).

    fixed it, haha

    Branjawn's picture

    I just did it, as in Nike, as in Kyle wouldn't like what I did probably :)

    there was some thought to it though... So, since my sub-sites were fine, and their dbs are separate.. I just backed up and deleted my main drupal db, did a fresh install of D7, yes INSTALL, not update.

    Site works, sub sites still work. I just have to rebuild the main site now... but, this is a good lesson for me. I think I will not have a main site anymore, I'll just use that domain as a placeholder for Drupal. that way, if I ever need to I can install and recreate the db without detrimentally affecting the other dbs/sites.

    Ultimately, I do not know what the problem was, nor am I equipped with the knowledge to know. I'm not a db guy, I'm not a server side guy (apache, php, etc) and I'm not a code guy. Thanks for the help offered, Nike won out in the end.

    Yet another reason I should have gone with Wordpress instead of Drupal I guess :\

    Sorry, Bam, I'm a fan of

    Screenack's picture

    Sorry, Bam, I'm a fan of Occam's Razor. I won't try to untangle an unnecessary Gordian knot, though smarter people may have an idea here. The process should be: disable all modules before turning them off. I presume some modules need to manage that process, as opposed to the error condition such a move could make.

    I recommend restoring from backup, ensuring each module has no significant issue with the upgrade. If not, then disable all modules before hand THEN migrating d7 core, then reenabling each module (and running the db update after each successive module enabling.)

    For that matter, I have no plans to migrate to 7 until Drupal distributes their first minor update.

    Though I like WP, and the WP 2.x to 3.x was a more trivial process, (on a far less-complex site, granted) you can do damage there as well if you don't mind your process.

    North Carolina

    Group organizers

    Group notifications

    This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: