Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
On a D7.26 system successfully running running ctools 7.x-1.3+7-dev (2014-Jan-28) and panels 7.x-3.3+54-dev (2014-Jan-28):
$ drush updb
No database updates required
Finished performing updates.
$ drush up
Checking available update data ...
Update information last refreshed: Mon, 02/03/2014 - 23:20
Update status information on all installed and enabled Drupal projects:
Name Installed version Proposed version Status
[...]
Chaos tools (ctools) 7.x-1.3+7-dev 7.x-1.x-dev Update available
[...]
Panels (panels) 7.x-3.3+54-dev 7.x-3.x-dev Update available
[...]
Code updates will be made to the following projects: Chaos tool suite (ctools) [ctools-7.x-1.x-dev], Panels [panels-7.x-3.x-dev]
Note: A backup of your project will be stored to backups directory if it is not managed by a supported version control system.
Note: If you have made any modifications to any file that belongs to one of these projects, you will have to migrate those modifications after updating.
Do you really want to continue with the update process? (y/n): y
Project ctools was updated successfully. Installed version is now 7.x-1.x-dev.
Backups were saved into the directory /…/drush-backups/…/20140204052755/modules/ctools.
Project panels was updated successfully. Installed version is now 7.x-3.x-dev.
Backups were saved into the directory /…/drush-backups/…/20140204052755/modules/panels.
WD php: PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table '….cache_panels' doesn't exist: TRUNCATE {cache_panels} ; Array [error]
(
)
in cache_clear_all() (line 165 of /…/includes/cache.inc).
PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table '….cache_panels' doesn't exist: TRUNCATE {cache_panels} ; Array
(
)
in cache_clear_all() (line 165 of /…/includes/cache.inc).
Drush command terminated abnormally due to an unrecoverable error.
Backups were restored successfully.
Backups were restored successfully.
A similar error was reported earlier in the otherwise unrelated #2187433: UUID update necessitates an explicit dependency on the updated Ctools.
Comment | File | Size | Author |
---|---|---|---|
#111 | panels-n2188277-111.patch | 562 bytes | DamienMcKenna |
#70 | 2188277-panelscache-schema-2.patch | 1.68 KB | japerry |
#65 | update.png | 8.11 KB | Yuri |
Comments
Comment #1
liza CreditAttribution: liza commentedthat error disappeared for me once i disabled the CONTEXT module. it wasn't enough to update CTools to the latest dev. I had to completely disable context and all it's associated modules not only for drush to abort in the middle of updating the database; but for drush to work at all afterwards.
Comment #2
jerry CreditAttribution: jerry commentedUnfortunately, that didn't work for me. My site is also using Context, but disabling it prior to the Panels update does not prevent the TRUNCATE errors shown in the original post. Drush also works normally for me apart from the inability to update Panels, whether Context is enabled or not.
Comment #3
Yuri CreditAttribution: Yuri commentedI confirm that this appears when installing the latest dev of panels. I replaced it with the stable version and the error message went away.
In my case the cache_panels table never existed in the database, as far as I can see from backups so its not caused by a sudden deletion of that table.
Comment #4
Yuri CreditAttribution: Yuri commentedComment #5
Yuri CreditAttribution: Yuri commentedSet to Major since using the 'stable' version of Aug 12 2012 is not an option...seems to be incompatible with a number of recent changes in modules.
By the way, the exact error message that I get when updating panels to the latest dev is
Comment #6
DamienMcKennaDid you run the database updates?
Comment #7
Yuri CreditAttribution: Yuri commentedyes i did.
Comment #8
DamienMcKennaIf you ran the database updates then it should have ran update 7303 which creates the 'cache_panels' table. Can you please check the 'schema_version' value in the {system} table for the main 'panels' table and let us know what it says?
If you have Drush installed you can fix the problem with the following command:
Alternatively, change the 'schema_version' to '7302' and run the database updates again.
Comment #9
DamienMcKennaAre any of you using Panels Everywhere? Do you have any additional / custom caching modules that interact with Panels, eg Expire?
Comment #10
jerry CreditAttribution: jerry commentedIn my case, it's 7302. Both "drush updb" and update.php report that there are no available updates, but apparently 7303 wasn't performed.
I'm not using Panels Everywhere, and while I do have Cache Expiration 7.x-2.0-beta2 installed, it's not enabled.
Comment #11
DamienMcKennaCan you please try downloading the dev release again?
Comment #12
deanflory CreditAttribution: deanflory commentedI too am having the issue with the new cache table not being created:
Using:
Panels 7.x-3.3+63-dev 2014-Jan-31
Drupal 7.26
Prior to executing the update, these are the proposed changes:
No "cache_panels" table has been created in the database.
I was updating two different sites at the same time and the one with far less modules installed did not have the error but the larger site did.
The site that did not incur the error in question did indeed create a new "cache_panels" table:
SELECT *
FROM `cache_panels`
LIMIT 0 , 30
The D7.26 site that did have the error has this system table schema:
sites/all/modules/panels/panels.module
panels
module
1
0
7303
The D7.24 site that did not have the error has this system table schema:
sites/all/modules/panels/panels.module
panels
module
1
0
7301
The error was repeatable on the site having the error.
Comment #13
DamienMcKennaDid you see any errors during the update on the larger site? I wonder if update 7302 is timing out?
Comment #14
deanflory CreditAttribution: deanflory commentedOnly the one reported in #12:
From my limited knowledge, it appears that the error is on 7303 unless the process performs both at the same time or in reverse order. Most of my timeouts settings on my server are WAAAAY jacked-up so I can't see that being an issue unless it involves MySQL. Also, the process didn't take that long, have had other updates take longer.
Comment #15
DamienMcKennaOut of interest, has anyone applied any patches that would have changed the update # for Panels?
Comment #16
deanflory CreditAttribution: deanflory commentedNo, none here.
Comment #17
jerry CreditAttribution: jerry commentedThat worked for my case:
Thanks, Damien. I probably should have tried that already.
Comment #18
deanflory CreditAttribution: deanflory commentedJust tried downloading it again, and running update.php, which did not complete due to the error:
FYI, I am not using drush.
Grrr...reverting...again.
Just to clarify, the version I used both times was 7.x-3.x-dev 2014-Jan-31
Comment #19
rwam CreditAttribution: rwam commentedSame issue here at an update from 7.x-3.3 to 7.x-3.4. ctools is updated separately to 7.x-1.4.
Here is my output from drush:
I've solved this issue with following 2 steps:
1st:
and 2nd:
Now it works, but it's less than ideal. May is this an issue for 7.x-3.4 too?
Ciao
Ralf
Comment #20
DamienMcKenna@rwam: What command did you run the first time? You shouldn't have needed to download Panels again, simply running "drush updb" or "drush updatedb" should have been enough.
Comment #21
bioborg CreditAttribution: bioborg commentedSame thing here as @rwam.
Today, needed 2 updates, ctools and panels.
Did a drush up, got the above error. Tried the drush fix to create panels cache, failed.
did a drush dl ctools, then drush updb, then drush dl panels and drush updb , and all is good now.
Comment #22
afoster CreditAttribution: afoster commentedUpdating from panels 7.x-3.3 via $drush up panels gives the same error
Confirming #21 worked for me,
I did it slightly out of order - drush dl panels, drush dl ctools, drush up
Comment #23
japerrySeems like drush updb is executing cache clear before the update hook is being called. I have a fix idea, but will require a new release. sigh.
Comment #24
rwam CreditAttribution: rwam commented@DaminenMcKenna: I used drush up first without success. Next I use drush up ctools to update Chaos Tools separately. After that I tried drush up panels and drush updb. Only with the procedure described above I can update the project.
Comment #25
rondev CreditAttribution: rondev commentedAs I don't use drush, I created the database in phpmyadmin with the following sql line:
CREATE TABLE `cache_panels` ( `cid` varchar(255) NOT NULL DEFAULT '' COMMENT 'Primary Key: Unique cache ID.', `data` longblob COMMENT 'A collection of data to cache.', `expire` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry should expire, or 0 for never.', `created` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry was created.', `serialized` smallint(6) NOT NULL DEFAULT '0' COMMENT 'A flag to indicate whether content is serialized (1) or not (0).', PRIMARY KEY (`cid`), KEY `expire` (`expire`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Generic cache table for caching things not separated out...';
You would change the database name according to your database schema (suffix, prefix,...).
I got this line from a database dump and copy from other an cache table as it seems generic. Schema module says nothing wrong.
Comment #26
Joel MMCC CreditAttribution: Joel MMCC commentedWe, too, are having this issue. We did the security updates to CTOOLS, Webform, etc. that all came in today, and on some sites the update worked fine, and on others it’s failing. The complexity of the site (other modules installed) appears to be the determining factor.
I Updated the Issue to reflect that it affects the new stable 7.x-3.4 as well as the previous -dev release.
While I may have stepped out of line here (and if so, I apologize), I also took the opportunity to edit @jerry’s main Issue text to redact all references to internal path names and database names and prefixes, as that information would be valuable to black hats and script kiddies. I can’t do that for comments, of course, so all of you who’ve posted raw drush dumps here, you may want to edit them. You should never post dumps including any such info on this nor any other tech forums. Be assured that black hats have bots running scripts scraping these and other tech support and developer forums for just such info.
My preferred technique is to replace all such path portions and prefixes with a horizontal ellipsis character (“…”), which in a monospaced font such as is used in <code> and PHP blocks looks considerably different from three periods so it’s obvious that the path shown has the extraneous but potentially dangerous info redacted.
To type a horizontal ellipsis, you can either use [Alt] + ([0 Ins] [1 End] [3 Pg Up] [3 Pg Up]) on the numeric keypad only on a Windows system, or [Shift]+[Option]+[:;] on a Mac OS X system. You may also be able to use the HTML Named Entity “…” and/or the HTML Numeric Entity “…” depending on the forum.
I also made the reference to the “unrelated” CTools issue into a proper Issue link, as well as inserted it as a Related Issue in the Issue Relationships.
Comment #27
Jaesin CreditAttribution: Jaesin commentedThis seems to be caused by Commit#: 599d24e. https://drupal.org/node/2184143
This might help some of you get this fixed.
From your modules directory:
Comment #28
DamienMcKennaGang,
The problem is, in part, because of the sequence of steps Drush takes when using the "update" aka "up" command - it downloads the new modules, then seems to spawn a new task to run the updates. As a result of this, using the "drush up panels" command repeatedly will not solve the problem, it's just repeating the same steps that are shown to fail.
An alternative to this is running "drush pm-updatecode" aka "drush upc", that just downloads the bare code changes (without touching the database updates), and then separately run "drush updb", I suspect this should work.
@japerry: Maybe you could talk to Moshe about it? I'm in IRC if you want to discuss anything (#drupal-seo, #drupal-nh).
Comment #29
Stephen OllmanNon drush version shown at #25 worked beautifully for me.
As long as you have access to you phpmyadmin,running that command creates the table and allows the update script to do its job without error.
Thanks rondev!!
Comment #30
burtlo CreditAttribution: burtlo commentedI just drushed this by doing "drush dl panels", then "drush updb".
I tried "drush upc", from #28, but it behaved the same as "drush up" for me.
Comment #31
activelink CreditAttribution: activelink commentedI tried updating to 3.4 today with drush and had this problem. The solution in #21 did not work for me, the update failed each time with the following drush output:
And panels updates 7302 and 7303 were still pending, though 7302 appeared to have run?
I notice that 7303 Adds the custom cache table, so is it that these updates are in the wrong sequence?
I had to use the solution in #25 to manually create the cache table. Then the drush updb ran without error:
Comment #32
nno CreditAttribution: nno commentedHad a same issue with drush pm-update. Tried to update from Panels 7.x-3.3 to 7.x-3.4. Ctools 7.x-1.4.
This went just fine:
drush dl panels
drush updatedb
Comment #33
taugusto CreditAttribution: taugusto commentedany simple solution for one without Drush ?
Comment #34
DamienMcKennaYou might try the following:
Edit panels_update_7302() in panels.install and insert the following as the first line of the function:
This will make it trigger panels_update_7303 before it tries to do he changes in panels_update_7302, just in case that causes any problems.
Comment #35
devenpro CreditAttribution: devenpro commentedThanks DamienMcKenna
#34 worked.
Comment #36
lepro CreditAttribution: lepro commentedWhat the post # 25 worked great for me.
As long as you have access to phpMyAdmin, run this command creates the table and allows the upgrade script do its work without error.
CREATE TABLE `cache_panels` ( `cid` varchar(255) NOT NULL DEFAULT '' COMMENT 'Primary Key: Unique cache ID.', `data` longblob COMMENT 'A collection of data to cache.', `expire` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry should expire, or 0 for never.', `created` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry was created.', `serialized` smallint(6) NOT NULL DEFAULT '0' COMMENT 'A flag to indicate whether content is serialized (1) or not (0).', PRIMARY KEY (`cid`), KEY `expire` (`expire`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Generic cache table for caching things not separated out...';
Rondev thank you very much!
Comment #37
taugusto CreditAttribution: taugusto commentedI have inserted "panels_update_7303();" in function "panels_update_7302()" in panels.install file
Returned:
The following updates returned messages
panels module
Update #7302
•UUID column already present in the panels_display & panels_pane tables. Generated UUIDs for database-based panel displays and panes.
.
Seems ok ?:)
Thank You DamienMcKenna !
Comment #38
niki v CreditAttribution: niki v commentedNon-drush user.
I tried #25 and successfully created the table but the update still refuses to run and if I check the system table, I'm running update 7301.
Comment #39
DamienMcKennaPlease also keep an eye on #2195243: Loosing database connection during upgrade.
Comment #40
niki v CreditAttribution: niki v commentedLooking at #2195243 I don't have any outstanding updates except for panels. Was CTools only a code update or was it also a database update?
When trying to run update.php I get a notice of Panels 7302 and 7303 as pending but they don't run.
The only error in my logs was the "SQLSTATE[42S02]: Base table or view not found: 1146 Table 'actived7.cache_panels' doesn't exist" related to the missing cache_panel table that went away after I created it
Update: Used Devel to uninstall and reinstall module. Now system table is correct (7303) and no more outstanding updates showing on update.php
Comment #41
lord4gb CreditAttribution: lord4gb commented#21 method via drush worked for me. Thank you
Comment #42
evoltech CreditAttribution: evoltech commented#19 worked for me
Comment #43
tyler.frankenstein CreditAttribution: tyler.frankenstein commentedThanks to many of the comments above, this worked for me:
Clear all caches on the 'cc'.
Comment #44
marcelgalema CreditAttribution: marcelgalema commented#32/#43 worked fine for me on two different sites (both staging sites, not tried on the production sites yet), after having updated all other modules (most noticeably ctools) using the regular drush up. So:
drush up ctools
drush updb (nothing needs to be done if drush up went fine)
drush dl panels
drush updb (now the two db updates are done)
drush up (just checking)
Update: it worked on 3 out of 4 live sites. The last one failed, but using the CREATE statement to set up the cache table did the trick. All fine now. Thx everybody for posting solutions!
Comment #45
lemdeals CreditAttribution: lemdeals commentedHI, #36 work for me.
I am not have access to drush because my site is in a share server. I used phpmyadmin, and the solution works very well. Thanks for your help.
lem
Comment #46
aasarava CreditAttribution: aasarava commented#32 worked for me, which is essentially downloading the latest version of the module and installing it, then running update.php. Presumably you could do this manually instead of drush.
Comment #47
davoaxiom CreditAttribution: davoaxiom commented#36 seems to have done the job. On a shared server and the phpmyadmin did the trick. Thank You!
Comment #48
Eleine CreditAttribution: Eleine commented#25 worked for me. It can be run from drush like this:
drush sql-query 'CREATE TABLE `cache_panels` ( `cid` varchar(255) NOT NULL DEFAULT "" COMMENT "Primary Key: Unique cache ID.", `data` longblob COMMENT "A collection of data to cache.", `expire` int(11) NOT NULL DEFAULT "0" COMMENT "A Unix timestamp indicating when the cache entry should expire, or 0 for never.", `created` int(11) NOT NULL DEFAULT "0" COMMENT "A Unix timestamp indicating when the cache entry was created.", `serialized` smallint(6) NOT NULL DEFAULT "0" COMMENT "A flag to indicate whether content is serialized (1) or not (0).", PRIMARY KEY (`cid`), KEY `expire` (`expire`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT="Generic cache table for caching things not separated out...";'
Comment #49
coolhandlukek2 CreditAttribution: coolhandlukek2 commented#36 worked for me thx - must learn to use drush!
Comment #50
Tubia87 CreditAttribution: Tubia87 commentedI experienced the same problem.
My solution was run these commands:
When I run the "updb" command, it updated also to schema version 7302 and 7303 from panels. I suppose was due to previous attempts to update panels module.
Hope it helps someone :)
Comment #51
JBecker CreditAttribution: JBecker commentedI can confirm this bug. I tried to update via "drush up". Same behaviour like in #32 and this workaround works ;)
Comment #52
Perignon CreditAttribution: Perignon commented#34 is the fix. You must force the update to run in the correct order so that the tables are created.
Comment #53
Jovan-2 CreditAttribution: Jovan-2 commented#25 and then setting schema_version to 7300 for panels in system table all through phpMyAdmin. Ran update.php. Building the panels cache table was skipped, since it was manually created in #25, but everything else ran and I haven't had any other problems.
Comment #54
javiernovoac CreditAttribution: javiernovoac commented#34 works for me!
thanks!
Comment #55
deanflory CreditAttribution: deanflory commentedAdding this to the beginning of the first line of the panels.install file like stated in #34 seems to have worked here:
Comment #56
REo CreditAttribution: REo commentedSame problem here. #34 (followed by drush updb) works for me.
Comment #57
decibel.places CreditAttribution: decibel.places commented1. dl panels-7.x-3.x-dev (doesn't fix)
2. running drush updb (no updates required)
3. add panels_update_7303(); to install file (panels already installed, so not run)
4. SQL query in #36 (and #25 and #48) - WORKS!
I added "IF NOT EXISTS" and bookmarked the query since I will probably need it again on other databases
Comment #58
postrational CreditAttribution: postrational commented#48 worked for me.
Comment #59
MethodDan CreditAttribution: MethodDan commentedI ran into this problem today with a live site. But following the instructions in comment #21 worked for me after trying many other things. I did:
- drush dl ctools
- Save over current location? Y
- drush dl panels
- Save over current location? Y
Then I was able to run a full "drush up" command and it worked :)
Thanks for this information, it was a real life saver!
Comment #60
robomalo CreditAttribution: robomalo commented#25 worked for me as well
Comment #61
sujomuc CreditAttribution: sujomuc commented#25 worked for me too.Thanks!
Comment #62
mdooley CreditAttribution: mdooley commented#34 worked for me. Thank you!
Comment #63
reinier_post CreditAttribution: reinier_post commentedThis same problem prevented
drush pm-update
from working for my sites.I used (a fixed version of) #8 above:
drush ev "db_create_table('cache_panels', drupal_get_schema_unprocessed('system','cache'));"
Thanks to all of you and Damien McKenna in particular.
Comment #64
MsNingrum CreditAttribution: MsNingrum commentedI was experiencing similar issue, until I realized that panels requires ctools, at the same time I had ctools that needs to be updated too, so I updated ctools first then updated panels. Problem solved.
Comment #65
Yuri CreditAttribution: Yuri commentedCOMMENT REMOVED because i made a mistake in modifying the panels.install. It now works ;-) Sorry.
Comment #66
qipengos CreditAttribution: qipengos commentedFor #34, it works:
When I finished, it said:
What's means?
Comment #67
sylvaticus CreditAttribution: sylvaticus commentedupdating first ctools didn't solve the problem, but #63 did.. thank you..
Comment #68
japerryLooks like adding
Works well. (edit: lets have the right update number here ;-) )
Comment #69
japerryNevermind. The issue is around how panels does revisions per schema. The cache table went into the original schema, causing this regression. I've made some changes below.
Try this and see if it fixes the issue:
Comment #70
japerryRe-rolled patch based on code from #2187433: UUID update necessitates an explicit dependency on the updated Ctools that performs a check first to make sure you have ctools 1.4 installed before it tries to install panels.
Comment #71
AgentJay CreditAttribution: AgentJay commentedI'm pretty sure the easiest fix is the one suggested by DamienMcKenna at #34
For the less experienced. This means opening panels.install in the root of the panels module folder. Going down to line 405 and adding:
panels_update_7303();
So this (before):
Will become this (after):
It will give you a this message:
Update #7302
UUID column already present in the panels_display & panels_pane tables. Generated UUIDs for database-based panel displays and panes.
But that is just because the update is trying to run twice so it is ignored once. No worries and it all works fine :)
Cheers.
Comment #72
DamienMcKenna@japerry: might it be worth bumping panels_update_7303 to panels_update_7304 to help people who might have ran the updates but resulted in a borked site?
Comment #73
japerryHmm I don't think we should need to do that. Looking at the errors reported above, it seems to occur on 7302, probably when clearing the cache, and calling a table that doesn't exist because its in the schema but not yet added in 7303.
This should mean that 7303 was never executed, so the system table won't show 7303, it should show 7302 or 7301. I guess a question for those having this issue: "When you go back to try to update again, does it show 7302 and 7303 as pending updates?"
Comment #74
James A CreditAttribution: James A commentedNon drush user
Ran the update and had the issue described so rolled back my database using backup and migrate and followed #34 and #71, everything appears to have worked out fine with the following output, although this is slightly different to the output others have reported:
The following updates returned messages
panels module
Update #7302
•Added panels_pane.uuid column. Added panels_display.uuid column. Generated UUIDs for database-based panel displays and panes.
Comment #75
tripper54 CreditAttribution: tripper54 commented@japerry: "When you go back to try to update again, does it show 7302 and 7303 as pending updates?"
Yes, after the failed update / cache clear a drush updatedb still showed both these updates as pending.
Fix in #71 did the trick for me.
Comment #76
japerry@tripper54, did you try to re-run the updates with the changes in the patch I suggested, or did you just copy #71?
One other problem was found, its possible clear cache is throwing the error. There is a hook for flush caches which is probably causing the error to occur before the update is applied. I threw a check around this hook to check to make sure the table exists before updating.
This and the patch are pushed now.
http://drupalcode.org/project/panels.git/commit/8059bda
Comment #77
cryptosmith CreditAttribution: cryptosmith commented#25 and #36 worked for me.
I used the text of the query exactly as written - I tried replacing the table name with the one reported in the error message, but that only failed differently.
I also received the Panels #7302 message.
Interestingly - I run two separate hosts in this configuration. The first one updated just fine, except that I saw the Panels #7302 message. The second one crashed and burned with the PDOException.
Comment #78
Clint Eagar CreditAttribution: Clint Eagar commented#25 worked for me as well.
Thank you.
Comment #79
gngn CreditAttribution: gngn at Computer Manufaktur GmbH commented#19 worked for me too
Comment #80
Druper CreditAttribution: Druper commentedNon drush version shown at #25 worked beautifully for me as well.
Comment #81
rajmataj CreditAttribution: rajmataj commented#19, downloading panels and updating the db, worked for me
Comment #82
usaginyunyu CreditAttribution: usaginyunyu commented#43 worked for me
thanks to all
Comment #83
mwadi CreditAttribution: mwadi commented#21 worked for me.
thanks
Comment #84
kmccarthy CreditAttribution: kmccarthy commenteddrush up in 7.25 failed for me as well when the cache tables were not available. Following the reco in #21 (drush dl ctools, drush dl panels, drush up) resolved the issue and worked for me as well.
Thanks bioborg!
Comment #85
nicktr CreditAttribution: nicktr commented#21 worked for me. Thanks!
Comment #86
mohammadyou CreditAttribution: mohammadyou commentedI have same problem here. I want to update the module but I can't.
when I want to patch the module [by copying the patch file into the module directory (7.x-3.3 version) and using cygwin64 command "C:\cygwin64\bin\patch.exe -p1 < C:\xampp\htdocs\rgpars\sites\all\modules\panels\2188277-panelscache-schema-2.patch" or even using p0 instead of p1]
I face with the error that says :
can't find file to patch at input line 5
perhaps you used the wrong -p or --strip option?
the text leading up to this was:
-------------------------------------------------
diff --git a/panels.install b/panels.install
index b913012ab645d1be40e2176f516844910822e6b6..196afd10675f46443751fd2b838df45aea04a0ec 100644
--- a/panels.install
+++ b/panels.install
-------------------------------------------------
file to patch:
I would appreciate if you give me the reason behind this error?
Comment #87
nicxvan CreditAttribution: nicxvan commented#43 worked for me.
Comment #88
asPagurus CreditAttribution: asPagurus commented#71 worked for me, but columns uuid in tables were filled by NULL.
I tried open one of my panels and save it - after that rows have got uuid (for that panel).
And then I took part of code from #7302 (from " // Add the uuid column to the display table." till end) and run it in devel's "run php".
All rows have got uuids.
update
I have tried to apply patch from #70 (after base reverting to panels 3.3). Patch applied, but I recieve the same error when run update.php.
update 2
I've tried to comment 7303 (with patch #70) but nevertheless get:
PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'xxx.cache_panels' doesn't exist: TRUNCATE {cache_panels} ; Array ( ) in cache_clear_all() (line 165 of xxxxx\includes\cache.inc).
update 3
After several attempts I go to solution in #25 - create table by phpMyAdmin.
But even so - columns uuid filled by NULL! though after update.php I have recieved:
Update #7302
Added panels_pane.uuid column. Added panels_display.uuid column. Generated UUIDs for database-based panel displays and panes.
So I copied code from 7302 and run it with devel-php.
Now all is ok - all uuids recieved values...
Comment #90
alesr CreditAttribution: alesr commentedGot this error today when updating panels to 7.x-3.4 in drush and the easy fix was to step back in database "system" table and set "schema_version" for "panels" to 7301 so the updates are executed on "drush updb"
Run this query:
UPDATE system SET schema_version = '7301' WHERE name = 'panels'
;or by using drush sql query:
drush sqlq "UPDATE system SET schema_version = '7301' WHERE name = 'panels';"
Comment #91
millionleaves CreditAttribution: millionleaves commentedNothing here solved my problem. I ended up rolling back to 3.3 and running this query to create the cache.panels, after which the update went through fine:
CREATE TABLE `cache_panels` (
`cid` varchar(255) NOT NULL DEFAULT '' COMMENT 'Primary Key: Unique cache ID.',
`data` longblob COMMENT 'A collection of data to cache.',
`expire` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry should expire, or 0 for never.',
`created` int(11) NOT NULL DEFAULT '0' COMMENT 'A Unix timestamp indicating when the cache entry was created.',
`serialized` smallint(6) NOT NULL DEFAULT '0' COMMENT 'A flag to indicate whether content is serialized (1) or not (0).',
PRIMARY KEY (`cid`),
KEY `expire` (`expire`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Generic cache table for caching things not separated out...';
Comment #92
aangel CreditAttribution: aangel commentedCreating the table per millionleaves' sql got me through my update with no trouble.
Comment #94
tomarnold2 CreditAttribution: tomarnold2 commented#34 worked and was super easy. Thanks!
Comment #95
nategasser CreditAttribution: nategasser commented#25 worked for me. Just used "drush sql-cli" and used the "create table" command there. Thanks!
Comment #96
Taiger CreditAttribution: Taiger commenteddrush dl panels ctools
(overwrite: yes)
then:
drush updatedb
(prompt to create new panels cache table: yes)
then you can:
drush up
Comment #97
entendu CreditAttribution: entendu commentedA note to those looking -- this fix is *not* in the Recommended release yet, so if you're upgrading with Drush it will fail (assuming you're not telling Drush to pull -dev versions).
Comment #98
mnemchuk CreditAttribution: mnemchuk commentedI'm looking at #21 - how is" drush dl ctools, then drush updb" different from "drush up ctools" ?
Comment #99
nicxvan CreditAttribution: nicxvan commentedI think drush bootstraps at a different time depending on how you run the command.
Comment #100
IrfanAhmed CreditAttribution: IrfanAhmed commentedbeen pulling my hair out ever since i updated from panels 7.x-3.3 to 7.x-3.4
Installed Git GUI / Cygwin and tried to install the working patch >> waste of time for novice users like myself.
#25 - rondev - I knew i needed the schema, was looking in all the wrong places. thank you so much for sharing.
copied/pasted/hit go! >> worked >> i still have some hair left. ;)
Comment #101
capfive CreditAttribution: capfive commented#36 fixed this for me, we were getting the issue of the cache_panels table not being able to clear, then we deleted it (stupidly....) once we updated Panels then it obviously needed the table back!!!
Thanks!
Comment #102
bryancasler CreditAttribution: bryancasler commented#36 also worked for me
Comment #103
keypetery CreditAttribution: keypetery commentedI had been having trouble upgrading Panels from D6 to D7.34, using Panels 7.x 3.4, which presumably fixed this error. I tried #34, for example, to no avail.
For anyone running into this problem and landing on this thread at a point in time after my comment here, what worked for me was this:1. Enable only the Panels module first, by itself2. Leave Mini Panels, Panel Nodes and Panels In-Place Editor disabled3. Leave jQuery Update disabled4. Run update.php5. Enable jQuery update6. Run update.php7. If you use them, enable Mini Panels, Panel Nodes and Panels In-Place Editor8. Run update.php[Edit- if you need to revert to a backup, don't forget to uninstall Panels and jQuery update before trying to re-enable the modules above][Update- Lies! I must have uninstalled Panels in 6 before enabling in 7 because when I did all my panels were missing (I had two, so not really a big deal). Started from scratch again and got the same error. Ultimate solution was to disable and uninstall Panels in 6 before upgrading to 7. I am going to try to rebuild those portions of my site using views only, and, if I need to, re-install and re-enable Panels fresh in 7 (and hope my tables have been cleared out from the uninstall in 6) and rebuild any panels if need be (and I think there will be a need, as one of my goals here in upgrading to 7 was for my site to be responsive).
I don't yet trust myself with drush or running queries in my database, and some of the patches in this thread did not really work either. So, for those of us non-coders out here, this was a tough issue. Thankfully, I did not have many panels and could work around this...for now.
After I rebuild my site in 7 (mostly clean-up I've always wanted to do -- only a few things that did not work right, like some bits in my field migration (whay can't it deal with the hidden formatter?), but that's another thread -- it'll be on to try my hand at sub-theming a responsive base theme. Wish me luck...]
Comment #104
Louis Delacretaz CreditAttribution: Louis Delacretaz commentedupgrading from drupal 6 to 7 and getting this error.
From the comments above my fixed was to set schema_version in table system to 7302,
run drush updb which happily creates the table
then set schema_version to 7301 and run drush_update again to pickup on update 7302
Comment #105
pwaterz CreditAttribution: pwaterz commentedEveryone this problem has been confirmed. No need to keep confirming it. Additionally most of these fixes are quick fixes not a case for a permanent fix.
Comment #106
pwaterz CreditAttribution: pwaterz commentedI am still running into this issue. The problem is being caused by panels_save_display in update 7302 which calls panels_clear_cached_content. Trying to think of a better fix.
Comment #107
pwaterz CreditAttribution: pwaterz commentedWhat I have done is reversed the updates. I don't see any issue with doing this.
Comment #108
pwaterz CreditAttribution: pwaterz commentedComment #110
pwaterz CreditAttribution: pwaterz commentedLast patch was bad
Comment #111
DamienMcKennaDoes this fix the problem? Rather than rearranging the updates, which is a bad thing to do, call panels_update_7303() from within panels_update_7302().
Comment #112
pwaterz CreditAttribution: pwaterz commentedThink I got it right this time.
@DamienMcKenna I really am not a fan of calling one update from another. I think the better solution is to change the update numbers. Do you see any issue with doing that?
Comment #114
DamienMcKenna@pwaterz: You should combine the two changes into a single diff, or manually recreate it from scratch, the patch you're uploading is confusing the testbot.
As for the direction to take, lets see what japerry thinks.
Comment #115
pwaterz CreditAttribution: pwaterz commentedSorry, trying to create this patch from an non standard context, let's try again lol.
Comment #116
pwaterz CreditAttribution: pwaterz commentedIgnore that...I need to do this when I am not so busy.
Comment #117
pwaterz CreditAttribution: pwaterz commentedComment #118
DamienMcKennaFYI for this scenario my perspective is that you're more likely to cause problems for sites that were using an older dev release by reordering the updates than you are to fix them in-place.
Comment #119
fsanfili CreditAttribution: fsanfili as a volunteer commentedThis worked for me via drush:
> drush php-eval "module_load_install('panels'); panels_update_7303();"
> drush php-eval "module_load_install('panels'); panels_update_7302();"
> drush cc all
Comment #120
dlz21 CreditAttribution: dlz21 commented#119 worked for me!
@fsanfili Genius never would have thought to do it this way.
Comment #121
DuaelFrHi there!
While working on a live website upgrade, I'm facing the same issue.
My schema version is currently 7301. It looks like Panels needs to use the
panels_simple_cache_clear_cache()
function during the update 7302. As this function now relies on thecache_panels
cache bin it leads to an error.As we are using CI to deploy our work it's really annoying to be locked in that kind of things. The only workaround I found is to create a
hook_update_N()
in our profile/feature, that creates the cache table and that runs beforepanels_update_7302()
according to ahook_update_dependencies()
implementation.I don't know if it is a clean way to fix that issue but I suppose we could add a call at the beginning of the
panels_update_7302()
to create the cache table. Given the content ofpanels_update_7301()
andpanels_update_7300()
it shouldn't be necessary to do the same there.The attached patch is really simple and solves the issue. I'll let you argue about it's quality ;)
Comment #122
DamienMcKennaIt wasn't included in 3.6 so maybe we can get it into 3.7.
Comment #123
DamienMcKennaComment #124
dsnopekThe patch here will conflict with #2786073: "Unknown column 'storage_type'" when updating from v3.3 to v3.6 - one of these will need to be re-rolled after the other is committed.
Comment #126
japerryThis is fixed.. for now. However, we may need to address the core issue that is causing this problem, see #2787123: Re-write panels_update_7302() to not call panels_save_display() for more info.