ASPENSMONSTER Just another WordPress site

October 10, 2012

Upgrading from WoW 4.3 to Mists of Pandaria (5.0.5) on GNU/Linux (Debian Testing)

Filed under: Uncategorized — aspensmonster @ 2:26 am

Flattr this!

I’ve yet to actually purchase Mists of Pandaria. I figured I’d see how well updating the client goes over first before I sink 40 bucks (plus 15 for the month) into a paperweight. This guide makes the following assumptions, though it may hold valid under other conditions:

  • You previously had a working Cataclysm installation on your GNU/Linux machine (4.3.x)
  • You are now attempting to upgrade

Symptoms

  • The updater is attempting to dowload updates to setup files, i.e., “Updating Setup Files”. There is an icon with a small CD disk imposed on top of the usual WoW icon. The install will eventually fail here and reference an error “BLZPTS00007” .
  • Assuming you reach the point where the new updater arrives, it appears stuck on “Reconfiguring game files. Please wait.” and it will only display zero.

Solutions

First: Cleaning up

First things first, kill off any stale processes you have laying around from previous attempts at getting this thing to work. Find the pids of all processes relevant to “WoW” or “Launcher.exe” or “Agent.exe” or “wine”:

ps aux | grep -i Agent.exe
ps aux | grep -i wow
ps aux | grep -i wine

Kill of all relevant pids. For example:

$ ps aux | grep Agent
preston   1035  0.4  0.1 2663436 16212 pts/3   Sl   22:29   0:04 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston   1077  3.5  0.1 2662636 16364 pts/3   Sl   22:30   0:38 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston   1108  0.3  0.1 2662636 16196 pts/3   Sl   22:30   0:04 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston   1146  0.4  0.1 2662572 16380 pts/3   Sl   22:31   0:04 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston   1651  2.2  0.1 2662856 16316 pts/4   Sl   22:46   0:03 ./Agent.exe --nohttpauth                                      
preston   2572  0.0  0.0   7820   868 pts/2    R+   22:48   0:00 grep Agent
preston  32655  0.2  0.1 2662632 16172 ?       Sl   21:40   0:10 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston  32685  0.2  0.1 2661544 16168 ?       Sl   21:41   0:10 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston  32718  0.2  0.1 2662568 16180 ?       Sl   21:41   0:10 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      
preston  32753  0.2  0.1 2661608 16180 ?       Sl   21:42   0:09 C:/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040/Agent.exe --locale=enUS                                      

As you can see, I gave this quite a few go’s before I got it. Running the following should work:

$ killall Agent.exe
$ killall Launcher.exe
$ killall Wow.exe

Just be sure to kill off all relevant processes to the launcher, game client, and Agent.exe to make sure you’re starting from scratch.

Second: Cleaning Agent.exe

Prep your updater. This mainly involves getting the Agent.exe ready. My understanding is that this program performs the actual communication between your PC and the update servers.

cd ~/.wine/drive_c/windows/profiles/All\ Users/Application\ Data/Battle.net/Agent/

According to other blogs and forums online, the path might be different. Regardless, once you find the folder, delete whatever Agent.$some_number folder is there:

$ pwd
/home/<your-user-name>/.wine/drive_c/windows/profiles/All Users/Application Data/Battle.net/Agent
$ ls | grep -i Agent
Agent.1024 Agent.exe
$ rm -r Agent.1024

Your folder will probably be numbered differently. Delete the folder. Then, run Launcher.exe in order to generate a new folder (I’d keep the original terminal open, so you can watch for when a new Agent.$some_number folder appears):

$ cd ~/.wine/drive_c/Program\ Files/World\ of\ Warcraft/
$ wine Launcher.exe

Once the Launcher starts and you can see the new folder, kill the Launcher process. You can also close the other terminal that you used to watch for the new Agent.$some_number folder.

At this point, kill all pids relating to Agent.exe, WoW.exe, or Launcher.exe.

Third: Prepping Agent.exe

Start the Agent.exe process with the following flag “–nohttpauth” as follows:

$ ~/.wine/drive_c/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1024/Agent.exe --nohttpauth &

The intent of the ampersand is to put the process in the background. Regardless, for me it kept spitting output to STDOUT, which turned out to be useful.

Once the Agent.exe process is running, start the Launcher.

Fourth: Starting the launcher

In another terminal, start the launcher. At this point, you should have two terminals open:

  • One watching the output of Launcher.exe
  • One watching the output of Agent.exe
cd .wine/drive_c/Program\ Files/World\ Of\ Warcraft/
wine Launcher.exe

