[ https://issues.apache.org/jira/browse/CASSANDRA-17207?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17468694#comment-17468694 ]
Josh McKenzie commented on CASSANDRA-17207: ------------------------------------------- Gotcha [~shravan001]. I fall back on the: {quote}This is usually because you're on Windows and something else has a handle open to the file; you can't delete files (or hard links, thanks NTFS) on Windows if someone has a handle open to it. {quote} Consider trying a utility like [handle|https://docs.microsoft.com/en-us/sysinternals/downloads/handle] from sysinternals to figure out what else has a handle open to that file that's preventing its deletion. Worst-case it'll be the java process, and thus C*, that have a different handle open to the file and we'll be stuck in the "Cassandra isn't really formally supported on Windows" territory. Since this is CommitLog segment deletion your risk is the drive filling up due to these segments not being appropriately de-allocated and deleted. > The process cannot access the file because it is being used by another > process. > ------------------------------------------------------------------------------- > > Key: CASSANDRA-17207 > URL: https://issues.apache.org/jira/browse/CASSANDRA-17207 > Project: Cassandra > Issue Type: Bug > Reporter: shravansingh > Priority: Normal > > > ERROR [COMMIT-LOG-ALLOCATOR] 2021-12-11 17:02:00,989 > JVMStabilityInspector.java:140 - JVM state determined to be unstable. > Exiting forcefully due to: > org.apache.cassandra.io.FSWriteError: java.nio.file.FileSystemException: > <basePath>\commitlog\CommitLog-6-1636406548826.log: The process cannot access > the file because it is being used by another process. > > at > org.apache.cassandra.io.util.FileUtils.deleteWithConfirm(FileUtils.java:138) > ~[apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.io.util.FileUtils.deleteWithConfirm(FileUtils.java:155) > ~[apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.db.commitlog.CommitLogSegment.discard(CommitLogSegment.java:342) > ~[apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.db.commitlog.CommitLogSegmentManager$2.run(CommitLogSegmentManager.java:379) > ~[apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.db.commitlog.CommitLogSegmentManager$1.runMayThrow(CommitLogSegmentManager.java:156) > ~[apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.utils.WrappedRunnable.run(WrappedRunnable.java:28) > [apache-cassandra-3.0.14.jar:3.0.14] > at > org.apache.cassandra.concurrent.NamedThreadFactory.lambda$threadLocalDeallocator$0(NamedThreadFactory.java:79) > [apache-cassandra-3.0.14.jar:3.0.14] > at java.lang.Thread.run(Unknown Source) ~[na:1.8.0_301] > Caused by: java.nio.file.FileSystemException: > <basePath>\commitlog\CommitLog-6-1636406548826.log: The process cannot access > the file because it is being used by another process. > > at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) > ~[na:1.8.0_301] > at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) > ~[na:1.8.0_301] > at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) > ~[na:1.8.0_301] > at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) > ~[na:1.8.0_301] > at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source) > ~[na:1.8.0_301] > at java.nio.file.Files.delete(Unknown Source) ~[na:1.8.0_301] > at > org.apache.cassandra.io.util.FileUtils.deleteWithConfirm(FileUtils.java:132) > ~[apache-cassandra-3.0.14.jar:3.0.14] > ... 7 common frames omitted > It seems similar to https://issues.apache.org/jira/browse/CASSANDRA-8390, but > it was resolved in 2.2 beta, though I am facing this in version 3.0.14 > I am running this on windows server OS and in cassandra.yaml, > disk_access_mode is set to standard -- This message was sent by Atlassian Jira (v8.20.1#820001) --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org