Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-14416

Nodes view doesn't work correctly when Solr is hosted on Windows

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Duplicate
    • 7.7.2, 8.1, 8.1.1, 8.2, 8.3, 8.3.1, 8.4, 8.4.1
    • 8.5
    • Admin UI
    • None

    Description

      I sent a message about this on the mailing list a long time ago and got no replies.
      Originally I saw it on 8.1.1, it's a problem in 8.3.1 and I don't expect it's fixed in 8.5, but I will check.

      On Solr 8.1.1 / 7.7.2 with Oracle 1.8.0_191 25.191-b12 with Solr running on Windows 10

      In the Nodes view of the Admin UI,http://localhost:8983/solr/#/~cloud?view=nodes there is a refresh button. However when you click it, the only thing that gets visibly refreshed is the 'bar chart' (not sure what to call it - it's shown when you choose show details) of the index shard size on disk. The other stats do not update.
      Also, when there is more than one node, only some of the node information is shown

      Firefox dev console shows:

      _Error: s.system.uptime is undefined
      nodesSubController/$scope.reload/<@http://localhost:8983/solr/js/angular/controllers/cloud.js:384:11
      v/</e[k]/n<@http://localhost:8983/solr/libs/angular-resource.min.js:33:133
      processQueue@http://localhost:8983/solr/libs/angular.js:13193:27
      scheduleProcessQueue/<@http://localhost:8983/solr/libs/angular.js:13209:27
      $eval@http://localhost:8983/solr/libs/angular.js:14406:16
      $digest@http://localhost:8983/solr/libs/angular.js:14222:15
      $apply@http://localhost:8983/solr/libs/angular.js:14511:13
      done@http://localhost:8983/solr/libs/angular.js:9669:36
      completeRequest@http://localhost:8983/solr/libs/angular.js:9859:7
      requestLoaded@http://localhost:8983/solr/libs/angular.js:9800:9_
      

      The system response has upTimeMs in it for the JVM/JMX properties, but no system/uptime

      {
        "responseHeader":{
          "status":0,
          "QTime":63},
        "localhost:8983_solr":{
          "responseHeader":{
            "status":0,
            "QTime":49},
          "mode":"solrcloud",
          "zkHost":"localhost:9983",
          "solr_home":"...",
          "lucene":{
            "solr-spec-version":"8.1.1",
            "solr-impl-version":"8.1.1 fcbe46c28cef11bc058779afba09521de1b19bef - ab - 2019-05-22 15:20:01",
            "lucene-spec-version":"8.1.1",
            "lucene-impl-version":"8.1.1 fcbe46c28cef11bc058779afba09521de1b19bef - ab - 2019-05-22 15:15:24"},
          "jvm":{
            "version":"1.8.0_211 25.211-b12",
            "name":"Oracle Corporation Java HotSpot(TM) 64-Bit Server VM",
            "spec":{
              "vendor":"Oracle Corporation",
              "name":"Java Platform API Specification",
              "version":"1.8"},
            "jre":{
              "vendor":"Oracle Corporation",
              "version":"1.8.0_211"},
            "vm":{
              "vendor":"Oracle Corporation",
              "name":"Java HotSpot(TM) 64-Bit Server VM",
              "version":"25.211-b12"},
            "processors":8,
            "memory":{
              "free":"1.4 GB",
              "total":"2 GB",
              "max":"2 GB",
              "used":"566.7 MB (%27.7)",
              "raw":{
                "free":1553268432,
                "total":2147483648,
                "max":2147483648,
                "used":594215216,
                "used%":27.670302242040634}},
            "jmx":{
              "bootclasspath":"...",
              "classpath":"start.jar",
              "commandLineArgs":[...],
              "startTime":"2019-06-20T11:41:58.955Z",
              "upTimeMS":516602}},
          "system":{
            "name":"Windows 10",
            "arch":"amd64",
            "availableProcessors":8,
            "systemLoadAverage":-1.0,
            "version":"10.0",
            "committedVirtualMemorySize":2709114880,
            "freePhysicalMemorySize":16710127616,
            "freeSwapSpaceSize":16422531072,
            "processCpuLoad":0.13941671744473663,
            "processCpuTime":194609375000,
            "systemCpuLoad":0.25816002967796037,
            "totalPhysicalMemorySize":34261250048,
            "totalSwapSpaceSize":39361523712},
          "node":"localhost:8983_solr"}}
      

      The SystemInfoHandler does this:

      // Try some command line things:
          try {
            if (!Constants.WINDOWS) {
              info.add( "uname",  execute( "uname -a" ) );
              info.add( "uptime", execute( "uptime" ) );
            }
          } catch( Exception ex ) {
            log.warn("Unable to execute command line tools to get operating system properties.", ex);
          }
      

      Which appears to be the problem since it won't return uname and uptime on windows, but the UI expects them

      If I run uptime from my Ubuntu shell in WSL the output is like "16:41:40 up 7 min, 0 users, load average: 0.52, 0.58, 0.59". If I make the System handler return that then there are no further dev console errors...
      However, even with that "fixed", refresh doesn't actually seem to refresh anything other than the graph.

      In contrast, refreshing the System (e.g. memory) section on the main dashboard does correctly update.

      The missing "uptime" from the response looks like the problem, but isn't actually stopping refresh from doing anything when I return an uptime. So, is the Nodes view supposed to be refreshing everything, or are my expectations wrong?

      Attachments

        1. screenshot-1.png
          18 kB
          cjcowie

        Issue Links

          Activity

            People

              Unassigned Unassigned
              colvinco Colvin Cowie
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: