If, in the course of your website, you use the Magento Downloader, you receive an error crying, “ERROR: failed to mkdir”, here’s a tip I just figured out.

If you moved your Magento to a new domain, check your path’s in your Downloader PEAR.ini file (/downloader/pearlib/pear.ini). In my case, when i changed the domain name Plesk changed the saved folder name as well.  You can get an updated path by creating a PHPINFO file and saving it in there and checking the values there.  If the path isn’t the same as what’s in that serialized array, you’ll have to update all the paths in the PEAR.ini file.  Also be sure to update the string length, or PHP will throw another error.

Source: GTGreg – http://www.gtgreg.com/101-magento-downloader-error-failed-to-mkdir

Tip from “Magento” on GTGreg’s  comments which worked for me was:

You can also just delete the pear.ini file. Through FTP or SSH, it’s the same. (BEFORE YOU DO THIS BACKUP THE PEAR.INI FILE)

Hope this Helps!