Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4D77310023 for ; Thu, 28 Nov 2013 11:59:41 +0000 (UTC) Received: (qmail 491 invoked by uid 500); 28 Nov 2013 11:59:39 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 446 invoked by uid 500); 28 Nov 2013 11:59:37 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 423 invoked by uid 99); 28 Nov 2013 11:59:36 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Nov 2013 11:59:36 +0000 Date: Thu, 28 Nov 2013 11:59:36 +0000 (UTC) From: "Andreas Schnitzerling (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (CASSANDRA-6283) Windows 7 data files keept open / can't be deleted after compaction. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CASSANDRA-6283?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13829911#comment-13829911 ] Andreas Schnitzerling edited comment on CASSANDRA-6283 at 11/28/13 11:58 AM: ----------------------------------------------------------------------------- During my importing I got the warnings: {panel:title=system.log} WARN [CompactionExecutor:13] 2013-11-22 03:10:49,864 AutoSavingCache.java (line 277) Failed to delete D:\Programme\cassandra\saved_caches\nieste-nfiles-KeyCache-b.db {panel} and other cache files too. Later the same: {panel:title=system.log} WARN [CompactionExecutor:22] 2013-11-22 07:10:49,896 AutoSavingCache.java (line 277) Failed to delete D:\Programme\cassandra\saved_caches\nieste-nfiles-KeyCache-b.db {panel} was (Author: andie78): During my importing I got the warnings: WARN [CompactionExecutor:13] 2013-11-22 03:10:49,864 AutoSavingCache.java (line 277) Failed to delete D:\Programme\cassandra\saved_caches\nieste-nfiles-KeyCache-b.db and other cache files. Later the same: WARN [CompactionExecutor:22] 2013-11-22 07:10:49,896 AutoSavingCache.java (line 277) Failed to delete D:\Programme\cassandra\saved_caches\nieste-nfiles-KeyCache-b.db > Windows 7 data files keept open / can't be deleted after compaction. > -------------------------------------------------------------------- > > Key: CASSANDRA-6283 > URL: https://issues.apache.org/jira/browse/CASSANDRA-6283 > Project: Cassandra > Issue Type: Bug > Components: Core > Environment: Windows 7 (32) / Java 1.7.0.45 > Reporter: Andreas Schnitzerling > Priority: Critical > Labels: newbie, patch, test > Fix For: 2.0.4 > > Attachments: leakdetect.patch, screenshot-1.jpg, system.log > > > Files cannot be deleted, patch CASSANDRA-5383 (Win7 deleting problem) doesn't help on Win-7 on Cassandra 2.0.2. Even 2.1 Snapshot is not running. The cause is: Opened file handles seem to be lost and not closed properly. Win 7 blames, that another process is still using the file (but its obviously cassandra). Only restart of the server makes the files deleted. But after heavy using (changes) of tables, there are about 24K files in the data folder (instead of 35 after every restart) and Cassandra crashes. I experiminted and I found out, that a finalizer fixes the problem. So after GC the files will be deleted (not optimal, but working fine). It runs now 2 days continously without problem. Possible fix/test: > I wrote the following finalizer at the end of class org.apache.cassandra.io.util.RandomAccessReader: > {code:title=RandomAccessReader.java|borderStyle=solid} > @Override > protected void finalize() throws Throwable { > deallocate(); > super.finalize(); > } > {code} > Can somebody test / develop / patch it? Thx. -- This message was sent by Atlassian JIRA (v6.1#6144)