This seemed to be due to a bug with how metric names are converted to file 
system paths. os.path.join() is used, but the metric path converts into an 
absolute path (e.g /org/apache/cassandra). This means you end up doing 
something like:

os.path.join('/opt/graphite/storage/whatever', '/org/apache/cassandra/etc')

the metric name gets converted to a path by replacing all dots with slashes. I 
just manually tweaked the Python code to strip any leading dots from the metric 
name as a temporary workaround. 

-Karl



> On Dec 17, 2014, at 11:04 AM, Nigel LEACH <nigel.le...@uk.bnpparibas.com> 
> wrote:
> 
> I'm running Cassandra Cassandra 2.0.11.83 (via DSE 4.6.0), and Graphite 
> 0.9.10. I know a bit about Cassandra, but not much about Graphite.
> 
> Our Graphite server exposes system metrics, and also those from the example 
> python scripts, successfully.
> 
> I can see Cassandra metrics hitting the Graphite server, but in the console 
> log, errors suggest they are attempting to load in to the root file system
> 
> exceptions.IOError: [Errno 2] No such file or directory: 
> '/org/apache/cassandra/metrics/ColumnFamily/system/sstable_activity/WriteTotalLatency/count.wsp'
> 
> Whereas, I think, it should be going to something like this
> 
> /var/lib/carbon/whisper/carbon/agents/org/apache/cassandra/metrics/ColumnFamily/system/sstable_activity/WriteTotalLatency/count.wsp'
> 
> I'm losing the prefix directory path somewhere, but don't know where to 
> configure it.
> 
> On the Cassandra side all I have added is a call to metricsGraphite.yaml, 
> which contains
> 
> graphite:
>  -
>    period: 60
>    timeunit: 'SECONDS'
>    hosts:
>     - host: '10.11.12.13'
>       port: 2003
>    predicate:
>      color: "white"
>      useQualifiedName: true
>      patterns:
>        - "^org.apache.cassandra.metrics.+"
> 
> On the Graphite side I simply have the following in Carbons' 
> storage-schemas.conf file
> 
> [cassandra]
> pattern=cassandra
> retentions = 60:90d
> 
> Any hints to what is going wrong?
> 
> Many Thanks
> Nigel
> 
> 
> ___________________________________________________________
> This e-mail may contain confidential and/or privileged information. If you 
> are not the intended recipient (or have received this e-mail in error) please 
> notify the sender immediately and delete this e-mail. Any unauthorised 
> copying, disclosure or distribution of the material in this e-mail is 
> prohibited.
> 
> Please refer to http://www.bnpparibas.co.uk/en/email-disclaimer/ for 
> additional disclosures.
> 

Reply via email to