• Resolved jitsiereveld

    (@jitsiereveld)


    I have a number of sites in subdirectories on my server that have all started displaying this error message.

    Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0

    Fatal error: Unknown: Failed opening required ‘/home/CENSORED/public_html/COMMON_DIRECTORY/wordfence-waf.php’ (include_path=’.:/opt/alt/php54/usr/share/pear:/opt/alt/php54/usr/share/php’) in Unknown on line 0

    Now, I was cleaning up the server when I deleted the COMMON_DIRECTORY that is in the error message. The site that was using it has been launched and is on a new server so I figured I didn’t need it anymore. That reminded me of a message I saw during setup about sites in subdirectories, but I can’t remember what it said for me to be able to figure out how to fix this.

    Can you tell me what the special notice about having sites in subdirectories is? Or what I need to do to get those sites back up?

    https://ww.wp.xz.cn/plugins/wordfence/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter jitsiereveld

    (@jitsiereveld)

    Sorry for my lack of patience, but one of the sites that is down now is a clients site that I am hosting and I need to get it back up asap…I’m not even sure if WordFence was installed on more than half of these subdomains that are down, since most of them are just development/demo sites.

    Reading through some of the other topics here, I tried adding the WordFence Assistant plugin and disabling my Firewall on the site using my root directory and now I can’t access that site either. Trying to fix it made things worse, please advise!!!!

    Plugin Author wfryan

    (@wfryan)

    The file it’s saying is missing is the core file for Wordfence’s Web Application Firewall. You should be able to get up and running by following the steps in the last section here to manually uninstall that portion: https://docs.wordfence.com/en/Web_Application_Firewall_FAQ#How_can_I_remove_the_firewall_setup_manually.3F

    • Depending on your server’s setup, you may have changes in the files .htaccess, .user.ini, and php.ini, all in the site’s main directory.
    • Wordfence surrounds its code with comments “Wordfence WAF” and “END Wordfence WAF” in the files it modifies. You can remove the code between these comments in these files:
    • .htaccess code varies by server configuration, but is surrounded by the comments mentioned above
    • .user.ini is only used on some server configurations, but if it exists, Wordfence code is surrounded by the comments mentioned above
    • php.ini is only used on some server configurations, and would have a single line beginning with “auto_prepend_file”
    • The file wordfence-waf.php in the site’s root folder can be removed after the files above are updated.
    • Important: If your host uses .user.ini or a PHP cache, the changes can take 5 minutes or so to go into effect. You may see white screens or error messages during this period.
    Thread Starter jitsiereveld

    (@jitsiereveld)

    Hey wfryan,

    Those steps to manual uninstalling the WordFence Firewall were the last things that I had done. After installing WordFence Assistant and creating another problem, I decided to FTP and remove all traces of WordFence.

    The plugin directory has been removed and any mention of WordFence in each of these files (.htaccess, .user.ini, php.ini) as well.

    Sites are all still down displaying those messages. The directory those messages are referring to is completely gone.

    Any other ideas?

    Thread Starter jitsiereveld

    (@jitsiereveld)

    It was cached, it looks like they are all coming back up now. Can’t believe I had to remove WordFence from my main site, but that is what I get for not reading about having WordFence on sites in subdirectories.

    Thanks for your help!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Fatal error: Unknown: Failed opening…’ is closed to new replies.