Found a very odd Flex Builder / MS Network bug today. The profiler wouldn’t run, and reported
“unable to connect to the application to fetch profile data. Please try profiling the application again”.
It turns out that on my home machine, everything ran fine, but on the office machine the profiler just plain refused to start up. After some googling I found that it was to do with the office network, Active Directory and my Home Drive.
When you profile an application the IDE writes to the mm.cfg file on your local machine. It adds in a pre-loader that runs before your application is started – this allows the IDE to connect to the app to get the profiling data.
Once it has written to the file it’s loaded again – and it’s this second load that fails when you log in with a domain account.
Instead of loading the mm.cfg file from my local user dir (C:/Users/matt.bryson/mm.cfg), it was trying to load it from my home drive on our network (H:/matt.bryson/mm.cfg) !!
Not sure why, not sure if this is a Flex builder issue, Flash Player issue or an AD/network issue, but a simple workaround is to run the profiler (so it writes the relevant data the mm.cfg file) and then copy the mm.cfg file to the root of your home dirve.
Now re run the profiler and it will successfully load the pre written mm.cfg file from your home drive and your off!
Strange but true.
OS specific mm.cfg file location can be found here