Invalidating Preferences Cache in Mavericks (OS X 10.9.x)

I recently set up a fresh install of Mavericks (OS X 10.9), and copied over some of preferences (plist) files from old installation to new box ( (~/Library/Preferences).

I noticed, applications failed to use (manually copied) preferences files, instead kept throwing errors (like one shown below):

cfprefsd[xxxx]: CFPreferences: error renaming file /Users/username/Library/Preferences/com.codeux.irc.textual.plist.bPsEnTV to /Users/username/Library/Preferences/com.codeux.irc.textual.plist

Unlike previous versions of OS X, Mavericks (OS X 10.9) caches preferences files. That means, if we edit or overwrite a preferences (plist) file, we need to invalidate the cache so that applications can see the changes, and start using this updated preferences file.

I didn't want to set up everything from scratch, in this case all IRC servers, nodes and chatrooms. It is not fun editing binary plist files, even with the help of XCode :-)

To fix this problem, we need to run this from terminal:

defaults read ~/Library/Preferences/com.codeux.irc.textual

We also need to make sure preferences file has correct permission. In my case, permissions were messed up because I copied file from different disk (installation).

Permission should look like following (i.e. owner can at least read/write; umask 077):

-rw-------

I would suggest restarting the respective application, if it is already running.