Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8967573
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T17:16:25+00:00 2026-06-15T17:16:25+00:00

TrueVFS is unable to remove the file after unmount and throws the following exception.

  • 0

TrueVFS is unable to remove the file after unmount and throws the following exception.

    java.nio.file.DirectoryNotEmptyException: tar:file:/D:/tmp/0554de32-5a95-4b58-a05d-d12effa68abc.tar!/
    at net.java.truevfs.kernel.impl.ArchiveFileSystem.unlink(ArchiveFileSystem.scala:326)
    at net.java.truevfs.kernel.impl.BasicArchiveController.unlink(BasicArchiveController.scala:222)
    at net.java.truevfs.kernel.impl.DefaultManager$BackController.net$java$truevfs$kernel$impl$CacheController$$super$unlink(DefaultManager.scala:39)
    at net.java.truevfs.kernel.impl.CacheController$class.unlink(CacheController.scala:105)
    at net.java.truevfs.kernel.impl.DefaultManager$BackController.net$java$truevfs$kernel$impl$SyncController$$super$unlink(DefaultManager.scala:39)
    at net.java.truevfs.kernel.impl.SyncController$$anonfun$unlink$1.apply$mcV$sp(SyncController.scala:100)
    at net.java.truevfs.kernel.impl.SyncController$$anonfun$unlink$1.apply(SyncController.scala:98)
    at net.java.truevfs.kernel.impl.SyncController$$anonfun$unlink$1.apply(SyncController.scala:98)
    at net.java.truevfs.kernel.impl.SyncController$class.net$java$truevfs$kernel$impl$SyncController$$apply(SyncController.scala:119)
    at net.java.truevfs.kernel.impl.SyncController$class.unlink(SyncController.scala:98)
    at net.java.truevfs.kernel.impl.DefaultManager$BackController.net$java$truevfs$kernel$impl$LockController$$super$unlink(DefaultManager.scala:39)
    at net.java.truevfs.kernel.impl.LockController$$anonfun$unlink$1.apply$mcV$sp(LockController.scala:92)
    at net.java.truevfs.kernel.impl.LockController$$anonfun$unlink$1.apply(LockController.scala:92)
    at net.java.truevfs.kernel.impl.LockController$$anonfun$unlink$1.apply(LockController.scala:92)
    at net.java.truevfs.kernel.impl.LockingStrategy.apply(LockingStrategy.scala:84)
    at net.java.truevfs.kernel.impl.LockController$class.unlink(LockController.scala:92)
    at net.java.truevfs.kernel.impl.DefaultManager$BackController.unlink(DefaultManager.scala:39)
    at net.java.truevfs.kernel.impl.ArchiveControllerAdapter.unlink(ArchiveControllerAdapter.scala:35)
    at net.java.truevfs.kernel.spec.FsDecoratingController.unlink(FsDecoratingController.java:111)
    at net.java.truevfs.kernel.impl.FalsePositiveArchiveController$$anonfun$1.apply(FalsePositiveArchiveController.scala:132)
    at net.java.truevfs.kernel.impl.FalsePositiveArchiveController$$anonfun$1.apply(FalsePositiveArchiveController.scala:131)
    at net.java.truevfs.kernel.impl.FalsePositiveArchiveController$TryChild$.apply(FalsePositiveArchiveController.scala:195)
    at net.java.truevfs.kernel.impl.FalsePositiveArchiveController.unlink(FalsePositiveArchiveController.scala:143)
    at net.java.truevfs.access.TFile.rm(TFile.java:2216)
    at net.java.truevfs.access.TFile.rm(TFile.java:2195

The tar file is successfully created, so no issues with that.

Here is what I am doing.

  1. Configure the True VFS

    TConfig config = TConfig.current();
    config.setArchiveDetector(new TArchiveDetector(“tar”, new TarDriver()));

  2. Create the tar

  3. Unmount the tar

    TVFS.umount(tarFile);

    convert into bytes and send it.

  4. Remove the file

    tarFile.rm()

I also tried tarFile.rm_r() and plain java.io.File.delete(). But none of them are working.

Can some one please advice me what went wrong? Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T17:16:26+00:00Added an answer on June 15, 2026 at 5:16 pm

    TrueVFS abstracts the TAR file into a virtual directory, so you can only remove it if it’s empty. To recursively remove a (virtual) directory with all its members, just call TFile.rm_r(). You said you tried that, but maybe there was a side effect of your previous attempts, so I suggest to repeat it and see how far it gets you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to add serialization support with XMLEncoder/XMLDecoder to a case class in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.