'CONNECT ERROR: Please check for sufficient write file permissions

In my Magento site:I am trying to install a plugins via magento connect manager, I copy and paste the extension key then click install and then proceed.I get error

CONNECT ERROR: Please check for sufficient write file permissions.
Your Magento folder does not have sufficient write permissions, which downloader requires.

Even though all my folders are in 0777 permissions.

Folders and permissions:

    app/code/community-0777 
    app/etc/modules-0777 
    app/design/adminhtml/default/default/template-0777 
    app/locale-0777 

any one have better solution for this? .

thanks in advance.



Solution 1:[1]

Magento provide cleanup tool to resetting file and directory permission. Check this link: http://www.magentocommerce.com/wiki/groups/227/resetting_file_permissions

Hope will help!

Solution 2:[2]

Go inside your Magento folder & change permissions of ALL FILES & FOLDERS RECURSIVELY to “777”.

copy and paste the following command from your putty.

find . -type d -exec chmod 777 {} \;
chmod 666 downloader/config.ini

You may also need to change the permissions on the pear download file to be able to properly install Magento Connect packages:

chmod 777 downloader/pearlib/download/package.xml

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Rajiv Ranjan
Solution 2 Arpit Jain