We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 41583
    • 29 Posts
    Environment:
    MODX Revolution 2.2.5-pl
    Ubuntu 12.04 LTS
    Apache/2.2.22
    PHP Version 5.3.10 (128Mb)
    Mysql 5.5.24
    Curl 7.22.0 (enabled)



    Modx Addons
    getResources 1.5.1
    Login 1.8.1
    NewsPublisher 1.4.2
    Personalize 3.4.0



    Yesterday when I logged onto my server it hung, and after rebooting the server, I could no longer download extras. The PHP errors are below. I am not sure what the problem could be.... help smiley Could anyone offer anyone advice.

    FYI: My fblogin extra also stopped working.


    [Sun Dec 02 14:36:16 2012] [error] [client 94.172.28.238] PHP Warning:  Invalid argument supplied for foreach() in /var/www/www.jarnyn.co.uk/core/model/modx/processors/workspace/packages/rest/getlist.class.php on line 48, referer: http://www.jarnyn.co.uk/manager/index.php?a=69
    [Sun Dec 02 14:38:20 2012] [error] [client 94.172.28.238] PHP Notice:  Trying to get property of non-object in /var/www/www.jarnyn.co.uk/core/model/modx/processors/workspace/packages/rest/getinfo.class.php on line 33, referer: http://www.jarnyn.co.uk/manager/index.php?a=69
    [Sun Dec 02 14:38:20 2012] [error] [client 94.172.28.238] PHP Notice:  Trying to get property of non-object in /var/www/www.jarnyn.co.uk/core/model/modx/processors/workspace/packages/rest/getinfo.class.php on line 34, referer: http://www.jarnyn.co.uk/manager/index.php?a=69
    [Sun Dec 02 14:38:20 2012] [error] [client 94.172.28.238] PHP Notice:  Trying to get property of non-object in /var/www/www.jarnyn.co.uk/core/model/modx/processors/workspace/packages/rest/getinfo.class.php on line 39, referer: http://www.jarnyn.co.uk/manager/index.php?a=69
      • 41583
      • 29 Posts
      I have also deleted the entire /core/cache/ directory.

      Some logs from MODx

      [2012-12-02 16:12:35] (ERROR @ /connectors/workspace/packages.php) Could not connect to provider at: http://rest.modx.com/extras/
        • 41583
        • 29 Posts
        For anyone else having this issue. In the end it was a bug in the way Ubuntu 12.04 handles DNS via resolv.conf
        I had to:

        edit

        /etc/resolvconf/resolv.conf.d/head 

        In that file, after the header, put in your info like you would in resolv.conf

        nameserver 192.168.1.XXX

        Then restart resolvconf

        sudo resolvconf -u


        :)
          • 4292
          • 15 Posts
          Have a similar problem.
          System error log:
          [2012-12-18 17:48:42] (ERROR @ /connectors/workspace/packages-rest.php) Could not connect to provider at: http://rest.modx.com/extras/
          [2012-12-18 17:48:46] (ERROR @ /connectors/workspace/packages.php) Could not connect to provider at: http://rest.modx.com/extras/
          

          Can't loading/updating packages, can't change provider's url.
          Also FormIt don't working.
          My site is on the hosting, so asked a question about server to them, now waiting for an answer.
          _____________________________
          *
          Testing with Firebug in admin side of site (trying to download/update package ):
          /connectors/workspace/packages-rest.php   Aborted
          /connectors/workspace/packages.php   Aborted
          

          in file
          /manager/assets/ext3/adapter/ext/ext-base.js
          

          [ed. note: bullet last edited this post 13 years, 9 months ago.]
            • 41583
            • 29 Posts
            Hi Bullet, do you have SSH access to the server ? If you do log on and see if you can ping www.google.co.uk . Just to check that your DNS is actually working.
              • 4292
              • 15 Posts
              Quote from: ankh2054 at Dec 19, 2012, 01:36 AM
              Hi Bullet, do you have SSH access to the server ? If you do log on and see if you can ping www.google.co.uk . Just to check that your DNS is actually working.
              Unfortunately I haven't ...
                • 41583
                • 29 Posts
                Create a snippet with the following code

                function ping($host, $port, $timeout) { 
                  $tB = microtime(true); 
                  $fP = fSockOpen($host, $port, $errno, $errstr, $timeout); 
                  if (!$fP) { return "down"; } 
                  $tA = microtime(true); 
                  return round((($tA - $tB) * 1000), 0)." ms"; 
                }
                
                //Echoing it will display the ping if the host is up, if not it'll say "down".
                echo ping("www.google.com", 80, 10);


                Call the Snippet in a resource and view the resource. If the server DNS is working you should see the MS, if not it should display down.
                  • 4292
                  • 15 Posts
                  Quote from: ankh2054 at Dec 19, 2012, 02:10 AM
                  Create a snippet with the following code

                  Call the Snippet in a resource and view the resource. If the server DNS is working you should see the MS, if not it should display down.
                  I see MS.
                    • 41583
                    • 29 Posts
                    unlikely to be a server issue then, unless the PHP code uses local PC DNS, but I doubt it.

                    Have a look at this post - https://forums.modx.com/thread/28823/cannot-download-package?page=2

                    They provide further insight.

                    Did it suddenly stop working or has never workde ?
                      • 4292
                      • 15 Posts
                      It stoped working. Moreover, i checked more 2 sites on this host- MODx Revo 2.2.5 and MODx Revo 2.2.2 and faced with same problem!
                      Interesting. I haven't even touched my site Revo 2.2.2 more then 6 month and today cheked it for the problem and got it!
                      So I think problem is in hosting provider. [ed. note: bullet last edited this post 13 years, 9 months ago.]