Create a keyboard shortcut for fast user switching in Mac OS X

Solution 1:

For 10.6 Snow Leopard, one can easily add a Service using Automator, and then assign any keyboard shortcut using System Preferences. See Fast User Switching/Apple Menu? for details.

Solution 2:

If you are at the CLI, you could have the following alias set to switch quickly:

alias switch='/System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession -suspend'

Solution 3:

I use BetterTouchTool for a lot more than just this but, one of the actions it allows you to do is "Show the Login Screen" (which is different from logging out and leaving you at the login screen). I use it ALL THE TIME to lock my machine when I leave it for extended periods of time… Here's a screenshot:

enter image description here