Need some help installing CCK on 6.2. After enabling even just the Content module of CCK, I get Page Not Found errors on every page of my site. The only way I can fix this is to set the module status to 0 in the DB and run update.php to rebuild and get access again. Any idea why this is happening?

Comments

Dave Meyer’s picture

I had the same thing just happen. Glad to see I'm not alone. There was an error reported in includes/content.views

merphq’s picture

Yeah, I've seen a few posts about problems with CCK and Views so I decided to try disabling Views and then enabling Content alone... Same thing! I don't think the two issues are dependent, but they seem to be related to the same underlying glitch somehow.

karens’s picture

Status: Active » Postponed (maintainer needs more info)

This is the core bug reported at http://drupal.org/node/262892 which will be fixed when D6.3 is released, but is currently only in the D6 -dev release.

This is reported against 6.x-2.x-dev. It's hard to know exactly what version you were using, but we just released a new rc2 release today that has the latest fixes (including some fixes to content.views.inc).

If you have backups of your previous database, the best path would be to go back to your previous database. Make sure you have the new rc2 release of CCK and also today's new rc release of Views and the latest -dev version of core, then try the update again.

merphq’s picture

Nope - still same issue with rc2 release. My core version is the most recent since I had to reinstall everything before I eventually came across the DB + update "fix" that restores Drupal after the faulty module install.

It's pretty disappointing that one of the main features/attractions of Drupal doesn't even work with the current version! Gotta love open source. Is there at least a KNOWN working combo (6.x + CCK)? I'd like to be able to at least play around in development until it's "stable".

yched’s picture

@merphq - Sorry to insist, just want to be extra clear so that we can rule that point out : your drupal *core* code has to be the one in http://ftp.drupal.org/files/projects/drupal-6.x-dev.tar.gz (or from latest CVS DRUPAL-6 branch), not the current official 6.2 release.

karens’s picture

I added a note to the CCK project page and on the new release announcement warning that you should use the development version of core. The note has a link to the file in #5.

CCK is working fine for all of us (using the development version of core).

karens’s picture

Also, once you get the 'Page not found error', upgrading the code won't fix anything. You have to go back to your backup and start over.

yched’s picture

(update : fixed the link on cck project page to point to core 6-dev, not cck-rc2 :-)

Laurentvw’s picture

Nope. I retried. Just installed drupal 6 dev version (fresh install). I enabled all the modules I used previously (except CCK), it worked fine. Then I checked the CCK (dev) module, submitted, and the page got blank. Frontpage is now blank, main admin page blank... everything.

yched’s picture

@Laurentvw : 'blank screen' can mean anything , unfortunately - most frequent case being insufficient memory. Please check http://drupal.org/node/31819.
Other than that, you need to check your PHP error logs or enable on-screen error display so that you can provide the actual error message.

Laurentvw’s picture

I've got sufficient memory. I've enabled on screen errors and here's what I got:

Fatal error: Class views_handler_field_content: Cannot inherit from undefined class views_handler_field_node in /var/www/vhosts/mysite.com/httpdocs/drupal2/modules/cck/includes/content.views.inc on line 255

Thanks.

yched’s picture

OK, then please use http://drupal.org/node/277968 to followup

merphq’s picture

Still no luck after downloading the dev core and the rc2 of CCK. To simplify, here are the exact steps and parameters that I'm using:

- Installed Drupal -dev (drupal-6.x-dev.tar) to localhost/drupaldev - (could localhost have anything to do with this?)
- Added CCK package (cck-6.x-2.0-rc2.tar) to C:\apache2triad\htdocs\drupaldev\sites\all\Modules (note: I've read http://drupal.org/node/277968 as well and the correct folder does not prevent the problem)
- Enabled only Content module from Drupal module admin
- Get WSOD

(My apologies, I should have clarified in earlier posts that I'm now getting WSOD and not PNF. Though in my C:\windows\php.ini file I've set "memory_limit = 20")

So, after reverting (content module status=0 in DB, then update.php), I then tried:

- Adding Views (views-6.x-2.0-rc1.tar) module
- Enabled all 3 views modules
- Enabled Content (also tried enabling all CCK components at once)
- Get WSOD

Any more ideas?

merlinofchaos’s picture

merphq: Your problem is clearly different, please don't pollute this issue; all you're doing is confusing people.

merlinofchaos’s picture

merphq: Scratch that, I was reading a different issue. Sorry!

merlinofchaos’s picture

merphq: I will say a memory limit of 20 is probably insufficient. Testing has determined that Drupal core + Views needs 24megs, and some people report 32 megs being necessary.

merphq’s picture

Hmm, well my issue isn't with Views really. I have no problem enabling and using it. It's the CCK aspect that's giving me difficulties. And still no luck after upping to 32 MB.

So, two questions:

- Do I need Views to use CCK in the first place? I can't recall anything indicating dependency. (not that it matters, I've got views working fine but CCK still won't play nice)
- Is my syntax correct in my php.ini file " memory_limit=32 " (it was originally set to " memory_limit=8M ")

karens’s picture

merphq:

1) No you don't need Views to use CCK (and you don't need CCK to use Views) they just do lots of great things when you use them together.

2) You syntax is *not* correct, it is 32M, not 32. And once you change the .ini file you need to restart your PHP server to allow PHP to notice the change.

CCK also takes up memory, but I don't know how much. I would think 32M would be sufficient for both CCK and Views, but it depends on what else you're using (and whether you get it enabled correctly). The php.ini file may or may not be the right place, you may need to contact your host and ask the best way in your system to increase memory. You can see how much you actually have by going to admin/reports/status.

merphq’s picture

Okay, I've set "memory_limit=32M" correctly in my php.ini file but still getting the WSOD after enabling Content module (restarted Apache before attempting - actually, I restarted the entire machine so all processes would be relaunched). At this point I don't have any other contrib modules installed, just the core modules that are enabled after a clean install. I'm working on a local development machine so my php.ini file is currently located in C:\windows. Where can I check/change the path? Would the rest of the system still function even if this wasn't the correct location?

Thanks for all of your help with this.

merphq’s picture

AHA! When I run a status report I don't see anything listed next to PHP memory limit. So, how can I check the path that Drupal is using for PHP?

karens’s picture

Do a search for php.ini. I'm betting you have several in various places. Try them all (restarting Apache each time) until you find the one that works.

merphq’s picture

Only php.ini file is in C:\WINDOWS. Just tried to enable Content again and then checked my PHP error log:

[03-Jul-2008 12:33:01] PHP Fatal error: Cannot redeclare content_help() (previously declared in C:\apache2triad\htdocs\drupaldev\sites\all\Modules\cck\content.module:22) in C:\apache2triad\htdocs\drupaldev\sites\all\modules\cck\content.module on line 50

Actually, I see several instances of the same error, each due to another (failed) attempt to enable Content I presume. In fact, this is the only error that appears in the php error log since yesterday when I started having trouble installing the module.
Does this help at all?

yched’s picture

Status: Postponed (maintainer needs more info) » Fixed

Obviously you have two copies of cck, which PHP is bound not to like : one in sites\all\modules, the other in sites\all\Modules
'Modules' (capital M) is not good.

merphq’s picture

Unbelievable!!! I can't believe I missed that. The Drupal install doesn't create the modules directory in \sites\all so I had to create it myself, and by force of habit (clearly a BAD habit) I created Modules instead of modules. Sheesh, I'm an idiot.

THANK YOU!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.