This document summarizes a presentation on helping Windows administrators survive using OS X. It discusses key differences between OS X and Windows like the file structure, permissions, preferences, security features like Gatekeeper and FileVault, and the launchd process management system. It provides examples of commands, shortcuts, and navigating the OS X interface. The presentation concludes with a discussion on differences in managing Macs with KACE and questions about Netbooting and software distribution.
1. Dell World User Forum
UFIL522: Surviving OS X as a Windows Admin
Jeffrey J Hoover, Senior Trainer
Michael Klocek, Learning Development
Dell World
User Forum
2. Dell World User Forum
Agenda
• Comparing OSX & Windows
• Permissions
• Preferences
• Security
• Launchd
5. Dell World User Forum
Menus
• At the top of the screen
• Varies by Application
• Standards
6. Dell World User Forum
Dock
• Shows Running or saved items
• Configurable
7. Dell World User Forum
Navigation
• Program Switching
– Command-Tab
– Click on Dock Icon
• Program Launching
– Dock
– Launchpad
– Spotlight
– Finder double-click
• Finding Files
– Finder Navigation
– Finder Search/Spotlight
– /usr/bin/find
› $ find /Library -name "AMP*" -print
8. Dell World User Forum
General Concepts
• It’s like Windows, only different
– Some people say very different
– Others say not so much
• Windows is a GUI with a command line option
• OS X is a GUI running on Unix
• K1000 needs command lines
9. Dell World User Forum
Comparisons
OS X Windows
Terminal Command Prompt
Disk Image (DMG) ISO
Command Key Control Key
Command-C Control-C
Finder Windows Explorer
Safari IE
Firefox Firefox
System Preferences Control Panels
.APP .EXE
Menu Start
OS X Windows
ls (UNIX command) dir (DOS command)
/Volumes/ C:
/
daemon Service
Plist files for configuration Registry files for configuration
/System C:Windows
Dock Task Bar
App wide Menus Window Menus
Get Info Properties
Folders (Finder) Directories
10. Dell World User Forum
Example Keyboard Shortcuts (Boot)
Option Display all bootable volumes (Startup Manager)
Shift Perform a Safe Boot (start up in Safe Mode)
Left Shift Prevent automatic login
C Start from bootable media (DVD, CD, USB thumb drive, and so forth)
T Start in FireWire target disk mode
N Start from NetBoot server
X Force Mac OS X startup (if non-Mac OS X startup volumes are present)
D Use Apple Hardware Test
Command-R Use Recovery (OS X Lion or later)
Command-V Start in Verbose Mode
Command-S Start in Single User Mode
Command-Option-P-R Reset NVRAM / parameter RAM
Hold down the Media Eject (⏏) key or
F12 key, or mouse or trackpad button
Eject removable discs
11. Dell World User Forum
Keyboard Shortcuts
Key Name Note
⌘ Command key Could also have (Apple Logo)
^ Control key
⌥ Option key Could also have ‘alt’
⇧ Shift key
⇪ Caps Lock
fn Function key
⏏ Eject key Makes the ‘F’ keys dual purpose
13. Dell World User Forum
Deeper into OS X
• File System
• Terminal
• Library Directories
• Permissions and ownership
• Preferences & Property Lists (plists)
• Security
14. Dell World User Forum
File System
• Command line is essential for KACE
• Unix
– FreeBSD/Darwin distribution
– Case Sensitive
– Forward Slashes
15. Dell World User Forum
Structure
File structure starts at the
Root of the Drive. Not much
is visible in the GUI, but the
command line reveals more.
16. Dell World User Forum
Terminal
• Command line is the way to go with the K1000
• Shell
– Think: CMD or PowerShell
– OS X supports: bash (default), csh, ksh, sh, tsch, & zsh
• Manual Pages ‘/usr/bin/man’
– e.g., ‘man ls’ will show you the manual for the ls command
• Navigation is similar, but listing the directory contents is different
– cd = change directory.
– $ cd /Library will take you to the /Library directory
– ls = list. Similar to dir command.
– ifconfig = ipconfig
17. Dell World User Forum
Bash Tricks & Survival
• !$ - Use the last ‘noun’ in history.
– $ ls /bin #shows the list of the /bin directory
– $ cd !$ #Changes to the /bin directory
• ~ - shortcut to current user’s home directory
– cd ~Library #changes to the local user’s /Library
• . - current directory
• .. – parent directory
17
18. Dell World User Forum
Terminal Tricks (bash)
. Current directory $ open .
.. Parent directory $ cd ..
!7 Rerun 7th command in history $ !7
!! Repeat the last command $ sudo !!
!$ Use the last noun used $
History 10 Show the last 10 commands
!grep Run the last command that
started with ‘grep’
$ !grep
grep 389/etc/services
<tab> Autocomplete /Lib<tab>
<arrow up> scroll through history
./ Execute something in the current
directory
$ ./AMPTools set HOST=kbox.example.com
19. Dell World User Forum
Terminal Tricks (bash)
dirs show directory stack $ dirs
pushd Push a directory into stack $ pushd ~/Library/Preferences
popd cd to the next dir in stack $ popd
grep Search for something $ grep 389 /etc/services
| pipe – execute another
command on the output
$ ps –ax | grep AMP
^x^y Replaces x with y in previous
command
$ cat fiel
$ ^fiel^file
> Redirect output $ cat etc/hosts > /tmp/hosts.txt
; Separate two commands $ uptime > uptime.txt ; cat uptime.txt
sudo Run command with Admin
Privileges
$ sudo make me a sandwich
21. Dell World User Forum
Library
• Library directories are the home to:
– Configuration files
– Fonts
– Plug-ins
– Preferences
– Scripts
– …and more.
• Several different Library directories on the system:
– System
– Network
– Local
– User
22. Dell World User Forum
Library
• /Library
– Local Library for application, developer, and all user use
– Typically the best place for Fonts, Plug-ins, and other resources
needed by all users.
– Has Application Support and Preferences
– Non dynamic path
• ~/Library
– User Library
– Dynamic Path
– Usually used for user preferences and other user items
23. Dell World User Forum
/Network/Library
• Rarely used, requires Directory binding
• Usually the last place something is looked for
24. Dell World User Forum
~/ (User’s Home)
• User’s files
• Default folder structure
• ~/Library is hidden by
default
• Mail
• Preferences
• User Application Settings
(Application Support)
27. Dell World User Forum
Permissions
• UNIX File Permisions
– /bin/chmod to Change
› chmod 775 ~/Documents
› chmod +rw ~/Documents
28. Dell World User Forum
Ownership
• UNIX ownership Rules
– Owner and Group
• /bin/chown to Change
– chown root:wheel /Library/LaunchAgents/foobar.plist
36. Dell World User Forum
Preferences
• Behind the GUI
• PLIST (Property List) files are like Registry Keys
– Not mandatory, but wide-spread
• Checks in ~/Library first, then /Library
• ~/Library/Preferences/com.apple.finder.plist
– Contains information about windows, Desktop, icons, views, etc.
37. Dell World User Forum
PropertyList files
• XML or binary based
• Change or view with
– /usr/bin/defaults
– /usr/libexec/PlistBuddy
– Text Editor
– XCode
38. Dell World User Forum
/usr/bin/defaults
• defaults read – list values
– $defaults read com.apple.finder CreateDesktop
– 1
• defaults write – change value
– $defaults write com.apple.finder CreateDesktop -bool false
• May need to restart effected process
– $killall Finder
› This works because the finder is monitored by launchd and always kept running
39. Dell World User Forum
/usr/bin/defaults
• Don’t use defaults if there is a command write to do it…
• Return System Name
1. PlistBuddy -c 'Print System:System:ComputerName'
/Library/Preferences/SystemConfiguration/preferences.plist
2. system_profiler SPSoftwareDataType |grep Computer|awk '{ print $3 }’
3. defaults read /Library/Preferences/SystemConfiguration/preferences.plist System
|grep "ComputerName =" |awk '{ print $3 }'|sed s/"//g | cut -f 1 -d';’
4. scutil --get ComputerName
42. Dell World User Forum
Security
• Standard Sysadmin procedures and policies apply
• Gatekeeper (authorized Apps)
• FileVault (Disk Encryption)
• Certs and Keychains
43. Dell World User Forum
Security – Standards
• Create a Separate Administrator Account
System Preferences > Users & Groups
• Disable Automatic Login
System Preferences > Users & Groups (Login Options)
• Require Password Lock when Sleeping
System Preferences > Security & Privacy > General
• Require Password to Modify Preferences
System Preferences > Security & Privacy > General
• Block All Incoming Connections
System Preferences > Security & Privacy > Firewall (Advanced)
• Do Not Allow Safari to Open Safe Files
Safari > Preferences > General
• Update Software Regularly
System Preferences > Software Update
44. Dell World User Forum
GateKeeper
"Gatekeeper is a new feature in Mountain Lion and OS X Lion v10.7.5 that builds on OS X's existing
malware checks to help protect your Mac from malware and misbehaving apps downloaded from
the Internet." --Apple
• Relies on Certs between the Developer and Apple.
• It is there for a reason… but it can get in the way.
45. Dell World User Forum
Gatekeeper
• System Preferences
– Security level
• Anything new may get caught.
• Some things are quarantined
47. Dell World User Forum
Gatekeeper
• Get around it by right-clicking (control-click) and choose Open
• Then confirm you meant to open that
48. Dell World User Forum
Gatekeeper
• If cert isn’t present or valid, gatekeeper interrupts and Quarantines the application
• Quarantines can be manipulated using /usr/bin/xattr
49. Dell World User Forum
FileVault 2
• Disk Encryption
“FileVault 2 uses full disk, XTS-AES 128 encryption to help keep your data secure. With FileVault
2 you can encrypt the contents of your entire drive.”
• Lion & Mountian Lion only (10.7+)
• Recovery Key! Don’t lose it!
• FileVault originally only encrypted User’s Home directory.
50. Dell World User Forum
FileVault 2
• Recovery Key! Don’t lose it!
52. Dell World User Forum
Keychain
• Keychain Access.app
– Holds passwords (that you choose to have the system save)
– Certificates
– Secure Notes, etc.
– Can be leveraged via Command line for Scripts
› you read the username like this from the command line
security find-internet-password -s ftp.home.com | grep "acct" | cut -d
'"' -f 4
› The service is what you entered in keychain, but without the prefix. And finally your password
security 2>&1 >/dev/null find-internet-password -gs ftp.home.com | cut
-d '"' -f 2
› That’s all. No more plain text passwords in your script.
54. Dell World User Forum
/sbin/launchd
• Service management framework
• Always running
• Monitors processes
• Scheduled actions
• Daemons run across the system
• Agents run as the User
58. Dell World User Forum
Round-Table Discussion
Topics for discussion:
• Differences in K1 Management of MacOS
– Patching
– Software Distribution
– Scripting
• How does Netboot work?
60. Dell World User Forum
KACE Support Portal Migrating to Dell Software Support Portal
• Starting in November, all KACE
Support Portal material will be
migrated to the Dell Software Support
Portal
• All service requests will be submitted
online or by phone
• Same great content
– Knowledge base articles
– Video tutorials
– Product documentation
– JumpStart training
• Check out the Support Portal Getting
Started videos