2

I have a removable Firewire drive. It has several partitions, many of which have Mac OS installers on them (I'm a developer/sysadmin, and need to reinstall fairly frequently). However, I also use this disk for backup and storage, so I don't want to install an operating system every time I attach it.

Whenever I attach the drive, Finder pops up a couple windows automatically, offering to install the operating system. I'd prefer that Finder not pop up these windows.

Why do only some of the partitions pop up windows? How can I disable it altogether?

3 Answers 3

2

The folder to open is controlled in a special field in the filesystem header. You can change this entry using the bless command as described in this source.

To review the current settings, use the following command:

bless --info /Volumes/Any Disk/

You can change which folder of the mounted volume is opened in Finder on mount:

sudo bless --folder "/Volumes/Any Disk/" --openfolder "/Volumes/Any Disk/Documentation"

You can reset the information completely as well:

sudo bless --unbless /Volumes/Any Disk/

Note that using these bless commands make the volume unbootable, so be careful if you need this. Of course, they also do not work for volumes with a read-only filesystem/medium, such as a CD/DVD.

2

Apparently it is set in the HFS+ filesystem header. I found some technical detail here, including C source to modify it.

The idea is to set word 2 of the finder info field in the HFS+ volume header. The Mac OS 9/X Finders know to open a window corresponding to the dirID stored in this field.

And there's an ancient app to set it here.

For a tool to read the volume header check out fileXray (non free.) Its manual shows the location of the relevant flag on page 170, it looks like :

# Open folder ID
         finderInfo[2] = 0

If you're also using these disks for backups you probably aren't going to want to mess with the filesystem header, certainly not with the outdated tools above.

1

To prevent a volume from opening in finder when mounted run the bless command like so:

sudo bless -folder "/Volumes/volumename"/

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .