无法启动cassandra

时间:2014-02-20 05:49:40

标签: nosql cassandra bigdata cassandra-cli

我有使用Cassandra的问题。当我尝试cassandra / bin cassandra -f以下异常时:

INFO 10:50:18,090 reading saved cache /var/lib/cassandra/saved_caches/system-schema_columns-KeyCache-b.db
java.lang.OutOfMemoryError: Requested array size exceeds VM limit
Dumping heap to java_pid7545.hprof ...
Heap dump file created [105901433 bytes in 0.574 secs]
ERROR 10:50:18,668 Exception encountered during startup
java.lang.OutOfMemoryError: Requested array size exceeds VM limit
at org.apache.cassandra.utils.ByteBufferUtil.read(ByteBufferUtil.java:394)
at org.apache.cassandra.utils.ByteBufferUtil.readWithLength(ByteBufferUtil.java:355)
at org.apache.cassandra.service.CacheService$KeyCacheSerializer.deserialize(CacheService.java:352)
at org.apache.cassandra.cache.AutoSavingCache.loadSaved(AutoSavingCache.java:119)
at org.apache.cassandra.db.ColumnFamilyStore.<init>(ColumnFamilyStore.java:267)
at org.apache.cassandra.db.ColumnFamilyStore.createColumnFamilyStore(ColumnFamilyStore.java:411)
at org.apache.cassandra.db.ColumnFamilyStore.createColumnFamilyStore(ColumnFamilyStore.java:383)
at org.apache.cassandra.db.Keyspace.initCf(Keyspace.java:314)
at org.apache.cassandra.db.Keyspace.<init>(Keyspace.java:268)
at org.apache.cassandra.db.Keyspace.open(Keyspace.java:110)
at org.apache.cassandra.db.Keyspace.open(Keyspace.java:88)
at org.apache.cassandra.db.SystemKeyspace.checkHealth(SystemKeyspace.java:474)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:226)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:442)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:485)
java.lang.OutOfMemoryError: Requested array size exceeds VM limit
at org.apache.cassandra.utils.ByteBufferUtil.read(ByteBufferUtil.java:394)
at org.apache.cassandra.utils.ByteBufferUtil.readWithLength(ByteBufferUtil.java:355)
at org.apache.cassandra.service.CacheService$KeyCacheSerializer.deserialize(CacheService.java:352)
at org.apache.cassandra.cache.AutoSavingCache.loadSaved(AutoSavingCache.java:119)
at org.apache.cassandra.db.ColumnFamilyStore.<init>(ColumnFamilyStore.java:267)
at org.apache.cassandra.db.ColumnFamilyStore.createColumnFamilyStore(ColumnFamilyStore.java:411)
at org.apache.cassandra.db.ColumnFamilyStore.createColumnFamilyStore(ColumnFamilyStore.java:383)
at org.apache.cassandra.db.Keyspace.initCf(Keyspace.java:314)
at org.apache.cassandra.db.Keyspace.<init>(Keyspace.java:268)
at org.apache.cassandra.db.Keyspace.open(Keyspace.java:110)
at org.apache.cassandra.db.Keyspace.open(Keyspace.java:88)
at org.apache.cassandra.db.SystemKeyspace.checkHealth(SystemKeyspace.java:474)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:226)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:442)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:485)
Exception encountered during startup: Requested array size exceeds VM limit

Cassandra 2.0 ubuntu 12.04

感谢您提前帮助解决此问题。

2 个答案:

答案 0 :(得分:4)

您需要在cassandra.yaml中减小密钥缓存的大小。但是要重新开始吧:

rm -rf /var/lib/cassandra/saved_caches/*

答案 1 :(得分:0)

增加cassandra环境文件中的VM内存配置

它出现在cassandra的conf文件夹中&#34; conf / cassandra-env.sh&#34;