I have a portable drive that I've divided into two partitions: an HFS+ partition for backups and extra storage, and an MSDOS partition so that I can transfer large files or folders to or from Windows boxes. However, I don't need the second partition very often, so I wanted a way to keep it from automatically mounting on my machine when I plug in the drive, while still being able to access it quickly and easily. This turned out to be reasonably easy to do.
First, to prevent the partition from mounting when the disk as a whole mounts, edit/create the fstab system file, which lives down in the root folders at /etc/fstab. Leopard does not seem to have this file by default; it does have a file /etc/fstab.hd, which is not the file you want (though it makes for interesting reading in a Hitchhikers Guide to the Galaxy sort of way). Use a plain-text (i.e. programmer's) text editor such as TextWrangler, Smultron, or Editra, or use a unix tool like vi, and create a file called fstab with the following contents:
LABEL=PARTITION_NAME none msdos rw,noauto
Fields on this line are separated by tabs or spaces, so be careful to escape any spaces in your partition name. The escape character for a space seems to be \040 (octal 40) -- see the example in the man page for fstab.
After searching for a way to change the port that Apple Remote Desktop connects over (so I could use Screen Sharing to reach two machines behind the same NAT router), I found that in Screen Sharing, you can specify a port for a connection, just like you can do in Chicken of the VNC. So, to manage multiple computers:
Port forward a different port to your second, third, etc. machines. That is, port forward external port 5901 to internal port 5900.
Open the ScreenSharing app, in /System » Library » CoreServices.
Enter your Domain Name and Port: mydomain.com:5901, for instance, for the second port.
That's it -- off you go to the specified machine on the described port. I did have issues with Keychain remembering which username and password to use if you have different accounts on each box. I found that setting up domain aliases for each machine solved this -- i.e. server01.mydomain.com:5901, server02.mydomain.com:5902, etc.
Also, a great shortcut to remember is that you can simply type vnc://server01.mydomain.com:5901 into Safari, and it will launch the ScreenSharing app and connect. Likewise, you can bookmark these URLs (which I do to manage my computer list).
Want to read a bunch of related e-mails without switching to Mail.app? You can:
Start by using Spotlight to search for whatever subjects or recipients define the group of messages you want to read, then Show All the results. Next, click on the plus-sign (+) option. You should now see the search criteria Kind Is Any. Click and hold on Any and then choose Other. In the text field, type Mail Message. Now click on Save and give the search whatever name you wish; make sure that Add To Sidebar is checked. Select this saved search in your sidebar, and click on the Cover Flow button at the top of the Finder window.
You may have to enlarge your Finder window to make the messages readable. You could use QuickLook to read them at a larger size.
You can still turn processor nap on and off with the newest version of OS X (10.5.7 as of this writing) and the newest version of the CHUD tools (4.6.2 as of this writing), which are installed with Xcode. You simply have to install the Processor System Preferences pane manually after installing the CHUD tools. I did this on my old dual G5 2.0 GHz to eliminate the CPU's chirping sound. Here's how...
Once C.H.U.D. tools is installed, in Finder go to /Developer » Extras » PreferencePanes. Drag the Processor.prefpane file to
/System » Library » PreferencePanes; the Finder will ask you to authenticate as an administrator to put it there, and then you're done!
You might have to reboot, but the Processor panel will then be available in System Preferences to turn nap on or off. Hope this helps you out!
[robg adds: This was covered originally in this hint, but it seems things have changed -- the Processor System Preferences panel used to be automatically installed.]
I have a Mac mini in my living room hooked up to my TV. I wanted to be able to control the mini from my iMac in my office. Using Screen Sharing built into Leopard, it's a simple click of the mouse to do this. With a little Automator love, I created a simple workflow that turns the Screen Sharing step into a click of an icon in the dock.
However, even with the power efficiency of the 2009 Mac mini, I don't want to leave it on 24/7. After searching through several solutions that used Python and shell scripting (neither of which I know or could make work), I found this nifty Applescript from Mark Muir that I adapted to solve my problem. Here's my modified code:
You'll need to replace the MAC_address property with the MAC address (found in the Networking System Preferences panel) of the machine you'd like to wake. I then wrapped this script in a simple Automator application to make it a true one-click operation. You can read all the details, and download a copy of the Automator application, in this entry in my blog.
[robg adds: I've mirrored the Automator application here on Mac OS X Hints, in case the original post ever goes away. While I haven't tested this one, I'm pretty sure you could replace the full script shown above with a call to the free Wakeonlan perl script, which was described in this older hint.]
Getting ready for work this morning, I walked into my office to find my 2.5 year old daughter mashing on my keyboard with the monitors off. Time out! After a quick check, it looked like no damage had been done. Later though, I tried to launch iCal with Quicksilver, and Quicksilver could not find it.
I looked at my apps folder (which was open apparently when she was mashing the keyboard) and saw that there were three folders with a bunch of jibberish for names. They were apps, but I wasn't sure which ones were which. Enter Time machine!
I tried to restore the whole apps folder, which I knew would take a while, but it told me Applications cannot be restored as it is used by the system. I selected all apps, hit copy, pasted the names into a text file and printed the file, meaning to open Time Machine and go down the list marking things off until I figured out what was missing.
With all of those items selected, I opened Time Machine and selected a backup from early this morning. All of the apps that were the same remained selected, but the ones that were missing -- the renamed ones -- were de-selected. I simply chose the de-selected apps and restored them.
This saved me a bunch of time going down the list and manually comparing the folder in Time Machine to my printed list. Now, off to Home Depot to get a lock for the office door!
I work at an Apple authorized service provider, and many times we need to do a new OS X install, create a (temporary) user account, run all the updates, then delete the user account and get the machine back to "new" condition, i.e. no user accounts and Setup Assistant runs at boot.
The process in 10.4 is pretty well documented, but not so 10.5. Here's a process I've come up with and tested twice. It's not as elegant as just deleting the whole netinfo database, but it still seems to accomplish what I need. Hopefully someone more knowledgeable can improve it!
10.5: For a long time now, I've wished that there was a way in OS X to create a shared folder which disregarded file permissions. In particular, I want all the users to be able to read and write to all the files in the shared folder. This is very useful to me, because I want to have only library for each of iTunes, iPhoto and Aperture, and share those libraries between all the users on my Mac.
I've tried many different things, but they were either too hacky or they just didn't work as advertised. I've come up with the following method which works, is safe, is not a hack, and is easy to implement. The secret to this technique is to use Access Control Lists (ACLs). The procedure is as follows:
Create a new group. The easiest way to do this is through the Accounts pane in System Preferences. Just click on the Plus sign to add a new account and then select Group from the New Account drop-down menu. Call this group anything you want; I called mine friday. Add all the users who you want to participate in the file sharing to your newly-created group.
Do the following steps in Terminal, in Applications -> Utilities:
cd into the /Users/Shared directory: cd /Users/Shared.
Create a new folder where the users will be able to share their files. I created a folder named Friday by typing mkdir Friday.
Change the group of the new folder to your newly-created group: sudo chown admin:friday Friday.
Change the default permissions, if you wish: sudo chmod 770 Friday (this is optional if you're happy with the default permissions).
You now have a folder where all members of the group friday can read, write and delete files, as well as read, write to and create new sub folders. The ACL rule takes precedence over standard UNIX file permissions and is automatically inherited. It's this automatic inheritance that is really important.
Now you are ready to copy your iTunes, Aperture, iPhoto libraries, plus anything else you want to share, into the shared folder. IMPORTANT: You must copy (hold down Option in Finder prior to dragging), and not merely move, items. This is particularly important with bundles, such as the Aperture library bundle for example. Moving items doesn't seem to always inherit the correct ACL rules. Copying ensures that the files are actually created in the shared folder, thereby forcing the ACL rules to be inherited.
[robg adds: This hint has been in the queue for a while -- I had tagged it as something I wanted to try with our shared iMac, then basically forgot about it. My apologies for not publishing it sooner. We've run similar hints for related subjects in the past, but this method seems reasonably simple and easy to understand. I still, of course, haven't tested it yet.]
Activity Viewer shows connection attempt not proceeding
The Console logs can give some clues to the cause. Sometimes this is caused by conflicting or corrupt Junk Mail settings in the com.apple.mail.plist file.
The various values have changed in some version updates to Mac OS X. For some, it's the JunkMailInfoPanelHasBeenShown attribute. For me, it was changing JunkMailBehaviorHasBeenConfigured to false. Also, removing the JunkViewerAttributes setting seemed to be necessary. These can be changed using Property List Editor (installed with XCode developer tools), or it's possible it could be done in the Terminal with these commands:
One of the more distressing Time Machine errors is Error 11. This is a "sticky" error; once it occurs, Time Machine will hit it every time it runs. All you'll see in the standard Time Machine interface is that Time Machine keeps failing. You need to check the system logs to see the Error 11.
The underlying cause of Error 11 appears to be some other error that caused an earlier Time Machine run to terminate without cleaning up after itself. This leaves behind a partial file that indicates to Time Machine that another copy of Time Machine is already producing a backup, so it just stops.
Colin Charles worked out the basic problem and solution, but his description only seems to apply to locally-attached disks. For network-mounted disks, where you've got an additional level of sparsebundle in the way, things are a bit more complicated. Read on for the solution...