At this point, I got past the first symptom regarding the “Updating Setup Files” message. At this point, it finished updating the setup files and proceeded to show me this:

stuck-at-zero-mists-of-pandaria-optimizing

This remained at zero for a full 20 minutes. Apparently, this is happening to lots of other people. Regardless, if you watch the terminal output from the Agent, you’ll see lots of these chunks:

fixme:process:GetLogicalProcessorInformation (0x4bfe334,0x4bfe934): stub
fixme:process:GetLogicalProcessorInformation (0x4bfe364,0x4bfe964): stub
fixme:process:GetLogicalProcessorInformation (0x4bfe334,0x4bfe934): stub
Request Issued: GET /install/wow_enus

Response: 200
{
	"playable" : false,
	"progress" : 0.083539,
	"playable_progress" : 0.273582,
	"download_rate" : 641473.000000,
	"streamed_bytes" : 15328977.000000,
	"written_bytes" : 2548552479.000000,
	"time_playable" : 2186.000000,
	"time_complete" : 9033.000000,
	"state" : 1002.000000
}
fixme:process:GetLogicalProcessorInformation (0x10ee398,0x10ee998): stub
fixme:process:GetLogicalProcessorInformation (0x4bfe364,0x4bfe964): stub
fixme:process:GetLogicalProcessorInformation (0x4bfe334,0x4bfe934): stub

I don’t know whether you’ll get the fixme bits. I got tons of them that drowned out the other important piece regarding the Request and Response. As shown here, it shows a progress that isn’t zero. As I watched terminal output, this number slowly crawled up.

However, the thing then crashed… And I was sad 🙁

Fifth: Updater Crashes

Once the updater crashed, wine showed me the typical “an error has occured” dialog, but no error was given. The Launcher remained open when I closed out of this prompt. Closing the launcher prompted me to another “an error has occured” wherein an error was given. Regardless, I noticed that the Agent was still running and giving strange output:

Recomputing Progress
13103.267840, 20028.850176, 0.903861
OnProgress:
	source = 3
	section = 1
	progress=1287651328
,3,1,1287651328
Recomputing Progress
13104.578560, 20028.850176, 0.914620
OnProgress:
	source = 3
	section = 1
	progress=1288962048
,3,1,1288962048
Recomputing Progress
13105.364992, 20028.850176, 0.937675
OnProgress:
	source = 3
	section = 1
	progress=1289748480
,3,1,1289748480

I decided to kill all Launcher.exe , WoW, and Agent.exe pids and start at it again. I kept getting the same errors. I deleted all Agent.$some_number folders that had collected (two of them in my case) and attempted to run the launcher again, which apparently has a new name:

$ pwd
/home/preston/.wine/drive_c/windows/profiles/All Users/Application Data/Battle.net/Agent/
$ ls | grep Agent
Agent.1024 Agent.1363
$ rm -r Agent.1024 Agent.1363
$ cd .wine/drive_c/Program\ Files/World\ Of\ Warcraft/
$ wine World\ of\ Warcraft\ Launcher.exe

But still kept getting errors. I was about to start flipping tables. But then I recalled that I was performing the following to start the Agent:

$ cd ~/.wine/drive_c/windows/profiles/All Users/Application Data/Battle.net/Agent/Agent.1040
$ wine Agent.exe --nohttpauth

and I observed the following error:

Incremental patch:
	-source url: http://dist.blizzard.com.edgesuite.net/tools-pod/NA/a1363/a-1040-1363-win.mpq.torrent.7193FE67072EFF34ADB4395B6156F494
	-dest: C:\windows\profiles\preston\Temp\Blizzard\AgentUpdate_B62A766D\a-1040-1363-win.mpq

<snip>

UpdaterImpl - Applying incremental patch failed.
UpdaterImpl -   ERROR: Blizzard Updater is unable to write to this location because it is a system directory.
Full download patch:
	-source url: http://dist.blizzard.com.edgesuite.net/tools-pod/NA/a1363/a-1363-win.mpq.torrent.03F61678280BFC0290E5D5A60B21C6BE
	-dest: C:\windows\profiles\preston\Temp\Blizzard\AgentUpdate_7DEFEBF3\a-1363-win.mpq

Okay. So the Agent.exe is going from revision 1040 to revision 1363. No biggie. But clearly, this process is failing. I tried running it this way:

$ wine .wine/drive_c/windows/profiles/All\ Users/Application\ Data/Battle.net/Agent/Agent.1040/Agent.exe --nohttpauth

and LO AND BEHOLD it fucking worked. Why that should make a difference, I don’t know. But I don’t like the inconsistency. So I did the following…

Sixth: Getting Agent.exe to patch properly

