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

Solr.cmd script typo in delete section

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 6.4.2
    • Fix Version/s: 6.5.1, 6.6, 7.0
    • Component/s: scripts and tools
    • Security Level: Public (Default Security Level. Issues are Public)
    • Labels:
      None
    • Environment:

      MS Windows Server 2012 R2
      Solr 6.4.2

      Description

      Behavior: Open a command line, go to solr bin directory and execute the following command: solr.cmd delete -collection gettingstarted
      A messagem appears "Usage: java [-options] class [args...]..." meaning there's a syntatic error.

      Problem: In line 1380 of solr.cmd the char "^" is supposed to act as a line break, but since it's not the last char in that line (a white space is) windows shell script doesn't concatenate the lines that follow, rendering the java command incomplete.

      "%JAVA%" %SOLR_SSL_OPTS% %AUTHC_OPTS% %SOLR_ZK_CREDS_AND_ACLS% -Dsolr.install.dir="%SOLR_TIP%" ^
      -Dlog4j.configuration="file:%DEFAULT_SERVER_DIR%\scripts\cloud-scripts\log4j.properties" ^
      -classpath "%DEFAULT_SERVER_DIR%\solr-webapp\webapp\WEB-INF\lib*;%DEFAULT_SERVER_DIR%\lib\ext*" ^
      org.apache.solr.util.SolrCLI delete -name Unable to render embedded object: File (DELETE_NAME) not found. -deleteConfig Unable to render embedded object: File (DELETE_CONFIG) not found. ^
      -solrUrl Unable to render embedded object: File (SOLR_URL_SCHEME) not found.://%SOLR_TOOL_HOST%:Unable to render embedded object: File (DELETE_PORT) not found./solr

      Same problem also exists in lines 1148 and 1188.

      Proposed correction: remove the white space after the "^" char in lines 1148, 1188 and 1380.

        Attachments

          Activity

            People

            • Assignee:
              janhoy Jan Høydahl
              Reporter:
              lmgoes Luis Goes
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: