I cannot start Firefox on my Mac. It just says "A copy of Firefox is already open. Only one copy of Firefox can be open at a time." I have tried restarting the computer. Any fixes?


You have suggested deleting the lock files in my profile, but, I don't have a profile. I was trying to fix the problem in question http://superuser.com/questions/3275/firefox-on-mac-slow-slow-slow by deleting my profile, so I deleted it, and this came up. So I cannot delete the lock files because they don't exist.

link|improve this question

feedback

10 Answers

up vote 3 down vote accepted

To remove .parentlock files you can run the following command in the Terminal:

rm -f ~/Library/Application\ Support/Firefox/.parentlock

(It's not in your profile)

However as said before, removing a .parentlock file won't help fix a stuck Firefox process.

link|improve this answer
1  
This doesn't work, I think the file is in the profile (am I wrong?) – Isaac Waller Jul 20 '09 at 17:02
On Mac OS X by default for Firefox it's not in the profile but in Firefox's Application Support folder. – Chealion Jul 20 '09 at 18:41
I ended up deleting the whole Application Support/Firefox folder. There was no .parentlock file in it (I do have hidden files on), but still, deleting it made it come back up. Thanks, – Isaac Waller Jul 21 '09 at 2:55
1  
I just had to kill of FF and saw that the .parentlock file was located (for my system and profile) in the directory "~/Library/Application\ Support/Firefox/Profiles/8vaea85u.default/" – Peter M Jan 21 '10 at 20:16
feedback

Firefox writes two lockfiles, if they are not deleted during shutdown you have to remove them manually. They are called lock and .parentlock and located in the profile folder.

MozillaZine has an article on how to do that on the Mac.

EDIT: On OS X only .parentlock exists, so it should be enough if you delete that file. The file will have 0 KB size, so you can delete it with no worry.

link|improve this answer
Where are these lockfiles located? – Isaac Waller Jul 20 '09 at 5:55
Aha! I don't recollect such behavior on Unix/Windows.. Is this specific to OSX? If so, that will explain persistence across reboot. – nik Jul 20 '09 at 5:56
See edit above. – Isaac Waller Jul 20 '09 at 6:01
@Isaac Waller: Updated the answer with a reference to an article that describes how to find the files on different platforms. – user1863 Jul 22 '09 at 16:16
feedback

Somehow the Firefox process is still running even after you close the program.

First, right click on the Firefox icon and try clicking Force Quit.

If that option is not there, press Option + Apple + Esc. This will bring up a list of running programs. Select Firefox and press Force Quit

If all else fails, type killall -9 firefox into the terminal. This should force the process to close, allowing you to start Firefox again.

link|improve this answer
I tried this all before posting the question - Firefox is not running. – Isaac Waller Jul 20 '09 at 5:56
feedback

This kills all firefox processes on Linux:

pgrep firefox | xargs kill -9
link|improve this answer
feedback

If firefox sees an active instance of itself when it starts, it skips creating another instance of itself with this error.

What do you mean by the statement, "I tried restarting"?
Did you reboot and this still persists?

I am not familiar with OSX enough to comment further on its behavior.

link|improve this answer
feedback

On OS X, if deleting the .parentlock or killing the process does not work, you may need to edit/delete the profiles.ini file. I encountered the problem while making multiple Firefox profiles and resolved the issue be deleting all but the default profile from the profiles.ini (not the profile dir). I think the cause in my case was the use_last_profile setting was enabled and the last used profile no longer existed (profile dir deleted).

link|improve this answer
feedback
 # There is a command that combines the pgrep with kill, he's pkill. So

 pkill firefox
link|improve this answer
feedback

This question got enough answers but I think this good to know too. On Mac, sometimes Firefox comes up with a red stripe that says something like "Your history and bookmarks will not be available because some other application is using them." When this happens you can't go backward/forward in your browser and it's really annoying. The solution is removing the file "places.sqlite.lock" in your Firefox profile directory. If you don't know how to locate your profile, read this: http://kb.mozillazine.org/Profile_folder#Where_is_my_profile_folder.3F

link|improve this answer
feedback

The lazy way to delete these lock files:

find ~/Library/Application\ Support/Firefox -name "*lock*" -exec rm {} \;

This will find and delete any file with "lock" in the name. See the man page for find for more information.

link|improve this answer
feedback

The lazy way to delete these lock files:

find ~/Library/Application\ Support/Firefox -name "*lock*" -exec rm {} \; This will find and delete any file with "lock" in the name. See the man page for find for more information.

Don't do this at home, or try without -exec rm {} \; first, assuming you don't want to remove "adblockplus" and other useful files with "lock" in their names.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.