Magento – Why can’t I reinstall Module Magento

-setupdatabaseinstallmodulescript

I have a module in magento, and the script setup module. Now I want to re-run this script and this module.
I deleted the setup of this module in core_resource, and access magento. But the module is not reinstalled. The database of this module isn't deleted, although I have DROP TABLE IF EXIST in scripts. And in the core_resource, the setup of this module not exists, it is really deleted. So I think the setup not run. But this module still work normally with old sql and no setup field in core_resource.

Best Answer

This possibly is a cache or compilation issue. The module may still be working in the frontend, but in fact be disabled. So check the status of the module in System > Configuration > Advanced > Advanced and also in app/etc/modules/yourmodule.xml. In this file you should see <active>true</active>.

If the module is properly enabled and flushing all cache did not help then this is what I would do in this situation (it's quite a lot of work):

  1. First, make sure you have a complete backup (file system and database)
  2. Then make sure compilation is disabled in System > Tools > Compilation
  3. Disable all cache in System > Cache Management
  4. Disable the troubling module in System > Configuration > Advanced > Advanced
  5. Logout of the admin panel
  6. Use FTP or SSH to remove all of the modules directories and files from the file system
  7. Use FTP or SSH to delete the following directories (if present)

    [your Magento install dir]/includes/src/
    [your Magento install dir]/media/css/
    [your Magento install dir]/media/css_secure/
    [your Magento install dir]/media/js/
    [your Magento install dir]/var/cache/
    

IMPORTANT: Don't delete the entire includes/ media/ and var/ directories, only the subdirectories I mentioned above!

  1. Reinstall the module by uploading all files
  2. Login to the admin panel
  3. Enable the troubling module in System > Configuration > Advanced > Advanced
  4. Clear all cache again in System > Cache Management
  5. Reindex in System > Index Management
  6. Logout of the admin panel and back in

If this doesn't help then repeat all steps above and between steps 6 and 7 do the following:

6,5. Remove all tables and entries of the module from the database. After core_resource don't forget to also check the core_config_data table for entries of the troubling module

NOTE: You will lose al your modules settings when performing this final step

Hope this is helpful!

Related Topic