I guess it’s a sign of my age. But I can’t stand that whole natural scrolling thing. So I disable it as a part of my imaging process. To do so, set the com.apple.swipescrolldirection global domain to false using defaults, as follows: defaults write NSGlobalDomain com.apple.swipescrolldirection -bool false To set it back: defaults write NSGlobalDomain com.apple.swipescrolldirection -bool true
-
-
Securely Empty The Trash By Default
You can empty the OS X trash securely by choosing the Secure Empty Trash option from the Finder menu. However, you can configure the empty trash option to be a Secure Empty Trash operation. To do so, write an EmptyTrashSecurely key into the com.apple.finder.plist. Use defaults to write the key into this plist as follows: defaults write com.apple.finder EmptyTrashSecurely -bool true
-
Reboot Your Own Machine At MacMiniColo
Even a Mac needs to be rebooted sometimes. If you host a computer at Mac Mini Colo, it’s pretty easy to reboot. To reboot your system, log into your account with MacMini Colo. Once logged in, click on Computers and then click on the computer that you’d like to reboot. Then click on the Reboot button and confirm the reboot.
-
Simple Preflight and Sanity Checking in Scripts
I was recently building some preflight scripts and was looking to record some information about a machine live, before proceeding with a script. I found the cheapest way to determine information about architectures and chipsets when scripting preflight scripts for OS X to be the arch and machine commands respectively. For example, to verify the architecture is i386, use the arch command with no options: /usr/bin/arch Which simply outputs “i386”: i386 To check the machine type, simply use the machine command: /usr/bin/machine Which outputs as follows: x86_64h
- Mac OS X, Mac OS X Server, Mac Security, Mass Deployment, Network Infrastructure, Programming, Ubuntu, Unix
Opposite Day: Reversing Lines In Files
The other day, my daughter said “it’s opposite day” when it was time to do a little homework, trying to get out of it! Which reminded me of a funny little command line tool called rev. Rev reads a file and reverses all the lines. So let’s touch a file called rev ~/Desktop/revtest and then populate it with the following lines: 123 321 123 Now run rev followed by the file name: rev ~/Desktop/revtest Now cat it: cat !$ Now rev it again: rev !$ You go go forward and back at will for fun, much more fun than homework… Enjoy!
-
Refresh OS X CRLs
I recently found an existing image with a lot of stale crl information. We couldn’t rebuild the image, so we decided to instead refresh all of the crl information. This information is stored in /var/db/crls/crlcache.db. Deleting the file turned out to be problematic so we needed to clear items out of the tables instead. While this could be done using a few different tools, it turns out there’s a command built into os x to take care of this process for us called crlrefresh. To use crlrefresh to clean up stale crlinformation and fetch new crlinformation for all CRL and certificates, use: crlrefresh rpvv
-
See How Long The Active User Has Logged In On A Mac
The following will grab you an integer of the number of hours an active user has logged into a computer: user=$( ls -l /dev/console | awk '{ print $3 }' ) ; ac users $user | awk '{ print $2 }'
-
Casper 9.62 Is Out!
Casper 9.62 is now out! And holy buckets, look at all the stuff that got fixed in this release: http://resources.jamfsoftware.com/documents/products/documentation/Casper-Suite-9.62-Release-Notes.pdf?mtime=1416856726 PS – There’s also some api improvement goodness!
-
MacVoices Podcast With Chuck Joiner About The New Take Control Of OS X Server Book!
Yay, podcasts! Chuck Joiner was kind enough to have me on MacVoices. We did a show, now available at http://www.macvoices.com/macvoices-14223-charles-edge-helps-take-control-os-x-server Or if you’d like to watch on YouTube or inline: http://youtu.be/AeccoRqIrgc
-
Bushel Goes Into Invitation Mode!
Yesterday the Bushel team finished some new code. This code allows you to refer your friends to Bushel! This skips the codes that everyone was waiting for and lets people create accounts immediately! From your home screen, click on Invite Friends. Or from the Account screen, scroll down to the section that says “Invite friends to join Bushel”. From here, you can post codes to Facebook, Tweet codes, post codes to LinkedIn and even email them. We’re not going into general availability just yet. But we’re definitely making it easier long-term to sign up and use Bushel! We hope you love it as much as we do! Since we’re still architecting how these…