Command line Mac OS X printer install

November 30th, 2010

Here’s a way to add a dgp http printer to mac os (and configure it to deal with the abort-job policy problem):

lpadmin -p ‘MomonWood’ -E -o name=’MomonWood’ -v ‘http://wood.dgp.toronto.edu/printers/Mom_on_Wood/.printer’ -P ‘/Library/Printers/PPDs/Contents/Resources/HP LaserJet 2430.gz’ -o printer-error-policy=”abort-job”

Resetting password on Mac OS X 10.5 (without the cd)

November 24th, 2010

I recently received a macbook which I didn’t have an account on, so I found the following instructions for resetting the password (from

http://www.macyourself.com/2009/08/03/how-to-reset-your-mac-os-x-password-without-an-installer-disc/ )

Reset 10.5 Leopard password

  1. Power on or restart your Mac.
  2. At the chime (or grey screen if your chime is turned off), hold down Command+S on your keyboard to enter single-user mode.
  3. This step is optional, but it’s a good idea because it checks the consistency of the hard disk before moving on. At the prompt, type fsck -fy and press Enter/Return. Wait for the checks to complete before going to the next step.
  4. Type mount -uw / and press Enter.
  5. Type launchctl load /System/Library/LaunchDaemons/com.apple.DirectoryServices.plist and press Enter.
  6. Type ls /Users and press Enter. This lists all of the usernames on the computer – helpful if you don’t know or remember what these are.
  7. Type dscl . -passwd /Users/username password and replace “username” with one of the users displayed in the previous step. Replace “password” with a new password of your choice. Press Enter.
  8. Type reboot and press Enter.

Windows Update Catalog

November 15th, 2010

Microsoft maintains a website with a catalog of all the device drivers, software update and hotfixes you get through windows update or the add/remove device wizard on windows.  It’s intended for corporate deployments of these packages.  The website is here:

http://catalog.update.microsoft.com

exFat support on Windows XP

September 14th, 2010

A student showed up today with a drive formatted using exFat, which isn’t included on windows xp by default (Vista and Win 7 have support for it).  Microsoft provides an update that can be downloaded.  Here is the command line to allow you to do a silent install from a central location using psexec (Sysinternals):

psexec -c \\MachineName WindowsXP-KB955704-x86-ENU.exe /passive /norestart /quiet

It looks like it will require a restart to work, but can be installed without restarting right away.

Volume licence Activation in Office 2010

August 6th, 2010

I’ve built a .cmd script modeled on the sample provided by Microsoft for installing Office 2010 silently.  It uses a MAK volume key and also does the activation after the install.  There is a vbs script provided in the office installation for managing activation.  I activate it by adding the following to my script:

IF NOT “%ProgramFiles(x86)%”==”” (goto ACT64) else (goto ACT86)

REM Attempt to activate the product
:ACT64
cscript “%ProgramFiles(x86)%\Microsoft Office\Office 14\OSPP.VBS” /act
goto End

:ACT86
cscript “%ProgramFiles%\Microsoft Office\Office 14\OSPP.VBS” /act

I also found that there is a tool for computers to do remote activation on – the Volume Activation Management Tool.  It only works with machines that allow remote wmi access, so it’s most useful in situations where you have already enabled this access via group policy to a number of machines.

Rebuilding inbox to fix hung imap command

July 14th, 2010

Every year I like to move my previous year email messages into a different folder, which often results in running into my quota limit.  This year, I managed to get the imap move command to keep trying and failing after running out of disk space.  To resolve it, I had to do the following:

  1. Right-click on the problem Inbox.
  2. Browse to the General Information tab.
  3. Click on Rebuild Index

The move command stopped and I was able to receive mail again.

July 12th to 16th

July 14th, 2010

This week is a software update week, and autodesk has updated their registration tool so our network licence file has been received.

  • windows software update
  • Setting up licence for autodesk products

Possible solution to windows 7 network problems

July 13th, 2010

A student has found some info on the net indicating that the bonjour service (installed with Adobe CS3, in this case) is interfering with windows 7 network. It has been disabled for testing. The student has now be running it for a few weeks without issue (since June 11).

I disabled bonjour in the services control panel.

University Iphone Developer Program

June 11th, 2010

I’ve now gone through the process required to get an ipad/iphone device ready to be used for development.  It was mostly easy to do by following the instructions on the developer site, but I kept getting an error message:

profile doesn’t match application identifier com.yourcompany.

The solution is to find and edit the .plist file in your app to give it the correct bundle identifier (for me it was edu.toronto.dgp)

Here is a link to how to change the template so it starts with the correct info.plist information:

http://www.johntwang.com/blog/2009/03/10/how-to-change-comyourcompany-in-xcode-for-iphone-applications/

You navigate to /Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Project Templates/Application and edit the Info.plist file in each of the template directories. (edit the value for CFBundleIdentifier)

June 7th to 11th

June 11th, 2010

In addition to G20 summit preparations, I’ll also be doing windows update tests and hopefully rolling them out next week.

  • Set up iphone app certificates for ipad development
  • testing remote switch power bars
  • upgrading flash on managed windows computers