This is a saga, but if you’ve been tearing your hair out trying to upgrade to version 5.0 of the Apple iOS on your iPhone, its probably worth reading.
Here’s the background.
Up to Oct 2011, iPhones came installed with iOS 4. Thereafter, iOS 5.0 was released, and all iPhones sold after this time were sold with iOS 5.0.
To be honest, I don’t know what the difference between iOS 4 and iOS 5 is. I needed an iPhone to test some mobile websites (I wouldn’t buy one for personal use under any circumstances, because they’re just hand candy) and all I know is that somebody gave me an iPhone 3GS phone that they had finished with, and had it unlocked from Vodafone so that I could use it on O2. To complete the unlock process I had to do a restore of the iPhone with iTunes, and iTunes would not let me do this unless I upgraded to iOS 5.
And so the story begins.
When I first attempted to do the upgrade, iTunes happily started downloading the new software. The payload is approx. 700MB, so I knew it would take a while. However, it crapped out after approx. 50MB, so I started it again. Same thing, crapped out again, and again, and again.
I did a bit of research on this, and was told by the Apple Support web site that I should ensure I had the latest version of iTunes. My version was about 6 months old, so I went ahead and downloaded the new version.
Now when I tried, iTunes wouldn’t connect at all to the software update server, and just crapped after waiting 30 seconds to connect.
I discovered that this was a very common problem, and one that not too many were able to resolve. The most common suggested resolution involves editing the local hosts file on your Windows system (C:\windows\system32\drivers\etc\hosts). This is in fact a load of crap.
The reason why this is a suggested solution is because lots of people have installed Jailbreak software on their PCs. This software inserts an entry into the hosts file so that iTunes is directed away from Apple’s software signing server when doing restores. If that hosts file entry remains, you won’t be able to contact Apple’s signing server when you want to do a genuine restore, for a software upgrade for example, so removing the entry helps. However, for people who have never tried to Jailbreak, this is just a waste of time. In fact, such users won’t even find the rogue entry in their hosts file.
Digging a bit deeper, I discovered that iTunes lets you load the software upgrade from a local source, by pressing the Shift key at the same time as you click Restore.
Hence, if I could get my hands on the .ipsw file (this is the file type for Apple iOS updates) that needed to be loaded, I could bypass any issues Apple was having in connecting to the software upgrade server.
I looked around on the web for a source for such files and found this link:
The server, appldnld.apple.com, is located in the apple.com Top Level Domain, so I figured this was pretty safe. I opened the link in my browswer and the file started downloading. However, after 50mbs, it crapped out again.
Not wanting to give in on this, I tried a few other things. Suspecting that maybe my local network connection was not robust enough to deal with whatever bumpf was coming out of the Apple network, I logged onto my Linux hosting server in the Amazon EC2 cloud and initiated the download from there with wget. This worked a treat, and I pulled the .ipsw file down onto the server in about 2 minutes.
I then connected to this server using Filezilla and ftp’ed the file down to my local PC. I used Filezila because it can restart failed downloads without having to restart the download all over again, which is handy for large files like .ipsw files. Witin 30 minutes or so, I had the .ipsw file on my laptap.
(Note: hopefully you won’t have to do the step above, and have a good enough network connection to get the .ipsw with your browser)
Feeling certain that I had now conquered the Apple iOS 5.0 upgrade connundrum, I cranked up iTunes and used the Shift-Restore option to load the locally stored .ipsw file. It loaded it up and unpacked it, and then told me it was going to verify the software with Apple.
Bang. Game over. An unknown error has occured (Error 3194).
Not to worry, I thought, lets see what Error 3194 means.
Error 3194: Resolve error 3194 by updating to the latest version of iTunes. “This device is not eligible for the requested build” in the updater logs confirms this is the root of the issue.
Excellent. An obscure meaningless error message that Microsoft would have been proud of. I really shouldn’t have expected anything else.
So back to Google for some more research, and this time I found all sorts of interesting stuff.
Apparently, since the release of the iPhone 3GS, Apple will no longer let you install operating software on your iPhone unless that software is approved (signed) by Apple. This basically applies to everything other than the most up to date version of the iOS. Apple doesn’t want you loading older versions, because some of these let you do things that Apple doesn’t want you to do.
That means that whenever you use iTunes to upgrade or restore your iPhone, iTunes will scurry off home to Apple and check that the software you are trying to load is approved for your model of iPhone. This, it seems, is an attempt to stop people jailbreaking their iPhones, because Apple doesn’t really like people doing things with their hardware that they don’t approve of. As noted above, this is why jailbreaking software directs you away from Apple’s signing server, gs.apple.com.
Anyway, armed with this nugget of information, I contacted Vodafone to ensure that my iPhone was definitely unlocked. If Apple was refusing to allow me upgrade it, I figured this must be something to do with the status of the handset with the mobile operator to which it was issued.
Not so. Vodafone said that as far as they were concerned the handset was unlocked, and that I would have to copy Apple for technical support.
I did as I was instructed, and was eventually put through to one of their agents to whom I described my problem. He said that Error 3194 meant that I had security software running on my PC, which I needed to shut down. I assured him I hadn’t, and directed him to the Apple Support website which stated that Error 3194 concerned the eligibility of phones for upgrade. He then suggested I reboot my PC. I told him I wasn’t going to do this, and that he was wasting my time.
He got a bit flustered at this and put me through to one of this supervisors. This guy seemed to know a little bit more so I explained the actions I had taken thus far. However, when I told him that I had downloaded the .ipsw file directly from a download server, he sprang to life, and I knew I had made a mistake.
This was not possible to do, he stated, the only way to get the software was through iTunes, and the software that I was now trying to load was obviously a jailbreak image from a 3rd party and that this was why the upgrade wasn’t working.
I tried to explain to him that the download came from within the apple.com domain, which meant it was legit, and asked why iTunes allowed you to load a locally stored .ipsw file if it was not possible to get such a file directly from Apple.
No, he said, he worked for Apple and he knew what he was talking about.
I tried to convince him still further. I showed him that the appldnld.apple.com resolved to an IP address that was leased to Akamai Technologies, the Edge Caching company that facilitates all of Apple’s media downloads.
No, he said, he worked for Apple and he knew what he was talking about.
At this point, I let him and off and we went through his checklist for solving software upgrade issues.
We cleared the DNS cache. No difference. We created a new user account under Windows and tried the download using that (!!). No difference. We cleared the comments out of the Windows hosts file and rebooted (!!!!!!). No difference.
I asked him if he knew what server iTunes tried to connect to when doing upgrades, and on what TCP port, so that we could test that independently. He didn’t know any of these details, and seemed incredulous that he should be expected to know.
He eventually told me something to the effect that I would have to sign up with a new ISP if I wanted to upgrade my iPhone. At this point, I ended the call.
Some good did come of it, however. Having asked the question about the server iTunes connects to, I set about finding this out for myself.
I installed TCPView on my laptop, cranked up the iTunes upgrade process, and had a look at what it was connected to. I found out that it was connected to ip address 126.96.36.199 on HTTP to do the download. This ip address is leased to an Italian Telecoms company, and obviously forms part of Apple’s new iCloud product, or maybe one of Akamai’s Edge servers.
I also decided to see what Apple was trying to download, and looked in C:\users\garreth\AppData\Roaming\Apple Computer\iTunes\iPhone Software Updates, which is where iTunes keeps the .ipsw files it downloads from Apple.
Here, I found a file called iPhone2,1_5.0.1_9A405_Restore.ipsw.download, which was obviously the partial download of the full .ipsw file.
Now, notice the difference in this file name the the one I originally downloaded.
Yes, iTunes was trying to download a newer .ipsw file that the one I had downloaded! Of course, iTunes wasn’t letting me use my .ipsw file because a newer one exists, and Apple doesn’t allow you install older .ipsw files than the current up to date version.
Now, all I had to do was find a copy of the newer .ipsw file that I could download directly and try and load that.
I Google’ed iPhone2,1_5.0.1_9A405_Restore.ipsw and found the following link, which was again on the appldnld.apple.com server, the one that the guy in Apple support swore blind had nothing to do with Apple and was giving me jailbroken software:
UPDATE Sep 2012: Latest image is:
I downloaded this one in the same way as before (via my Linux server) and tried the Shift-Restore option again.
And guess what? It worked! The new iOS was loaded to my iPhone and I now have an unlocked iPhone that I can use on the O2 network.
So what do you need to know from all of this. A few things.
First of all, it is possible to load a locally stored .ipsw file into iTunes. You just need to ensure that it it the most up to date version of the iOS. The Tech Support guys in Apple are obviously not told this, and it would probably result in them get users to do all sorts of crazy things with their PCs, which could end up in Apple getting sued (“Woman strangles cat with computer cable while trying to upgrade iPhone” etc)
Secondly, you really should give serious consideration to using something other than an iPhone as your smartphone. The saga I have described above if very common in the iPhone user population, and is unheard of for Android users. I myself have an Android. I’ve updated the operating system on it twice. When it needs an upgrade, it tells me, and I then let it download the upgrade overnight, directly to the handset using WIFI. When I get up in the morning, its done. No hassle.
Also, my handset manufacturer, HTC, is quite happy for me to use whatever operating system I want on my phone, which is what I’d expect, given that I paid for it and own it. The fact that this isn’t the case with Apple, explained here, should be all you need to know.