[ckan-dev] DataStorer and preview troubleshooting

Jim Craner jim at codeforamerica.org
Mon Jul 30 17:54:09 UTC 2012


Hi David,

Thanks for the quick reply!

CKAN lives at data.cityofsantacruz.com -- it's a "standard" Nginx on
80 / Apache on 8080 install per the "Install from Source"
documentation and post-install deployment docs.  I have no
customizations to the Apache script or Nginx script that I got from
the docs.

I mentioned in an email earlier that I'm seeing ElasticSearch log
references to "ckan-data.cityofsantacruz.com" but I don't see *any*
reference to the string "ckan-data" in any of my config or source
files so I have no idea where that's coming from.  Right now I'm
grepping the entire file system for reference to that string in case I
overlooked something.

Any suggestions for figuring out if this is a problem with ES or with
Apache or Nginx or something else altogether?

Thanks again!
Jim

On Mon, Jul 30, 2012 at 10:44 AM, David Raznick <kindly at gmail.com> wrote:
> Hello Jim
>
> The error looks like it is to do with the datastorer.  It not guessing
> the url of ckan correctly and when it trying to report back to ckan it
> is falling over.
>
> Is the instance you have under some suburl or not root path? i.e ckan
> lives under http://domain.com/ckan
>
> The datastorer may think that ckan is at http://domain.com and that
> causes the error.  We have fixed this before but it is very dependant
> on what the webserver sends to ckan in order for it know its hostname.
>
> Thanks
>
> David
>
>
>
> On Mon, Jul 30, 2012 at 6:04 PM, Jim Craner <jim at codeforamerica.org> wrote:
>> I did some more testing based on past troubleshooting advice from this list...
>>
>> So I can upload data via the API:
>>
>> prompt$ curl -XPUT http://localhost/api/data/<resource_id>/1 -d
>> '{"test":"data"}' -H 'Authorization: <API key of my admin user>'
>>
>> successfully replaces the CSV that was in that resource with the
>> "test, data" table and preview works, API calls against it work, etc.
>>
>> So it seems that it's just when files are uploaded via the web
>> interface that no DataStore is being created.  My celery log is still
>> showing the "AttributeError: 'NoneType' object has no attribute
>> 'read'" error referenced in the pastebin I made
>> (http://pastebin.com/jtXUbvJx) but I can't tell if this is the
>> archiver or datastorer process or something else altogether.
>>
>> Any suggestions greatly appreciated!
>> Thanks,
>> Jim
>>
>>
>> On Sun, Jul 29, 2012 at 9:19 PM, Jim Craner <jim at codeforamerica.org> wrote:
>>> <premature enter-hitting>
>>>
>>> Thanks for any advice you can suggest!
>>> -Jim
>>>
>>> On Sun, Jul 29, 2012 at 9:19 PM, Jim Craner <jim at codeforamerica.org> wrote:
>>>> Hi,
>>>>
>>>> I successfully had CKAN 1.7.1 running, including DataStorer storing
>>>> CSV resources and the ability to preview them with Recline.
>>>>
>>>> I logged in today and resources that previously displayed previews
>>>> properly in Recline now show the Dreaded Pink Fail Bar of Doom.
>>>>
>>>> I then tried to upload some new test CSV resources, including ones I'd
>>>> successfully uploaded and previewed before, and got the same thing.  I
>>>> checked the celeryd.log and it was yielding the following:
>>>>
>>>> [2012-07-29 21:08:44,507: INFO/MainProcess] Got task from broker:
>>>> datastorer.upload[814f9861-a34c-4b4c-993f-f7c8358cd9b4]
>>>> [2012-07-29 21:10:04,677: ERROR/MainProcess] Task
>>>> datastorer.upload[814f9861-a34c-4b4c-993f-f7c8358cd9b4] raised
>>>> exception: AttributeError("'NoneType' object has no attribute
>>>> 'read'",)
>>>>
>>>> I pasted the entire traceback from the celeryd.log here:
>>>> http://pastebin.com/jtXUbvJx
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> -----
>>>> Jim Craner, 2012 Fellow
>>>> Code for America
>>>> jim at codeforamerica.org
>>>> (+1) 773-809-4546
>>>> http://codeforamerica.org
>>>
>>>
>>>
>>> --
>>> -----
>>> Jim Craner, 2012 Fellow
>>> Code for America
>>> jim at codeforamerica.org
>>> (+1) 773-809-4546
>>> http://codeforamerica.org
>>
>>
>>
>> --
>> -----
>> Jim Craner, 2012 Fellow
>> Code for America
>> jim at codeforamerica.org
>> (+1) 773-809-4546
>> http://codeforamerica.org
>>
>> _______________________________________________
>> ckan-dev mailing list
>> ckan-dev at lists.okfn.org
>> http://lists.okfn.org/mailman/listinfo/ckan-dev
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-dev



-- 
-----
Jim Craner, 2012 Fellow
Code for America
jim at codeforamerica.org
(+1) 773-809-4546
http://codeforamerica.org




More information about the ckan-dev mailing list