First, delete Agent.1040 (or any other Agent.$some_number folder). Then, run the launcher again:

$ cd .wine/drive_c/Program\ Files/World\ Of\ Warcraft/
$ wine World\ of\ Warcraft\ Launcher.exe

At this point, you’re back to “updating setup files.” Just let this fail out in a few minutes. It should have redownloaded the Agent at patchlevel 1040 (or some other level, I’m assuming at this point it might be the same for you).

Now, run the Agent.exe like so to get it to patch to the new level.

$ wine .wine/drive_c/windows/profiles/All\ Users/Application\ Data/Battle.net/Agent/Agent.1040/Agent.exe --nohttpauth

you’ll know it’s successful when this happens:

Post Response:
<patch>
<record program="Bnet" component="Win">
http://attdist.blizzard.com/sc2patch/update/B16117-5C52FCF1/sc2-1-22280-x86-Win-enUS-bnet-bin-component-dl;sc2-1-22280-x86-Win-enUS-bnet-bin-component-dl;69B17A0F007E49F5B37E2876C87A17DA;22280
</record>
<record program="Agnt" component="cdn">
dist.blizzard.com.edgesuite.net|llnw.blizzard.com|attdist.blizzard.com
</record>
<record program="Agnt" component="Win">
;;;;
</record>
</patch>

If it fails again, “killall Agent.exe” and try again.

At this point, you should be patched to 1363. Kill the agent and make sure that when you restart the agent (using the NEWER revision), the following behaviour resumes:

Start the new Agent:

$ wine .wine/drive_c/windows/profiles/All\ Users/Application\ Data/Battle.net/Agent/Agent.1363/Agent.exe --nohttpauth

(use whatever number is highest for you)

And then as Agent.exe is running you’ll see this:

OnProgress:
	source = 3
	section = 1
	progress=31719424
,3,1,31719424
Recomputing Progress
15847.129088, 20028.850176, 0.979634
OnProgress:
	source = 3
	section = 1
	progress=32505856
,3,1,32505856

Seventh: It’s working… maybe?

At this point, I believe the updater is actually working. I see lots of network traffic indicating heavy downloads. And if I look at the 200 responses in terminal (from the Agent.exe process) I get the impression that it’s updating whenever I run the new launcher like so:

$ cd .wine/drive_c/Program\ Files/World\ Of\ Warcraft/
$ wine World\ of\ Warcraft\ Launcher.exe

The launcher WILL CRASH, but right before it does I see this in terminal of agent:

Request Issued: GET /update/wow_enus

Response: 200
{
	"playable" : true,
	"progress" : 0.678491,
	"playable_progress" : 1.000000,
	"download_rate" : 0.000000,
	"streamed_bytes" : 0.000000,
	"written_bytes" : 0.000000,
	"state" : 1007.000000
}

If I try and run the launcher again later:

Request Issued: GET /update/wow_enus

Response: 200
{
	"playable" : true,
	"progress" : 0.704574,
	"playable_progress" : 1.000000,
	"download_rate" : 0.000000,
	"streamed_bytes" : 0.000000,
	"written_bytes" : 0.000000,
	"state" : 1007.000000
}

I’m getting the distinct impression that the launcher is simply broken at this point. Granted, it appears to be broken for people on windows too, reporting issues about the progress bar not moving, but seeing plenty of disk and network activity to indicate that it is indeed working.

Eighth: Does it load?

Indeed, If I run Wow.exe directly, the game loads! With the new Mists of Pandaria ToS and other legal jargon, along with a new background. I have yet to shell out 15 dollars to see if the game runs as expected, however. I’ll update later, as I’m pretty damn exhausted.

FINAL

Honestly, you might be better off just wiping and redownloading the installer from Battle.net, but if you insist on following the above steps, I hope they were helpful. The gist is to get a functional Agent.exe operating and updating the client. At that point, the launcher will still be broken, but the game WILL be updating. I’ll update later with how playable it is.

UPDATE: Just shelled out the 15 bucks. The game is playing nice and smoothly. Well, after I dealt with some libXi hiccups that seem specific to debian… I’ll update later if someone comments indicating a need for help with libxi libX11-6 probs on Debian.

UPDATE AGAIN: I had an 85 Marksmanship Hunter. Looks like the talent system has been COMPLETELY reworked. No-focus aim shot at 3 stacks of steady shot? Thrill of the hunt that gives you the ability to basically spam arcane shot? Various tweaks to disengage that will actually keep you from getting yanked back into the fray instead of just death-gripped back? What is this magic?!?! So basically, when it comes to PvP (OR raiding), I’m back to square one. Lovely.