Blog Archive
Most of this is quite old and irrelevant, some might be dangerous. You have been warned.
Most of this is quite old and irrelevant, some might be dangerous. You have been warned.
One of the great things in vSphere 5.1 is that the Mac Pro is a fully supported server for ESXi. That means you can virtualize OSX on supported and recent hardware.
While the templating and integration is not as great as with Windows and Linux, you can deploy VMs in a reasonably short amount of time. Just make sure you don't check the "Edit virtual hardware (Experimental)" box as it may blow your template up.
If you attempt to grow the disk, you will get a "Partition failed" error message in OSX "MediaKit reports partition (map) too small.". No matter how many times you try it won't work...
At this point you have 4 options:
Since I didn't have time to place a purchase request and didn't have much time, I used a PartedMagic iso I already had in one of my Datastores. Only to notice that the iso wouldn't boot. This is due to the fact that OSX VMs are running in EFI boot mode only.
Fear not, there is a way to get it to boot:
UPDATE 10/03/12: Turns out, Apple decided it's no longer possible to update a newer OS than what the server is actually running (i.e. no updates for 10.8 if the server is running 10.7). As per this KB article, updating Mountain Lion requires a Mountain Lion server. My stance on this is to use either Reposado or Munki to server updates moving forward... Apple still doesn't care about the enterprise market.
Anything below this is deprecated and no longer works. Keeping it here for archiving purposes.
You want to follow this Apple article that applies to Snow Leopard: http://support.apple.com/kb/HT4771
Add the following line at the end of the otherCatalogs array in /etc/swupd/swupd.plist:
index-mountainlion-lion-snowleopard-leopard.merged-1.sucatalog
Then, locate the following line in /etc/swupd/swupd.conf:
RewriteRule ^/index\.sucatalog$ http://%{HTTP_HOST}/cgi-bin/SoftwareUpdateServerGetCatalog?/index-lion-snowleopard-leopard.merged-1.sucatalog
Add these 2 lines after:
RewriteCond %{HTTP_USER_AGENT} Darwin/12
RewriteRule ^/index\.sucatalog$ http://%{HTTP_HOST}/cgi-bin/SoftwareUpdateServerGetCatalog?/index-mountainlion-lion-snowleopard-leopard.merged-1.sucatalog
Restart Software Update.
I've been quite busy lately so I'll try to be quick... I would like to share my discoveries on MDT 2012 and the information I gathered while I was migrating from MDT 2010.
If you're running MDT 2012, please read Michael Niehaus' post: http://blogs.technet.com/b/mniehaus/archive/2011/11/28/mdt-2012-new-feature-dart-integration.aspx
I recently found out Microsoft Diagnostics and Recovery Tools (I'll refer to it as DaRT thereafter) was quite handy. It is part of Microsoft Desktop Optimization Pack, which is available for free if you're covered by Software Assurance.
So basically the goal here it to integrate the tools available in DaRT into the WinPE boot image generated by MDT.
Looks handy, doesn't it?
DaRT is distributed as an installer which requires Windows 7 setup files to generate a custom WIM encapsulated into an ISO. Sounds quite cool but that's one more thing to maintain and update with new drivers... Since the DaRT installer uses WinPE that shouldn't be too hard to figure out a way to add some more files to make it work.
Took me a little while to figure out but it ended up working so I'm sharing the technique with you guys:
You will need: Windows AIK, the DaRT installer, MDT 2010 and some kind of archive utility like 7-zip.
You will also need to do this twice, once for the x86 Boot Image and once for the x64 Boot Image.
You're done.
Mikael Nystrom has a very interesting blog post over at deploymentbunny.com on how to update the BIOS on HP, Dell and Lenovo computers.
The source code is mostly functional but you will need to be careful with the non-unicode characters here and there.
You will often find yourself with a deployed computer that doesn't match the resolution it's supposed to use. It's quite annoying, especially on laptops (have you seen how ugly Windows is when displayed at 1024x768 on a 1920x1200 screen?).
There is a very easy way around that:
Congrats, you now have a resolution independent task sequence. It is highly recommended to have up to date drivers available in your deployment process.
Let's say we want to advertise an update to Adobe Reader only to clients with outdated versions (anything older than 10.0.1).
select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,
SMS_R_SYSTEM.SMSUniqueIdentifier,SMS_R_SYSTEM.ResourceDomainORWorkgroup,
SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_ADD_REMOVE_PROGRAMS on SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID = SMS_R_System.ResourceId where SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName like "Adobe Reader %" and SMS_G_System_ADD_REMOVE_PROGRAMS.Version != "10.0.1"
Make edits to match the DisplayName and Version according to the results you want.
You're good to go.
You may get the following error message when trying to generate reports:
"The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map."
To solve that, add the ASP Role Service to IIS in addition to ASP.net.
To enable ConfigMgr client deployment, create the following GPO (or update if you already have one):
Computer Configuration > Policies > Administrative Templates > Network > Network Connections > Windows Firewall > Domain Profile
Windows Firewall: Allow inbound file and printer sharing exception: Enabled
Allow unsolicited incoming messages from these IP addresses: SCCM IP Address
Windows Firewall: Allow inbound remote administration exception Enabled
Allow unsolicited incoming messages from these IP addresses: SCCM IP Address
After installing SCCM I noticed that IIS was not populated with the different websites needed to run ConfigMgr properly.
I took me hours to figure out until I found the ConfigMgr Toolkit. Run the MP Troubleshooter, it will solve the issues.
Of course MS could fix that easily but that must be too much to ask for.
What I wrote about Adobe Reader MSI patching has a major flaw: you cannot under any circumstances update Adobe Reader after installing it with the modified MSI. I had to find another way...
Good news, it's a lot easier now.
I came across the need to deploy iTunes using MDT (2010 or 2012). Unfortunately, there is no way to run the usual setup file with switches.
The key is to expand the installer (using 7-zip) and then create hidden applications for each component (that also allows you to prevent Bonjour or Apple Software update from installing...).
Install the MSI files in this order:
ApplicationSupport.msi
MobileDeviceSupport.msi
SoftwareUpdate.msi
Quicktime.msi
Bonjour.msi
iTunes.msi
Using this command: msiexec /i XXX.msi /qb REBOOT=ReallySuppress
(where xxx is the msi filename, of course)
It also works for the 64-bit version. Every time there is an update of iTunes, simply overwrite the files on your network share.
You will notice that now matter how you install your operating system, the network adapters order is very likely to be wrong, usually with the wireless adapter at the top.
How to find out:
Now, there's a way to automate this for enterprise deployment: Hyper-V Network VSP Bind Application.
This utility is not intended to be used on client Operating Systems but indeed works great. All the info is here: http://code.msdn.microsoft.com/nvspbind
Simply copy the executable to a known location and execute the following command:
nvspbind /++ "Local Area Connection" *
Where /++ puts the adapter named "Local Area Connection" at the top for all protocols with *
If you need to automate the attribution of local admin rights, use the following script, that will save you quite a few clicks:
Dim DomainNameDim UserAccountSet net = WScript.CreateObject("WScript.Network")local = net.ComputerNameDomainName = "CONTOSO" set group = GetObject("WinNT://"& local &"/Administrators") UserAccount = InputBox( "Please enter the username (first.last) of the local admin or cancel (the user must exist in AD)" ) on error resume nextgroup.Add "WinNT://"& DomainName &"/"& UserAccount &""CheckError sub CheckErrorif not err.number=0 thenset ole = CreateObject("ole.err")MsgBox ole.oleError(err.Number), vbCriticalerr.clearelseMsgBox "User added to the local Admin Group"end ifend sub
If you want to be able to set the local admin password but also leave the possibility to make it blank, edit the following file scripts\DeployWiz_Validation.vbs in MDT 2010 and scripts\DeployWiz_AdminPassword.vbs in MDT 2012:
Function ValidatePassword
ValidatePassword = ParseAllWarningLabels
NonMatchPassword.style.display = "none" If Password1.Value <> "" then
If Password1.Value <> Password2.Value then
ValidatePassword = TRUE
NonMatchPassword.style.display = "inline"
End if
End if
ButtonNext.Disabled = not ValidatePassword
End Function
Deployment guru Johan Arwidmark has a pretty interesting article about adding a boot menu to WDS. But it's about Windows Server 2008 R2. If, like me, you need info about Windows Server 2008, follow his step-by-step until step 7.
Annoying.
Some people recommend to nuke the whole Outlook profile but that didn't work for me. The solution is pretty simple... Go to Start>Run then type the following:
Outlook.exe /resetnavpane
Fixed!!
[Edited for Mac OSX Lion, thanks to Ted.]
Deploying Windows on Macs is a bit complicated since they don't support standard PC features like PXE. Considering you have one-and-only one Mac OS partition (usually Macintosh HD), running the Boot Camp installer creates a fourth partition on Disk0 (Disk0\Partition3 or Disk 0\Partition4 if you're running Lion/Mountain Lion).
MDT lets you generate boot CDs for unsupported hardware. Make sure you include Broadcom, Marvell and Nvidia Ethernet drivers into your driver repository.
You're done.
Sometimes when Outlook changes network contexts (i.e. from wired to wireless), it triggers an annoying authentication popup. There's a way around:
I've been wanting to put a list of my favorite tools online for a long time...
System cleanup, tune-up and optimization:
Ccleaner - Piriform - Free - Cleans caches, temp files, application specific settings, cleans up the registry and much more.
Defraggler - Piriform - Free - An awesome disk defragmentation software.
Cleanup! 4.5.2 - Steven Gould - Free - Very very strong cleanup tool for Windows XP only.
Filesystem repair:
Data Recovery Wizard Pro - EaseUs - $69.95 - Best data recovery software I've ever used. Way more efficient than Ontrack EasyRecovery Pro. And cheaper. Saved my a** more than a couple of times.
ViVard - Copyrsoft - Free - HDD diagnostic and sector repair. Vendor independent.
Mac side:
Appcleaner - FreeMacSoft - Free - Application uninstaller for Mac OS. Like AppZapper but free.
OnyX - Titanium Software - Free - Like Ccleaner, for mac. Awesome.
Misc:
Mouse Jiggler.vbs, a small VBscript I use to prevent a computer from locking itself when I'm working on it without knowing the user's password:
Set WshShell = WScript.CreateObject("Wscript.Shell")
Do While 1
WshShell.SendKeys"{SCROLLLOCK}"
WshShell.SendKeys"{SCROLLLOCK}"
WScript.Sleep(300000)
Loop
Just a useful tip from the top of my head. If you want to migrate Outlook settings without having to reconfigure accounts, delivery options and PST locations, here is the registry key you need to export:
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles
* If you're migrating from XP to a next-gen OS (Vista or 7), you'll get some error messages because C:\Documents and Setting\User\Local Settings\Application Data is now C:\Users\User\AppData\Local make sure you put the PST files in the right place and simply browse to their location when asked.
Since I try to put everything here that gives me headache, makes me pull my hair or worse, makes me want to run to the closest hardware store to buy the biggest hammer I can find, here is my latest discovery...
Case study:
A Windows XP user requests a new computer running Windows 7.
Actions taken:
Backup the old computer to a network share.
Take a new computer out of the box.
Put a standard image on it.
Have the user logging in.
Restore files.
Let the user go.
Issue:
A few days after the system deployment, the user starts complaining about connectivity issues (i.e. getting an IP but no connectivity) and general slowness of the computer.
Troubleshooting steps:
Since I got the new one back, I had some more time to investigate...
Here's what I found after running ipconfig /all:
Default Gateway . . . . . . . . . : 0.0.0.0
Very interesting, that explains why he has an IP but no connectivity. A quick Google search confirmed the issue:It's related to Adobe CS3 software that installs Bonjour which basically breaks WinSock on Windows and the solution is to remove Bonjour using the following steps:
Courtesy of FritoBandito from the Adobe Forums.
I came across a couple of issues while test-driving Sophos Antivirus Enterprise.
Here are the correct steps to deploy Sophos to Windows machines (XP, Vista and 7):
You should now be able to deploy Sophos Antivirus seamlessly.
In Microsoft effort to tighten Windows security, the administrative shares as we used to know them (C$, IPC$ or Admin$) are not visible by default...
Hopefully, here again, there is an easy trick:
Now you can deploy Kaspersky Antivirus on Vista without taking that much risk.
If you see iTunes hanging (being unresponsive) when you connect your iPhone, try the following:
Double clicking on an Excel file does not open it. Instead Excel opens and displays a blank workbook. However, if you minimize Excel, it will immediately maximise itself and display the file you originally tried to open.
The solution is really weird: You can stop this annoying behavior by adding an Add-in, like this:
Excel options >Add-Ins > Manage: Excel Add-Ins > Euro Currency tools.
As you may know, Macs use a GPT (GUID Partition Table) unlike Windows, that usually uses the old MBR (Master Boot Record). On top of that, there is just a BIOS emulation on top of the EFIon Apple machines. As usual, Macs are a step ahead but that creates some side effects:
Hopefully, there are workarounds. First of all, if you have HDD issues, you can move the drive to another computer (PC) to perform extensive testing, especially at the logical and mechanical level. You don't need to actually boot on the HDD - that would be impossible anyway - to analyze it. Moving a drive is not hard and doesn't void the warranty if done properly.
Cloning is now fairly easy, there is an awesome tool called WinClone from TwoCanoes that allows you to backup and restore a functional Boot Camp partition. You can even shrink your Windows partition. They also claim that you can deploy Windows using ARD.
I also would like to share a few reminders:
Sometimes, the networking layer in Windows gets corrupted. Of course you don't necessarily know why...
There are a few easy steps to fix it. The best one, in my opinion is a good old driver update which will not only reset the stack but will also bring you more stability. Check with your computer manufacturer/chipset vendor for that.
Alternatively or if you already have the best available driver (big up for staying up to date, here), you can issue a command to reset the TCP/IP stack:
A reboot is recommended after as a few registry keys need to be regenerated.
There is an interesting article at TechRepublic about GNZ or Global Name Zones in Windows Server 2008.
http://blogs.techrepublic.com.com/networking/?p=608
For the record, in the Windows Support Tools, you can find the browstat.exe utility (browstat status from a command line) that allows you to check which computer is the Master Browser and then to troubleshoot that mess that is slowing down your LAN.
How to resolve Entourage issues with Exchange 2007, especially the infamous "The user's folder could not be found. Entourage could not find a mailbox for the user username_last, username_first." The basic workaround is to instruct users to manually change the mailbox path to: mail.contoso.com/exchange/your.username@contoso.com. But wait! There is a permanent fix: