[Fixed] vSphere 5.1 cannot login with domain account after changing domain controller

We changed our domain controllers of our company these days. Of course, we did that by SOP:

  1. use dcpromo to promote new servers as domain controllers;
  2. migrate PDC and other critical roles to the new domain controllers;
  3. use dcpromo to depromote the old domain controllers.

After these steps, all Windows servers works great.

But we can use neither vSphere Client nor vSphere Web Client to login vCenter with a domain account any more.

 

By asking VMware support, we realize we have to adjust Single Sign On for this change.

Steps:

  1. Open vSphere Web Client, using admin@system-Domain to login;
  2. Select Sign-On and Discovery – Configuration from the left panel;
  3. You will the a record related to your domain on the right;
  4. Select the record and make a screen capture of all information;
    (You cannot edit it directly, cos it won’t save successfully.)
  5. Delete that record and create a new one, with the same setting and new LDAP address;
    (For Authentication Type, the existed one may set to Reuse Session, but you have to change it Password and leave an account with password below. I don’t know the reason.)
  6. Save it.

All done.

 

Disable Safe Sleep in OSX

While OSX falling asleep, it save all memory into a local disk file, for avoiding data loss caused by batteries running out while sleeping. But it comes with some disadvantages:

  • That file is the same size as your memory. It eats your hard drive. You may not want this on a SSD solution;
  • Writing a so huge file requires more time while entering sleep mode.

And, when is the last time your mac’s battery running out while sleeping? Never, I guess.

Good news is, if you pleased, you can disable this function by running these two commands in terminal window.

sudo rm /private/var/vm/sleepimage
sudo pmset -a hibernatemode 0

These commands above will delete the existed image file and disable the further creation process of this file. Of course, after taking these steps, your computer will not able to resume from sleep while battery running out, by taking a cold boot instead. You may lost all unsaved data in that rare situation.

Time Sync between OSX and Windows

Through Boot Camp, we can install a dedicated Windows instance with OSX in the same mac computer. Due to the different time models, you may see that the time is not right while booting into another system.

Reason:

  • OSX, as well as other unix-like system, setting UTC to hardware time, convert to local time dynamically while displaying;
  • Windows use LOCAL TIME as hardware time directly.

You may not realized this because one of these reasons below:

  • You are in England, or other countries in Time Zone 0 (GMT);
  • Your computer system, both OSX and Windows has a client of NTP, which will get the right time from internet server very soon after booting. Certainly, the related computer should have an active internet connection.

How to fix it:

I didn’t find a way to change the time model of OSX. But we can do that in Windows.

  1. Start Regedit;
  2. Nav to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation;
  3. Create a new DWORD named as RealTimeIsUniversal, and set it value to 1.

Fix “Open With” menu of OSX

After removing and re-installing some software, there may be some of obsoleted or duplicated item in osx “Open With” menu of right-click mouse menu. In that case, you need to run this code in terminal to rebuild that menu.

/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain user; killall Finder

As you seen, after rebuild menu, Finder will be killed and restart also.

Alternatively, you may want to save that code as a shortcut by this:

  1. Start Teminal;
  2. nano .bash_profile
  3. write this text below and save that file:
    alais FixOpenWithMenu = '/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain user; killall Finder'

After doing that, you will only need to type FixOpenWithMenu in terminal window instead of that long command.

 

Install dotNet framework 3.5 on Win8 / WinSvr2012

We know that from Windows Vista, the original optical media is useless after you finish system installation. Enabling a role of feature do not require that media any more.

But in Windows 8 / Windows Server 2012, for some reason we don’t know, the situation is changed a little. The setup package of dotNet framework 3.5 is not pre-copied to your hard drive. It will have to be downloaded from Microsoft while enabling that feature.

If you hate this, luckily, that setup package is on installation media also. We just need to tell the system to use that instead of downloading.

You may want to run this as administrator:

DISM /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:d:\sources\sxs

where:

  • /Online targets the operating system you’re running (instead of an offline Windows image).
  • /Enable-Feature /FeatureName:NetFx3 specifies that you want to enable the .NET Framework 3.5.
  • /All enables all parent features of the .NET Framework 3.5.
  • /LimitAccess prevents DISM from contacting Windows Update.
  • /Source specifies the location of the files needed to restore the feature (in this example, the D:\sources\sxs directory).

Source: http://msdn.microsoft.com/en-us/library/hh506443.aspx