Exclude Backup Drive

I just backed up my boot drive, but now when I go to right click on a file to open it in an app I get doubles with the second app pointing to the backed up drive version. Any way to tell Haiku to ignore or exclude the backup drive, or do I just need to compress the backup folder?

There are open tickets in the bug tracker about this. It used to be a lot worse when it showed the full path to the duplicates. There are several options listed in the tickets for #11024 and #8799, including things like unmounting the backup drive when it’s not in use.

Another option that wasn’t listed in the tickets is to remove the BEOS:APP_SIG index from the drive if you don’t need to query it for applications. The BFS index can be recreated later if needed. It would be something like rmindex -d /mydrive BEOS:APP_SIG to delete it. Replace /mydrive with the path to where your actual backup drive is mounted.

To recreate the index:

mkindex -d /mydrive -t string BEOS:APP_SIG
reindex -r BEOS:APP_SIG /mydrive

Also, if you are seeing duplicates of the default Haiku apps or apps that have been installed from packages then you are probably backing up virtual files. These applications are extracted into memory from the hpkg files when Haiku is running but only the hpkg file needs to be backed up. If you just did a simple file copy when you backed up your files then you may have converted these virtual files into real ones.

1 Like

If you don’t have a separate partition to mount/unmount when needed, you can also create an image file that you can mount with a double-click and unmount as usual.

  • Create the image: dd if=/dev/zero of=./testimage bs=1M count=100
    (“count” is the size in MiB as the blocksize (“bs”) is 1 MiB)
  • Do: diskimage register testimage
  • Open DriveSetup, and you’ll see your “testimage” at the bottom.
  • Format it to “BFS” and mount it.

From now on you can mount it with a double-click and unmount when not needed and its apps won’t appear in Tracker’s “Open with…” or any file of it in queries etc.

1 Like