I use Google Chrome as my default browser. So when I started getting errors saying "Your profile could not be opened correctly" , it was quite annoying. I tried lot of fixes on my own and nothing seemed to work. I checked the forums and most of the solutions were to basically create a new profile which was not acceptable to me.
I had quite a bit of idle time today and hence decided to find the root cause. One of the main reasons for my anxiety was the nagging doubt that this might be due to my recent Chrome Extension – Chrome Nanny (for more details see Chrome Nanny – A Leech Block like Extension for Chrome ). It turned out that my extension was innocent but in the process , I found the root cause !
The cause of this issue seems straightforward – Some file or database is corrupted. I tried opening all SQLite databases and they all worked correctly. Most of the other files (esp which had JSON data) too seemed fine to me. The remaining was some data files and I had no way to find how to verify their integrity.
I was able to finally solve the issue. I had few solutions which should work. I had listed all of them – so use the one which works for you.
Method 1 : Check if there is any zombie processes
This is probably the most common scenario. If you get an error “Your profile could not be opened” , close all Chrome windows. Now check using ps if there is any chrome process still alive. A simple ps –aux | grep –i chrome or ps –aux | grep –i chromium should do. If there is any processes still alive kill them (use kill, pkill or killall). Make sure all chrome processes are dead and start Chrome again. If the error does not come again, great ! Else follow the other steps.
If you are in Windows, then use the task explorer to kill all chrome processes.
Method 2 : Removing Web Data file
Try this method first as this was the issue in my system. Google Chrome has a file called "Web Data" which stores lot of info in it – including your passwords (wink wink). In my case this file was corrupted. I deleted this file and all worked well.
If you are in Linux , you can find the "Web Data" file at ~/.config/google-chrome/Default (if you are using Chrome) or at ~/.config/chromium/Default (if you are using Chromium). If you are in Windows (atleast in Windows 7), the file is at C:\Users\<username>\AppData\Local\Google\Chrome\User Data\Default\ . Delete the file and restart Chrome. Hopefully everything should work well. Of course, you will lose all your stored passwords and the search engines.
Method 3 : Check if any of the SQLite databases is locked
Chrome uses SQLite to store lot of information. Some times, the database might be locked and Chrome might not be able to access it. In this case, follow Kyron’s script in this Chrome forum.
Basically what he does is this : he dumps the SQLite database data into an SQL file, deletes the database , recreates it using the SQL file. This script should work if you are in Linux. (I think it should work for Mac too). His script is written for Chromium. If you are using Google Chrome, change the folder ~/.config/chromium/Default/ to ~/.config/google-chrome/Default/ .
Method 4 : Creating a new profile with most of the data from old profile
This method is very similar to the previous methods where instead of removing "Web Data", it tries to create a new profile with most of the useful data from old profile copied in to it. The steps are :
a) Rename the Default folder at ~/.config/google-chrome/Default or ~/.config/chromium/Default to say backup. For Windows, the folder is at C:\Users\<username>\AppData\Local\Google\Chrome\User Data\Default\
b) create a new folder with name "Default"
c) copy the files/folders given below from original Default folder (currently named as backup) to the new Default folder one by one . After each step, try opening Chrome to see if the error comes. If an error comes, then the latest object you copied caused the issue.
Extensions folder (contains all your extension’s source code)
Local Storage folder : copy only files beginning with "chrome-extension_" (other files are most likely not needed )
History* (all your history )
Again note that you will get a profile that is very close to the previous profile but it will not have the old stored passwords or the custom search engines you had.
Hope this post helped to solve a nagging issue !
[Update 12 May 2010] : Added more scenarios.
If you liked this post , please subscribe to the RSS feed.