Recovering important data from iOS4

December 4, 2011 Leave a comment

Today I have been experiencing some disaster on my iPhone 4: my iPhone stopped responding during file I/O.  It even cannot response to power on/off command and I need to force it reset using “Home + Power” combination.  My disaster happened after this “forced restart”: it stucked at apple logo, and seems like it ran into “automatic restart” once after several seconds.  I predicted the iOS file system is corrupted.

I tried iPhone Recovery Mode, DFU, Tethered Boot and everything, and got no luck on booting the phone again.  Frankly speaking, I can only about some photo in my phone but nothing else.  For that kind of rubbish low quality device if there is no data in it I will throw it straight to trash bin.  I regard I didn’t remember someone from Redmond told me 1 or 2 years before this gadget is a toy and not for IT pros like us.  (Sorry if someone still love this device since it really drove me mad)

Eventually I discovered a way that sound feasible to me for retrieving my valuable data.  Thanks Immar28 at http://modmyi.com/forums/file-mods/237321-how-iphone-data-recovery.html.  Since the mechanism seems not working fine in iOS4, I did some workaround and eventually made the recovery carrying on.  I would like to share the tricks so someone stuck into the same situation with me may get some hope.

  1. You need to have your iPhone jailbroken – though someone still having strong reaction against this due to whatever ethic or other reason, jailbreaking is the only way in to this rest of the walkthrough.  If your phone is too new for jailbreak, or if you don’t want to jailbreak your iPhone, sorry, please let your data RIP.  I am not going to teach you how to jailbreak your phone, please google it by yourself.
  2. Install OpenSSH into your jailbroken iPhone.
  3. If you are using Windows as your primary working platform like me, download a SSH server and a DD utility for Windows.  You don’t need it if you are using a Mac or Linux.  You can google for Bitvise WinSSHD and dd for Windows to source them.
  4. Disable screen timeout lock in iPhone.
  5. Connect your iPhone into Wifi, in the same LAN with your computer, then SSH into your iPhone, and su to make root access.
  6. In your iPhone, use dd to dump out the user disk /dev/rdisk0s2s1 and stream the content back to your PC SSH server.  The command sh0uld be like this: dd if=/dev/rdisk0s2s1 bs=1M | ssh user@192.168.1.101 ‘dd of=iphone_user_parition.img’  Remember bs=1M is an important factor that cannot be omitted.
  7. That should be a long long way to go since mine iPhone is a 32GB one.  Observe on PC side to see the dump file grow and the process should be ended automatically.  I amd currently in this stage.
  8. In PC side use a raw file system recovery tool like R-Studio to scan the disk image to extract the lost data.

I will keep updating for any luck on my recovery.  Meanwhile I have bought a Galaxy Notes as my replacement phone :-) (Maybe a Nokia Windows Phone Lumia as a backup phone… I tried it in MSHK Microsoft Experience Center, and it was great).

Categories: iPhone, Mobile

Windows 8, Windows Server 8 and Hyper-V 3.0 Features Unveiled!

September 18, 2011 Leave a comment

Since the transition from Windows 3.1 to Windows 95, and Windows NT 4.0 to Windows 2000, I had long time didn’t experience an excitement of Microsoft OS launch.

I can even see the impact of Windows 8, Windows Server 8 and Hyper-V 3.0 in technology econogy can be at least as big as iPhone launch.

I am now composing several post for Windows 8, Windows Server 8 and Hyper-V 3.0 respectivity, together with System Center 2012.  You will see how Microsoft OS has been evolved from a easy-to-use SME OS (this is the image of Windows as of NT 4.0, but inherited till now in most people’s mind) into a “not only enterprise ready”, but a “enterprise cloud ready” OS, with Hyper-V 3.0 and System Center as the intruments.

Stay tuned.

Troubleshooting Windows Proxy Autodiscovery (WPAD)

September 10, 2011 Leave a comment

Today I was configuring TMG for DNS/DHCP WPAD.  In fact, I ran into a trouble that some host in the segment can use IE Proxy Autodiscover setting, while some cannot. 

This is confusing: I hosted the wpad.dat file on TMG and published to Intranet only.  The file is accessable (or else there will not be the case some host can be configured correctly).

Technology Background

Windows Internet connection can leverage automatic discovery feature to discover proxy setting.  To make it happens, you can leverage TMG client for AD discovery.  However, although this is highly recommended to install TMG client for better performance, there is still some cases that TMG client installation is impossible.  In this case, you need to rely on DNS and DHCP auto discovery.

The basis of DNS and DHCP discovery is on a file wpad.dat.  This file is a text file, and can be generated by TMG.  You can host it on any HTTP server or TMG itself.  Of course, when hosted on TMG, you need to make sure TMG port 80 of internal NIC is not already occupied.

Windows will default to query DHCP option 252 (custom option that you need to add manually at DHCP server) for the full path name of wpad.dat file.  For tricks of this, please check the Troubleshooting Walkthrough section in this post.

