Ryan McGuire created CASSANDRA-5383:
---------------------------------------

             Summary: Windows 7 deleting/renaming files problem
                 Key: CASSANDRA-5383
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-5383
             Project: Cassandra
          Issue Type: Bug
          Components: Tests
    Affects Versions: 1.2.3
            Reporter: Ryan McGuire


Two unit tests are failing on Windows 7 due to errors in renaming/deleting 
files:


org.apache.cassandra.db.ColumnFamilyStoreTest: 
{code}
    [junit] Testsuite: org.apache.cassandra.db.ColumnFamilyStoreTest
    [junit] Tests run: 27, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 
13.904 sec
    [junit] 
    [junit] ------------- Standard Error -----------------
    [junit] ERROR 13:06:46,058 Unable to delete 
build\test\cassandra\data\Keyspace1\Indexed2\Keyspace1-Indexed2.birthdate_index-ja-1-Data.db
 (it will be removed on server restart; we'll also retry after GC)
    [junit] ERROR 13:06:48,508 Fatal exception in thread 
Thread[NonPeriodicTasks:1,5,main]
    [junit] java.lang.RuntimeException: Tried to hard link to file that does 
not exist 
build\test\cassandra\data\Keyspace1\Standard1\Keyspace1-Standard1-ja-7-Statistics.db
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.createHardLink(FileUtils.java:72)
    [junit]     at 
org.apache.cassandra.io.sstable.SSTableReader.createLinks(SSTableReader.java:1057)
    [junit]     at 
org.apache.cassandra.db.DataTracker$1.run(DataTracker.java:168)
    [junit]     at 
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
    [junit]     at 
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    [junit]     at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    [junit]     at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)
    [junit]     at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:206)
    [junit]     at 
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
    [junit]     at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
    [junit]     at java.lang.Thread.run(Thread.java:662)
    [junit] ------------- ---------------- ---------------
    [junit] Testcase: 
testSliceByNamesCommandOldMetatada(org.apache.cassandra.db.ColumnFamilyStoreTest):
        Caused an ERROR
    [junit] Failed to rename 
build\test\cassandra\data\Keyspace1\Standard1\Keyspace1-Standard1-ja-6-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Standard1\Keyspace1-Standard1-ja-6-Statistics.db
    [junit] java.lang.RuntimeException: Failed to rename 
build\test\cassandra\data\Keyspace1\Standard1\Keyspace1-Standard1-ja-6-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Standard1\Keyspace1-Standard1-ja-6-Statistics.db
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:133)
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:122)
    [junit]     at 
org.apache.cassandra.db.compaction.LeveledManifest.mutateLevel(LeveledManifest.java:575)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStore.loadNewSSTables(ColumnFamilyStore.java:589)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStoreTest.testSliceByNamesCommandOldMetatada(ColumnFamilyStoreTest.java:885)
    [junit] 
    [junit] 
    [junit] Testcase: 
testRemoveUnifinishedCompactionLeftovers(org.apache.cassandra.db.ColumnFamilyStoreTest):
  Caused an ERROR
    [junit] java.io.IOException: Failed to delete 
c:\Users\Ryan\git\cassandra\build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ja-2-Data.db
    [junit] FSWriteError in 
build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ja-2-Data.db
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.deleteWithConfirm(FileUtils.java:112)
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.deleteWithConfirm(FileUtils.java:103)
    [junit]     at 
org.apache.cassandra.io.sstable.SSTable.delete(SSTable.java:139)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStore.removeUnfinishedCompactionLeftovers(ColumnFamilyStore.java:507)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStoreTest.testRemoveUnifinishedCompactionLeftovers(ColumnFamilyStoreTest.java:1246)
    [junit] Caused by: java.io.IOException: Failed to delete 
c:\Users\Ryan\git\cassandra\build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ja-2-Data.db
    [junit] 
    [junit] 
    [junit] Test org.apache.cassandra.db.ColumnFamilyStoreTest FAILED
{code}


org.apache.cassandra.db.ScrubTest:
{code}
    [junit] Testcase: testScrubFile(org.apache.cassandra.db.ScrubTest): Caused 
an ERROR
    [junit] Failed to rename 
build\test\cassandra\data\Keyspace1\Super5\Keyspace1-Super5-f-2-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Super5\Keyspace1-Super5-f-2-Statistics.db
    [junit] java.lang.RuntimeException: Failed to rename 
build\test\cassandra\data\Keyspace1\Super5\Keyspace1-Super5-f-2-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Super5\Keyspace1-Super5-f-2-Statistics.db
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:133)
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:122)
    [junit]     at 
org.apache.cassandra.db.compaction.LeveledManifest.mutateLevel(LeveledManifest.java:575)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStore.loadNewSSTables(ColumnFamilyStore.java:589)
    [junit]     at 
org.apache.cassandra.db.ScrubTest.testScrubFile(ScrubTest.java:94)
    [junit] 
    [junit] 
    [junit] Testcase: testScubOutOfOrder(org.apache.cassandra.db.ScrubTest):    
Caused an ERROR
    [junit] Failed to rename 
build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ia-1-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ia-1-Statistics.db
    [junit] java.lang.RuntimeException: Failed to rename 
build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ia-1-Statistics.db-tmp
 to 
build\test\cassandra\data\Keyspace1\Standard3\Keyspace1-Standard3-ia-1-Statistics.db
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:133)
    [junit]     at 
org.apache.cassandra.io.util.FileUtils.renameWithConfirm(FileUtils.java:122)
    [junit]     at 
org.apache.cassandra.db.compaction.LeveledManifest.mutateLevel(LeveledManifest.java:575)
    [junit]     at 
org.apache.cassandra.db.ColumnFamilyStore.loadNewSSTables(ColumnFamilyStore.java:589)
    [junit]     at 
org.apache.cassandra.db.ScrubTest.testScubOutOfOrder(ScrubTest.java:201)
    [junit] 
    [junit] 
    [junit] Test org.apache.cassandra.db.ScrubTest FAILED
{code}

Reproduced in a Windows 7 VM:
java 1.6.0_43-b01
ant 1.9.0
C* trunk
run 'ant clean test'

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to