Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Ripmax2000

macrumors regular
Original poster
Aug 31, 2005
117
3
Hi there, I just need some help from someone who knows about Terminal.

Using a thread I found a few months back ( https://forums.macrumors.com/threads/234583/ ) I have been able to have my Bootcamp disk unmount on startup. However I have just upgraded to Leopard and the drive is back.
I have used the steps provided again, but this time it does not seem to work.
I have pasted what I get when I type diskutil list, does anyone know what I have to type next?

/dev/disk0
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *698.6 Gi disk0
1: EFI 200.0 Mi disk0s1
2: Apple_HFS Macintosh HD 623.0 Gi disk0s2
3: Microsoft Basic Data 75.3 Gi disk0s3


Thanks in advance.
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
The thread you linked to seems to do this the complicated way. The simplest way is to open Script Editor (/Applications/AppleScript), create a new script, and enter
Code:
do shell script "diskutil unmountDisk disk0s3"
Then Save As "application bundle", and add that newly created .app to your startup items in System Preferences.
 

Ripmax2000

macrumors regular
Original poster
Aug 31, 2005
117
3
Just tried it, typed what you wrote, pressed Compile the hit run. It says AppleScript error - Unmount of disk0s3 failed: at least one volume could not be unmounted.

If I right-click on the drive I can eject it though, any ideas?
 

Ripmax2000

macrumors regular
Original poster
Aug 31, 2005
117
3
Yeah, the disk was mounted when I tried that. It's only when that didn't work I tried unmounting it manually.

Is Leopard's Terminal different to Tiger's then? Because the previous way was working fine in Tiger, but when I type it under Leopard it doesn't work.
 

ChrisA

macrumors G5
Jan 5, 2006
12,584
1,699
Redondo Beach, California
The thread you linked to seems to do this the complicated way. The simplest way is to open Script Editor (/Applications/AppleScript), create a new script, and enter
Code:
do shell script "diskutil unmountDisk disk0s3"
Then Save As "application bundle", and add that newly created .app to your startup items in System Preferences.

"Complicated way" I think not. Much simpler to never mount the drive then putting and unmount script in a startup folder. Ok, the method could have been even simpler. Rather then edit the line in /etc/fstab you could isimply comment it out.

I don't have Leopard installed yet. It could be that they've changed the way drives get mounted. Some Linux distributions or Solaris are moving away from simply using /etc/fstab like BSD UNIX has done since the mid part of the last century. Perhaps Leopard is followig this lead.

In any case the simplest thing is to simply remove the drive from the list of what gets automatically mounted at startup.

Until how to do this becomes clear (a few days after Leopard is on the street) why not simply "eject" the drive using the mouse.
 

wildcardd

macrumors 6502a
Mar 26, 2007
526
0
Denver, CO
Don't know if you have figured it out yet, but I think I have.

Leopard doesn't like the unmountDisk command for some reason. Try removing the Disk portion of the command, so only unmount is still there. Like this:
do shell script "diskutil unmount disk0s3"

Weird, but it worked.
 

amsukalski

macrumors newbie
Jul 3, 2007
22
4
I'd be really interested in finding out how to make Leopard not mount my Windows partition in the first place, rather than starting an AppleScript at Login to unmount the drive. Anyone know how to do this? I'd really appreciate it.
 

wildcardd

macrumors 6502a
Mar 26, 2007
526
0
Denver, CO
I'd be really interested in finding out how to make Leopard not mount my Windows partition in the first place, rather than starting an AppleScript at Login to unmount the drive. Anyone know how to do this? I'd really appreciate it.

It would be nice to have that option...but I do not believe it exists. Email Steve..maybe he will consider it ;)
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.