Scrpit to stop dgraph, archive logs, start dgraph

  1. Home
  2. Blog
  3. Scrpit to stop dgraph, archive logs, start dgraph

Scrpit to stop dgraph, archive logs, start dgraph

DgraphCluster has an object’s applyIndex() method from the default “DistributeIndexAndApply” scrpit to create a new script within your Deployment Template. You can see this script in AppConfig.xml for your application. The applyIndex() method will stop the dgraph, archived the log files, then restarted the dgraph.

<script id="RestartDgraphAndArchiveLogs">
      <bean-shell-script>
              [![CDATA[DgraphCluster.applyIndex();]]>
       </bean-shell-script>
</script>


For running this script, we can execute below command from location where your application is installed. For example if application installed at “C:\Endeca\Apps\DemoApp\” then go to location “C:\Endeca\Apps\DemoApp\control\” then run below command

"runcommand.bat/sh RestartDgraphAndArchiveLogs"
1 2 3 20
Let's Share
Show Buttons
Hide Buttons