[ckan-dev] File does not exist: /var/www/api

Mark Wainwright mark.wainwright at okfn.org
Mon Aug 19 10:55:33 UTC 2013


> One other option to check, especially if you don't run CKAN at the
> root url (/), is whether or not the ckan.api_url is set properly. This
> configuration is not automatically set from ckan.site_url (which it should
> be),

Yes, in fact it looks like there is already an issue for this, so it
will hopefully be fixed in the next version:

https://github.com/okfn/ckan/issues/960

Mark



On 17/08/2013, Patrick West <westp at rpi.edu> wrote:
> The issue has been resolved …
>
> http://stackoverflow.com/questions/13971622/error-when-trying-to-upload-a-file-to-ckan-failed-to-get-credentials-for-stora/18282721#18282721
>
> Specifically:
>
> If the older answer doesn't work out, then there is a chance that you don't
> have the One other option to check, especially if you don't run CKAN at the
> root url (/), is whether or not the ckan.api_url is set properly. This
> configuration is not automatically set from ckan.site_url (which it should
> be), and if CKAN is installed on a sub-path, like /ckan/, any API calls that
> are made from Javascript will fail. An additional configuration to try would
> be to set ckan.api_url to be the same as ckan.site_url.
>
> Patirck
>
> On Aug 15, 2013, at 4:49 PM, Patrick West <westp at rpi.edu> wrote:
>
>> So I ran through the link given, and we've got everything set up properly.
>> pairtree and argparse are both installed. The two parameters in the
>> configuration file are set. The data directory exists and is owned by
>> www-data and is writable.
>>
>> When I look at developer resources in Chrome, the following resource is
>> not available:
>>
>> /api/i18n/en
>>
>> it gets a 404 Not Found. That seems to be where the /var/www/api issue is
>> coming from. So not sure what that is or why it would be a problem.
>>
>> When I go to the main page of the site, this is what I get in the error
>> log:
>>
>> [Thu Aug 15 21:34:09 2013] [error] 2013-08-15 21:34:09,340 INFO
>> [ckan.lib.base]  / render time 0.105 seconds
>> [Thu Aug 15 21:34:09 2013] [error] [client 192.168.1.42] File does not
>> exist: /var/www/api, referer: http://udco.tw.rpi.edu/ckan/
>>
>> When I go to the dataset page, I get the following in the error log:
>>
>> [Thu Aug 15 21:34:56 2013] [error] 2013-08-15 21:34:56,618 INFO
>> [ckan.lib.base]  /dataset render time 0.066 seconds
>> [Thu Aug 15 21:34:57 2013] [error] [client 192.168.1.42] File does not
>> exist: /var/www/api, referer: http://udco.tw.rpi.edu/ckan/dataset
>>
>> When I click on Add Dataset, I get the following in the error log:
>>
>> [Thu Aug 15 21:35:14 2013] [error] 2013-08-15 21:35:14,980 INFO
>> [ckan.lib.base]  /dataset/new render time 0.285 seconds
>> [Thu Aug 15 21:35:15 2013] [error] [client 192.168.1.42] File does not
>> exist: /var/www/api, referer: http://udco.tw.rpi.edu/ckan/dataset/new
>>
>> When I click on Next: Add Data, I get the following: more below the stack
>> trace
>>
>
> PARTS REMOVED
>
>>
>> Each time I click through, the Chrome Developer Resource tells me that the
>> following resource is not available:
>>
>> /api/i18n/en
>>
>> it gets a 404 Not Found.
>>
>> I do see where the internal virtual server IP address is showing up:
>> 192.168.1.42
>>
>> It shouldn't be using the IP address, it should be using the URL that we
>> set in site_url.
>>
>> Thanks,
>>
>> Patrick
>>
>> On Aug 15, 2013, at 9:16 AM, Adrià Mercader <adria.mercader at okfn.org>
>> wrote:
>>
>>> Hi Patrick,
>>>
>>> I'm not sure this error message is related to the problems with the
>>> Filestore. Is it part of a bigger stacktrace?
>>> As for the uploads failing, can you check the various options described
>>> in this answer on StackOverflow?
>>>
>>> http://stackoverflow.com/a/13971623/235993
>>>
>>> Adrià
>>>
>>>
>>>
>>> On 14 August 2013 22:39, Patrick West <westp at rpi.edu> wrote:
>>> I keep getting this error in the log files. I don't know if this is
>>> causing the problem of not being able to upload files or not.
>>>
>>> I have followed the instructions at
>>> http://docs.ckan.org/en/ckan-2.0.1/filestore.html for local file storage.
>>> I've created the directory. I've given the correct permissions. But I
>>> still can't upload files.
>>>
>>> So what is this error saying? I don't see anything in the CKAN
>>> documentation.
>>>
>>> -- Patrick West
>>> ---- Tetherless World Constellation
>>> ---- Rensselaer Polytechnic Institute
>>> ---- westp at rpi.edu
>>>
>>>
>>>
>>> _______________________________________________
>>> ckan-dev mailing list
>>> ckan-dev at lists.okfn.org
>>> http://lists.okfn.org/mailman/listinfo/ckan-dev
>>> Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev
>>>
>>>
>>> _______________________________________________
>>> ckan-dev mailing list
>>> ckan-dev at lists.okfn.org
>>> http://lists.okfn.org/mailman/listinfo/ckan-dev
>>> Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev
>>
>
>


-- 
Business development and user engagement manager
The Open Knowledge Foundation
Empowering through Open Knowledge
http://okfn.org/  |  @okfn  |  http://ckan.org  |  @CKANproject




More information about the ckan-dev mailing list