Hi Gavin,

How have you configured your `storage_schedule`? It's possible that
the job for calculating storage statistics hasn't occurred (or
finished) yet.

You can manually trigger storage usage calculation by invoking the
following command:

sudo riak-cs-storage batch

>From there, you can retrieve statistics from the `usage` bucket with `s3cmd`:

s3cmd get s3://riak-cs/usage/<ACCESS_KEY>.abj.20130501T000000Z.20130531T000000Z

Also, here is a script I wrote up to access usage and storage
statistics with `s3cmd`:

https://gist.github.com/hectcastro/126b5657f228096775c6

--
Hector


On Mon, Dec 9, 2013 at 1:25 AM, Gavin Huang <[email protected]> wrote:
> BTW, what I can see from the riak-cs log is:
>
> 2013-12-09 22:04:40.836 [error] <0.17758.42> No WM route: 'GET'
> /riak-cs/usage/GRRYE2NHIXTNPFP89NMJ/abj/20131210T000000Z/20131210T160000Z
> {5,{"x-amz-date",{"X-Amz-Date","Mon, 09 Dec 2013 06:10:17
> +0000"},{"authorization",{'Authorization',"AWS
> MESG2VCANJVU7XTX-9YC:K7v4mFdvvAZ8a5LJHqfc/TZLy/w="},{"accept-encoding",{'Accept-Encoding',"identity"},nil,nil},{"host",{'Host',"riak-cs.s3.amazonaws.com:8080"},nil,nil}},{"x-rcs-rewrite-path",{"x-rcs-rewrite-path","/riak-cs/usage/GRRYE2NHIXTNPFP89NMJ/abj/20131210T000000Z/20131210T160000Z"},nil,nil}}}
>
>
>
> On Mon, Dec 9, 2013 at 10:50 AM, Gavin Huang <[email protected]> wrote:
>>
>> Hi,
>> I'm trying to get the usage and access statistics from Riak-CS.
>> I configured "storage_schedule"(restarted riak-cs), I manually start
>> riak-cs-storage (it takes a while first time, but getting more quick
>> afterwards).
>>
>> I tried to access the storage via s3cmd:
>> s3cmd get s3://riak-cs/usage/[adminkey]
>> s3cmd get s3://riak-cs/usage/[adminkey]/aj
>> s3cmd get
>> s3://riak-cs/usage/[adminkey]/abj/20131201T140000Z/20131210T160000Z
>>
>> all request get the response of:
>> ERROR: S3 error: 404 (Object Not Found):
>>
>> is there anything I missed?
>>
>> Thanks.
>> Gavin
>
>
>
> _______________________________________________
> riak-users mailing list
> [email protected]
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>

_______________________________________________
riak-users mailing list
[email protected]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to