Next to DHCP, or if DHCP is not available, Windows will go to ask for DNS.  You need to create a CNAME record “WPAD” in DNS zone and point to the FQDN of the wpad.dat hoster, that is the TMG in my case.

Troubleshooting Walkthrough

Finally I made it done.  Below are some tips and tricks on troubleshooting:

Check wpad.dat file accessibility

Make sure at the host that is experiencing error, browse for the file directly.  In my case, my TMG FQDN is tmg1.contoso.com, and I was hosting the wpad.dat file at port 80 (this is a must for DNS discovery, please check MS TechNet or TMG product documentation), when you check the following path:

http://tmg1.contoso.com:80/wpad.dat

You should be able to see a download page like this:

wpad.dat download prompt

If you can see this, it means your wpad.dat file is published correctly on TMG.  You can try typing “wpad.dat” as “Wpad.dat”.  You will find it doesn’t work, since the file name part is case sensitive.  This is very important!

The CNAME record

Next, test out the following URL:

http://wpad.contoso.com:80/wpad.dat

If that’s OK, means your DNS entry is also configured correctly.

wpad.dat file validity

You will immediately come across a question: is the wpad.dat file ready works?  Try placing the wpad file path directly into IE Automatic Configuration Script text box, if you can still access Internet, then the file should have no problem:

wpad.dat file as auto configuration script

Wpad related registry entries

One important point for Wpad working, is the registry settings.  You need to know the following key contains the Wpad settings of your user profile:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections

If you kick into the value “DefaultConnectionSettings”, you will find this binary data is actually containing the wpad.dat file path:

In my case, the original erroreous “DefaultConnectionSettings” value looked like below, how terrible it is:

Ignoring wpad.dat retrieval?

Then, does Windows really getting the wpad.dat file?

To verify this, I went to TMG log console to see if any port 80 traffic is requesting to TMG by the client machine (192.168.0.254) when browsing start.  This is what I found:

Why DNS query?  I should have asked IE to get from proxy.  DNS query should only be done from TMG to TMG’s DNS server.  It means Windows refused to grab wpad.dat setting, not even apply.

Using the MS Network Monitor for troubleshooting

Further troubleshooting can be really hard without a network monitoring software.  Most people will consider Microsoft has taken away Network Monitor from Windows.  In fact the had provided download link in MS Download Center website here:

MS Network Monitor 3.4 Download: http://www.microsoft.com/download/en/details.aspx?id=4865

Wpad decisions

I found there is a somewhat related registry key here:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Wpad

Seems like Windows is trying to save whether using, not using and how to use wpad.dat file preference here.  This is a new Windows 7 feature, though pretty much stupid.

The keys are:

  • If your computer has been able to resolve Internet FQDN before, then proxy auto discovery will not be used for performance consideration.
  • If your computer is being unable to perform auto discovery for several tries, then proxy auto disovery will be disabled for performance consideration.

This setting is a per connection setting.  However, if you try to do plug and unplug NIC from zone to zone, that can come across some unpredictable result.

To remediate this, I did back up the registry key first, and then try deleting the whole key and see what’s going to happen.  I found the key will be regenerated when IE is closed and restarted, however, the key is empty.

Then I tried disabling proxy auto discovery in IE, apply the setting and turned back on, then the whole Wpad registry is recovered into a correct manner, and everything works like a charm!  Let’s see wpad.dat is being downloaded from TMG (this time the client IP is 192.168.0.201 as shown in Network Monitor):

Just in case you are very new to IE, here is the setting to disable and re-enable auto discovery (“Automatically detect settings” as below).

I know this is not a good way to resolve a problem.  Since I am devil, I like to take shortcut.  And I am also curious, so I search for what these registry means, and any way to bypass, I found some post on the net saying:

This feature can be bypassed by setting the following registry value:

HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Wpad\WpadOverride = 1

Nice one.  At least I don’t need to do dirty moves any more ;-)

Categories: Forefront, TMG Tags: , ,

Tricks on setting up System Center Service Manager 2010 SP1

August 29, 2011 Leave a comment

Although System Center Service Manager (SCSM) has been released for around 1 year till now, most people is still new to it.

Nothing better than playing around a platform and experiencing it by yourself for learning.

However, installation of SCSM, though not as complex as other family member like Configurations Manager (SCCM) 2007, there are still minor tricks.  I would like to talk about them here.

  1. SCSM 2010 SP1 - SP1 is actually a full install package.  You don’t need to install RTM version before installing SP1.
  2. SQL Server locale - not all SQL Server locales are supported by SCSM.  A common trap is Latin1-General-CI-AS locale, which is a very commonly used locale, is not compatible with SCSM!  For US English, you should use Latin1-General-100-CI-AS instead.  If you want to make your database 100% compatible to SCSM, please check out here.  Make sure the SQL server is properly setup before starting SCSM installation, else you might need to go over the whole process once again.
  3. Authorization Manager hotfix check - this is for responding a friend’s question: if your underlying OS is Windows Server 2008 R2 SP1, you don’t need to install the hotfix.  However the checker is so stupid that a warning is still prompted to scare you out even you don’t need it:

