• Mac OS X,  Ubuntu,  Unix,  Xsan

    Uniq Logs

    Recently I’ve been looking at a lot of log files. And sorting through them can be a bit of a pain. However, there are some tools out there to help make this process a bit easier. The first of these is sort. If I have a log that has 1,000 lines, while I like to initially see any lines that are repeated numerous times so that I can see when servers are throwing a lot of errors, combing through them can get tedious. Sort will help to reduce the volume and organize them in a manner that makes sense. For example, to sort the logs and remove duplicate line entries…

  • Mac OS X,  Mass Deployment,  Xsan

    Blessing the blessed

    The bless command can be used to read your currently blessed operating system in Mac OS X. You can also leverage it to set an operating system in Mac OS X. Don’t ask why, but I recently needed to read what my blessed operating system was and set my blessed operating system to the same volume. Much like choosing a volume in the Startup Disk System Preference pane when I’m already booted to that volume. With a little help debugging, here’s what I came up, in case anyone : myDisk=”$(/usr/sbin/bless –getBoot)” myDiskOutput=”$(/usr/sbin/diskutil info “$myDisk” | grep “Volume Name” | cut -c 30-60)” bless –mount /Volumes/”$myDiskOutput” –setBoot echo $myDiskUtilOutput > /tmp/booter.txt…

  • Mac OS X,  Mac Security

    Disable Quarantine

    I recently wrote up an article on some of the new malware safeguards in Snow Leopard. Well, turns out some people want to disable some of it. So you know the prompt that you are downloading an application that then asks you if you want to open it since it’s been quarantined. Well, you can disable it (not that you should but I’ve seen a couple of cases now where I needed to. To do so you’re going to place an LSQuarantine key into the com.apple.LaunchServices.plist. To do so, run: defaults write com.apple.LaunchServices LSQuarantine -bool NO To set it back to normal: defaults write com.apple.LaunchServices LSQuarantine -bool YES

  • iPhone

    The iPad's A4 processor

    The iPad is leveraging the new A4 chip from Apple, the first time Apple has released their own chip. Running at 1GhZ, the A4 is an ARM-based chip. The A4 is similar, if not the the ARM Coretex-A9 MPCore processor with graphics brought to you by the ARM Mali 50, capable of 720p hi-def video. These chips are what are referred to as System on a Chip, which stands for SOC. An SOC has a processor, graphics and memory together on the chip. If this sounds similar to an Atom chip, such as Moorestown from Intel then you’re not crazy, it is. This is similar to the Snapdragon chips from…

  • Mac OS X

    Last of the Screen Sharing Hacks

    Once upon a time (all the way back in Mac OS X 10.5) you could add a bunch of useful icons into the toolbar of Screen Sharing.app using: defaults write com.apple.ScreenSharing ‘NSToolbar Configuration ControlToolbar’ -dict-add ‘TB Item Identifiers”(Scale,Control,Share,Curtain,Capture,FullScreen,GetClipboard,Quaty)’ But alas, you can’t any more (NSToolbar still exists but I haven’t found a way to get the array to result in actual icons in the toolbar). I’ve done a few articles for other preferences so I thought I’d dig my heels in and see if there were any I missed (using gdb). Well, apparently, there’s still ShowBonjourBrowser_Debug, which was also in 10.5 but it doesn’t seem to do anything. But I…

  • Mac OS X,  Mass Deployment

    What Is My Build Number?

    I have been known to occasionally ask what build number of Mac OS X that someone is using. The sw_vers command can be used to obtain this. Simply run: sw_vers And the BuildVersion will be listed. Or just to get the BuildVersion: sw_vers | grep BuildVersion Or to just get the number (useful in scripts that catalog such a thing: sw_vers | grep BuildVersion | cut -c 15-21 As one comment just indicated, you could also just use `sw_vers -buildVersion`. I guess I should review these commands every operating system or 4… Thanks Allen.

  • Mac OS X

    Spotlightish Finder

    When you search for files the Finder window with the results has what is known as the Path Bar. As you can see in the below image, the Path Bar allows you to click on any directory in the hierarchy up to the one you are on and open that directory in the Finder. By default, the Path Bar is only shown in a search result, but if you like it then you can see it in every Finder window. To enable this feature, create a boolean key in the com.apple.finder.plist with a value of yes. To do so, you can use the defaults command: defaults write com.apple.finder ShowPathBar -bool…

  • Mac OS X

    Command Keys and ScreenSharing

    I like to send the command, control and other system keys to hosts that I’m using ScreenSharing or Remote Desktop to access. But as I recently discovered, not everyone does. You can turn this feature off using the defaults command to augment the DoNotSendSystemKeys key of the com.apple.ScreenSharing.plist property list file. Simply run the following command: defaults write com.apple.ScreenSharing DoNotSendSystemKeys -bool YES To turn them back on: defaults write com.apple.ScreenSharing DoNotSendSystemKeys -bool NO Or for Remote Desktop, augment the com.apple. defaults write com.apple.RemoteDesktop DoNotSendSystemKeys -bool YES To turn it back off for Remote Desktop: defaults write com.apple.RemoteDesktop DoNotSendSystemKeys -bool NO FYI, if you don’t want to send the command keys…

  • Mac OS X,  Windows Server

    RDP from the Command Line

    Let’s face it, connecting to Windows Servers is a must for many of us. And some of us want to do so programatically. I did look at populating the CoRD database in a previous article. But now, luckily CoRD has recently introduced a command line interface for managing just these types of connections on the fly as well. And, it is very straight forward. There are two ways to call CoRD from the command line. The first is similar to how we handled VNC in an earlier article. Simply leverage the open command and call the URL with a rdp in the beginning. For example, if you want to open…