On 4/1/2014 1:23 AM, Gurfan wrote: > Hi, > > As Transaction log(Tlog) play important role while restarting the SolrCloud > cluster, we are trying to decrease the size. Many of the posts on net which > we find describing that - > "decreasing the AutoCommit and increasing autoSoftCommit would generate the > small size of transaction log".
Transaction log size is purely controlled by hard commits (autoCommit), soft commits have no influence at all. > To test the aforesaid statement we executed some Run: > > Document Size: ~2KB. > > 1st Run: > > AutoCommit: 30 Sec > autoSoftCommit: 20 Sec > openSearcher: false > Index size: 4.7 GB > Transaction log: > Master: 740KB > Slave: 86 MB > > 2nd Run: > > AutoCommit: 20 Sec > autoSoftCommit: 30 Sec > openSearcher: false > Index size: 4.7 GB > Transaction log: > Master: 740KB > Slave: 202 MB When you say master and slave, are you using old-style replication, or are you using SolrCloud? With old-style replication, the slave should not be indexing *anything* -- the index itself is copied from the master to the slave. I don't know whether transaction logs are copied by replication, but I suspect that they are not. If they are not, the slave should not have ANY transaction logs. If they are, the slave should be identical. You should be OK to delete the slave transaction logs. It's entirely possible that there is a bug. With SolrCloud, master and slave have no meaning -- each shard has replicas, and one of the replicas is elected to be leader. An election can happen at any time in response to cluster events, and a different replica might be elected leader. Although replication is required for SolrCloud operation, it is not used except at node startup and if something goes wrong that requires index recovery. Each node does its own indexing and will manage its own transaction logs according to how frequently you do a hard commit. Thanks, Shawn