One of the checks that the prerequisite checker performs is to look for the presence of the Authorization Manager hotfix (975332). If the hotfix is not found, a warning is displayed as shown in the following image.

Warning during Service Manager prerequisite check

The Authorization Manager Hotfix is included with Windows Server 2008 R2 with SP1. If you are using Windows Server 2008 R2 with SP1, you can safely ignore this warning.

After getting through these show stoppers and apparent show stoppers, you should be able to install SCSM 2010 SP1 and try it out by yourself.

PS: you might want to know that Service Manager 2012 is coming out as the 2nd version in CY2011Q4 :-)

Links:

Categories: SCSM Tags: ,

ESG Performance Report on Hyper-V R2 SP1

August 28, 2011 Leave a comment

Although VMware is still considered as the market leader of x86 server virtualization, Microsoft Hyper-V is slowly eating up its market leadership.  This is also reflected from Gartner’s magic quadrant report on virtualization report released in June 2011: Microsoft has been promoted to “leader” quadrant of x86 server virtualization, together with VMware, the previous “sole leader”, and Citrix as well.

In fact, Hyper-V is being misunderstood by most of the early adopter of virtualization: they consider Hyper-V is just a toy, slow, unstable, etc.

After 2 years of working in Hyper-V R2, I am personally considering Hyper-V R2 is not bad in enterprise readiness as publicly misinterpreted.  In fact, that’s very sad that most of the posts in the web is pretty biased to VMware.  However, this is not difficult to understand:

  1. VMware has good marketing and public image.
  2. VMware is not free, and everyone in the industry can resell it with price mark up, including both of us; while not everyone can resell Windows Server (except for Open license and full box set).
  3. VMware has an open API for 3rd party ISV to develop software solution to extend its capability.

I am not going say which hypervisor is better, this is no definite answer and will definitely end up with big thread mess here.  I am just focusing on the benefit that Hyper-V R2 can bring to you.

As an end-user, you might be interested in the cost (Hyper-V R2 is free!  Everyone can download it from here), familiarity (Windows style UI), and ease on provisioning.  More importantly, as a free hypervisor, it is delivering a high degree of functionality that paid version of VMware is delivering, including failover cluster and Live Migration (vMotion of VMware)!

Need to take a note here: I am talking about Hyper-V R2, not Hyper-V (R1).  I am considering Hyper-V (R1) a premature product, while Hyper-V R2 delivers a huge improvement over the previous release, in terms of design, stability and performance that a bare metal hypervisor should deliver.

To clear up rumors about Hyper-V R2′s (particularly in performance area this time), Microsoft has recently posted a link from Enterprise Strategy Group about performance benchmark on famous Microsoft platform workloads like Exchange 2010, SharePoint 2010 and SQL Server 2008 R2.  ESG delivers a clear, parametric and reproducible series of tests.  Potential virtualization user might find this document informative and good for reference.

You can find the performance report here.

ESG Hyper-V R2 SP1 Application Workload Performance Report

Why not giving Hyper-V R2 a try?  It’s free (Hyper-V R2 Server is free, while Windows Server is not, of course), and it behaves well.  And more importantly: Hyper-V R2 is a key for further Microsoft infrastructure architecture!  I am predicting next generation Microsoft infrastructure cannot be disconnected from Hyper-V… do you believe it?  I am believing it already :-)

Links:

  • Gartner’s magic quadrant report on virtualization report: click here.
  • Hyper-V R2 Server free download from MS Download: click here.
  • ESG Hyper-V R2 SP1 Application Workload Performance Report: click here.

Adding Facebook chat to your Windows Phone “Mango”

August 28, 2011 Leave a comment

Windows Phone “Mango” includes tons of exciting features, one of them is “Facebook chat”. However, if this feature is turned on, most likely you will just be redirected to your Facebook home instead of having the feature properly set up.

The reason behind is: you need to associate your Windows Live account with Facebook application. You can do this by logging into Windows Live profile page.

Step 1: opening up your Windows Live profile page

1: Windows Live profile page

Step 2: Connecting Facebook

2: Connecting Facebook

By means of adding the application, as well as making sure you are logging in your Facebook account using Windows Live email address, then you’re ready to rock ;-)

Categories: Windows Phone

Welcome to infratalk

August 28, 2011 Leave a comment

Hi there.  Welcome to infratalk.  I hope this blog can be a garden for you as an infrastructure lover to find your necessary survival information.  Enjoy blogging :-)

Categories: General
Follow

Get every new post delivered to your Inbox.