Right, I am using the old config since we don't config example in the
apache repository. I have attached the config that I am using. Thanks.

On Wed, Mar 11, 2009 at 2:51 PM, Avinash Lakshman <[email protected]>wrote:

>  May be you need to have the new config format? I am not sure. Send me
> your config file.
>
>
>
> Avinash
>
>
>  ------------------------------
>
> *From:* Jiansheng Huang [mailto:[email protected]]
> *Sent:* Wednesday, March 11, 2009 2:50 PM
> *To:* [email protected]; Avinash Lakshman; Prashant
> Malik
> *Cc:* [email protected]
> *Subject:* NPE in apache cassandra
>
>
>
> Hi folks, I checked out the new code from apache and compiled it. When I
> start up the server with a clean installation base (i.e., without using any
> system/user data from previous installation),
> I got the following.
>
> UNCAUGHT EXCEPTION IN main()
> java.lang.NullPointerException
>     at java.io.DataOutputStream.writeUTF(DataOutputStream.java:347)
>     at java.io.DataOutputStream.writeUTF(DataOutputStream.java:323)
>     at
> org.apache.cassandra.db.Table$TableMetadataSerializer.serialize(Table.java:254)
>     at
> org.apache.cassandra.db.Table$TableMetadataSerializer.serialize(Table.java:244)
>     at org.apache.cassandra.db.Table$TableMetadata.apply(Table.java:209)
>     at org.apache.cassandra.db.DBManager.storeMetadata(DBManager.java:150)
>     at org.apache.cassandra.db.DBManager.<init>(DBManager.java:102)
>     at org.apache.cassandra.db.DBManager.instance(DBManager.java:61)
>     at
> org.apache.cassandra.service.StorageService.start(StorageService.java:465)
>     at
> org.apache.cassandra.service.CassandraServer.start(CassandraServer.java:110)
>     at
> org.apache.cassandra.service.CassandraServer.main(CassandraServer.java:1078)
> Disconnected from the target VM, address: '127.0.0.1:45693', transport:
> 'socket'
>
> I did some debugging and found that in the following code, the first entry
> in cfNames is always null. Is it safe to say that if cfName is null, then we
> don't want to do the writings?
>
> public void serialize(TableMetadata tmetadata, DataOutputStream dos) throws
> IOException
>         {
>             int size = tmetadata.cfIdMap_.size();
>             dos.writeInt(size);
>             Set<String> cfNames = tmetadata.cfIdMap_.keySet();
>
>             for ( String cfName : cfNames )
>             {
>                 dos.writeUTF(cfName);
>                 dos.writeInt( tmetadata.cfIdMap_.get(cfName).intValue() );
>                 dos.writeUTF(tmetadata.getColumnFamilyType(cfName));
>             }
>         }
>
> A related question I have is what's the procedure for us to check in code?
> I have made some changes for adding latency counters in the server and
> exposing them through http. Would be good to check in the changes and minor
> fixes so that I don't have to risk of losing them ...
>
> Thanks,
>
> Jiansheng
>
>
<Storage>
   <ClusterName>Test</ClusterName>
   <RackAware>false</RackAware>
   <MulticastChannel>230.0.0.1</MulticastChannel>
   <ReplicationFactor>6</ReplicationFactor>
   <ZookeeperAddress></ZookeeperAddress>
   <RpcTimeoutInMillis>5000</RpcTimeoutInMillis>
   <StoragePort>7000</StoragePort>
   <ControlPort>7001</ControlPort>
   <HttpPort>7002</HttpPort>
   <ThriftPort>9160</ThriftPort>
   <ColumnIndexSizeInKB>256</ColumnIndexSizeInKB>
   <MetadataDirectory>/var/cassandra/system</MetadataDirectory>
   <CommitLogDirectory>/var/cassandra/commitlog</CommitLogDirectory>
   <CommitLogRotationThresholdInMB>128</CommitLogRotationThresholdInMB>
   <GangliaServers>
     <GangliaServer>127.0.0.1:12000</GangliaServer>
   </GangliaServers>
   <DataFileDirectories>
     <DataFileDirectory>/var/cassandra/data</DataFileDirectory>
   </DataFileDirectories>
   <BootstrapFileDirectory>/var/cassandra/bootstrap</BootstrapFileDirectory>
   <StagingFileDirectory>/var/cassandra/staging</StagingFileDirectory>
   <CommitLogFastSync>false</CommitLogFastSync>
   <Tables>
      <Table Name = "RFI">
   	    <ColumnFamily>User</ColumnFamily>
   	    <ColumnFamily>Page</ColumnFamily>
   	    <ColumnFamily>Ad</ColumnFamily>
   	    <ColumnFamily>CF1</ColumnFamily>
   	    <ColumnFamily>CF2</ColumnFamily>
   	    <ColumnFamily>CF3</ColumnFamily>
   	    <ColumnFamily ColumnType="Super">IPBasedData</ColumnFamily>
   	    <ColumnFamily ColumnType="Super">SuperCF1</ColumnFamily>
   	    <ColumnFamily ColumnType="Super">SuperCF2</ColumnFamily>
   	    <ColumnFamily ColumnType="Super">SuperCF3</ColumnFamily>
      </Table>
   </Tables>
   <Seeds>
     <!-- Add names of hosts that are deemed contact points -->
     <!-- Seed>127.0.0.1</Seed -->
   </Seeds>
</Storage>

Reply via email to