1. nicolas81's Avatar
    Hey everyone!

    I've finally, finally solved a problem I've been dealing with for the past month (since updating DM to the latest version 6.x.35)

    I have a BB Bold 9700 with OS ( by the way the issue is not related to the OS as I had the error prior to getting this version).

    The problem is that when opening DM, everything is fine AS LONG as I don't connect my phone. As soon as I do, DM crashes with the dreaded "DM has stopped working" message. I tried literally everything... Browsed many forums and found onyl questions without answers... Turns out hundreds of BB users faced the same problem on various BB models. Out of these I can honestly say, only 2 managed to fix the issue they were facing.

    To start with and to help people identify if my issue is similar to the one they are facing, I'll paste the issue as shown in : Rim.Desktop.Exception.log

    14:47:54.860|FATAL|10|Exception|0|Fatal Error
    System.IO.IOException: The directory name is invalid.

    at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
    at System.IO.Directory.InternalGetFileDirectoryNames( String path, String userPathOriginal, String searchPattern, Boolean includeFiles, Boolean includeDirs, SearchOption searchOption)
    at System.IO.Directory.GetFiles(String path, String searchPattern, SearchOption searchOption)
    at System.IO.Directory.GetFiles(String path)
    at Rim.Common.Filesystem.Win32FileSystem.<GetFiles>d_ _7.MoveNext()
    at Rim.Common.Filesystem.FolderPath.<GetChildren>d__3 `1.MoveNext()
    at Rim.Common.Filesystem.FolderPathExtensions.<GetChi ldFiles>d__6.MoveNext()
    at Rim.Media.Common.LibraryIdVersionManager.UpgradeWm sFilesForWmp(IFolderPath settingsFolder)
    at Rim.Media.Common.LibraryIdVersionManager.UpgradeTr ansactionFiles(IFolderPath settingsFolder)
    at Rim.Media.Device.BlackBerryInfo.CreateDriveInfo(Me diaPaths mediaPaths, MediaDestinationType destinationType, IInterruptibleFileSystem fileSystem, Boolean isContentStore)
    at Rim.Media.Device.BlackBerryInfo.RefreshDriveInfo(B oolean isDftpMode, Object token)
    at Rim.Media.Device.DeviceService.OnDeviceAcquired(ID evice device, Object token, DeviceAcquireResult result)
    at Rim.Desktop.Services.DeviceManager.Device.Internal Login(List`1 loginActions, Boolean isPrivate)
    at Rim.Desktop.Services.DeviceManager.DeviceManager.P rocessDeviceLoginRequest(Device device)
    at Rim.Desktop.Services.DeviceManager.DeviceManager.< LoginCurrentDevice>b__11()
    at Rim.Desktop.Services.Tasks.Task.RunOneOperation()
    at Rim.Desktop.Services.Tasks.Task.Run()
    at Rim.Desktop.Services.DeviceManager.DeviceManager.h andleWork(DeviceManagerWork work)
    at Rim.Common.Utilities.QueueWorkThread`1.ThreadProc( )
    at System.Threading.ThreadHelper.ThreadStart_Context( Object state)
    at System.Threading.ExecutionContext.Run(ExecutionCon text executionContext, ContextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()

    Now my problem is that unlike other error logs posted by users on various forums, mine didn't show what the issue was... There is a gap between the 1st and 2nd lines in the log. In all error logs I saw, that missing line was supposed to hold details on the issue. In my case, the "invalid directory name".

    I tried reinstalling DM without success and after seeing that so many people on the web had given up considering RIM was not taking any action, I joined the club and even made the decision not to buy the 9900 once it is released. I use the phone heavily for work and cannot deal with poor customer support.

    Finally today, for some reason while working on resolving an issue in an application I use at work, I decided to use a tool for trying to solve the DM crash... The tool is Process Monitor (procmon.exe) and is an AMAZING tool to see exactly what happens when you run any process (executable or others).

    Granted it's not very accessible and users who don't work in IT might not be familiar with many terms/features in this tool, but I honestly don't think there is any other way to identify the problem you're facing in DM.

    In my case I noticed in the captured activity of Process Monitor that there were two "path not found" issues just before the activity related to writing into the error log started. The 2 paths were :
    F:\BlackBerry\system\Media Sync\xxxxx.system
    C:\Users\Nicolas\AppData\Roaming\Research In Motion\BlackBerry Media Sync\<mypin>.settings

    First path is on the blackberry itself and in my case I had a file named "media sync" but no folder. I renamed that file and created the folder with that name.

    For the 2nd path, which was very strange, I could not find a file matching my BB pin... There was another one matching my wife's pin. I just took a copy of it and renamed it to my pin number.

    After these 2 adjustments I reopened DM and I got a message that a new device had been detected. I did a few settings and my BB connected successfully... No crash... I tried syncing, backup and everything seems to be working fine now.

    I hope this helps others in investigating the issues they are facing. By the way in Process Monitor be sure to first access the Filter options and select process name as : "rim.destop.exe"
    This will monitor ONLY the activity related to DM.
    Last edited by nicolas81; 07-05-11 at 02:10 AM.
    07-03-11 04:04 AM
  2. MobileMadness002's Avatar
    Awesome. Although I have not experienced this error myself, it no doubt will assist others and possibly myself in the future.

    Thanks for taking the time to provide your solution to us.
    07-03-11 04:22 AM
  3. nicolas81's Avatar
    You're welcome! I just had to post my findings online as so many people have taken the extreme measure of selling their phones and moving to different brands because of this... Hopefully I'll be able to help some people save a few bucks by providing them with the tools to solve the issue. AND avoid going nuts with RIM's terrible support regarding this issue...
    07-03-11 04:50 AM