We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 18878
    • 210 Posts
    Hi,

    I had Modx 0.9.6 running perfectly for a year or so on a LAMP server.

    Today, while I was browsing the manager, I suddenly started getting this errors:

    Warning: fopen() [function.fopen]: Unable to access /home/supropia/public_html/manager/media/style//login.html in /home/supropia/public_html/manager/includes/accesscontrol.inc.php on line 128
    
    Warning: fopen(/home/supropia/public_html/manager/media/style//login.html) [function.fopen]: failed to open stream: No such file or directory in /home/supropia/public_html/manager/includes/accesscontrol.inc.php on line 128


    Now everytime I try to access the manager I get the above message. The frontend is also down (totally blank).

    I read in other posts that this might be a assets/cache problem? (http://modxcms.com/bugs/task/622)

    But... why did it happen all of a sudden?

    Regards.

    Mc
      • 25663 MODX Staff
      • 12,272 Posts
      Is it possible your host upgraded the server or made some other configuration change?
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 18878
        • 210 Posts
        Quote from: rthrash at Oct 28, 2008, 03:40 AM

        Is it possible your host upgraded the server or made some other configuration change?

        Ryan,

        Thanks for the quick reply. I sent them a few tickets an hour ago, and they replied that no change or upgrade was made. Another thing: I found the files siteCache.idx.php and sitePublishing.idx.php with permissions set to 0644. Strange because I always set them to 0777 after I upload my files the first time. I also contacted my host and asked about this (possible) permission changes, and this is their reply:

        Quote from: my
        Regarding the subject of permissions, all of our new servers (your’s included) run PHPSuExec. On most Apache servers, PHP runs as an Apache Module. As such, it runs directly in the user "nobody", but doesn’t require the execute flag. This means that in order to execute a PHP file, it simply needs to be world readable. The problem is that this allows every other users on the server to read your PHP files! Allowing other users to read your HTML files is not a problem, since they can be displayed in your web browser. However, PHP files are not readable since they are parsed when they are called by the web server.

        Many scripts use a PHP file to store a database username and password. This means that on another server every client could read your PHP files, retrieve your password and access your databases. Thusly, the permissions for directories should be 755 and PHP should be 644.

        To fix issues with people being able to read your files without your knowledge or permission, we installed something called phpSuExec. As such, instead of using everyone’s permissions it uses the owner’s permissions. You can now change the permissions of your PHP scripts to : 0700 or 0400 and still be able to read and execute them. However, these scripts will no longer be accessible to any other users. In fact, PHPsuexec will refuse to execute a script if it is world-writable to protect you from someone abusing one of your scripts. Permissions of 0777 are world writeable.

        They also said that this phpSuExec was installed a long time ago.

        Mc
          • 26903
          • 1,336 Posts
          Hmm, this has been seen before but under different circumstances than yours, have a look at this thread :-
          http://modxcms.com/forums/index.php/topic,29771.msg181070.html#msg181070.

          It doesn’t directly help you but you could look in your database to see if manager_theme is set in your site_settings table.

          I can easily re-create your fault by setting $manager_theme to ’’ just above its use in accesscontrol.inc.php so it would appear we are losing the manager_theme again.

          Do your providers mean they have just installed PHPSuExec, or its always been there?
            Use MODx, or the cat gets it!
            • 18878
            • 210 Posts
            Quote from: shamblett at Oct 28, 2008, 09:10 AM

            Hmm, this has been seen before but under different circumstances than yours, have a look at this thread :-
            http://modxcms.com/forums/index.php/topic,29771.msg181070.html#msg181070.

            It doesn’t directly help you but you could look in your database to see if manager_theme is set in your site_settings table.

            I can easily re-create your fault by setting $manager_theme to ’’ just above its use in accesscontrol.inc.php so it would appear we are losing the manager_theme again.

            Do your providers mean they have just installed PHPSuExec, or its always been there?

            shamblett,

            Yes, I think my problem is the same as described in the thread you provided. I checked my database and manager_theme is correctly set to MODxLight in the system_settings table.

            My host provider explained that PHPSuExec has always been there, and that they didn’t perform any upgrades or modifications, so I guess this "losing manager_theme" problem is coming without warning and for no reason. sad

            I read on some other posts that this could be a cache problem? Is it possible that the siteCache.idx.php and sitePublishing.idx.php files became corrupt?

            Mc
              • 22303 MODX Staff
              • 10,725 Posts
              Reupload the install directory and run an upgrade to repair the cache files. If that doesn’t fix it, let us know more about your site. How many documents? What is your memory_limit in PHP?
                • 18878
                • 210 Posts
                Quote from: OpenGeek at Oct 28, 2008, 02:29 PM

                Reupload the install directory and run an upgrade to repair the cache files. If that doesn’t fix it, let us know more about your site. How many documents? What is your memory_limit in PHP?

                I solved the problem: first I deleted files siteCache.idx.php and sitePublishing.idx.php and then I reuploaded them from my local machine installation package: assets\cache\ and the problem disappeared.

                Anyway it’s not a big site, around 30 documents, and the memory_limit is: local value: 64M , master value: 64M. The origin of the problem is still a mystery.

                Regards.

                Mc