title: Run application during server boot time
body: <p>I have a problem. 
  <code>lsb_release -a</code> result</p>
  
  <p>No LSB modules are available. <br/>Distributor ID:  Ubuntu <br/>Description:    Ubuntu 17.04 <br/>Release:  17.04 Codename: zesty</p>
  
  <p>and this my auto start script: <strong>start-app</strong></p>
  
  <pre><code>#!/bin/bash
  ### BEGIN INIT INFO
  # Provides:          data exchange
  # Required-Start:    $all
  # Required-Stop:
  # Default-Start:     2 3 4 5
  # Default-Stop:
  # Short-Description: Start data exchange service...
  ### END INIT INFO
  echo 'after reboot' &gt; /home/forte/test.txt
  java -cp /home/forte/apps/data-exchange-service-1.0.jar org.springframework.boot.loader.JarLauncher &amp;
  exit 0
  </code></pre>
  
  <p>After created I give excute permission </p>
  
  <pre><code>chmod +x start-app
  </code></pre>
  
  <p>Then I moved this script under <strong>/etc/init.d</strong> and execute </p>
  
  <pre><code>update-rc.d start-app defaults
  update-rc.d start-app enable
  </code></pre>
  
  <p>I check the <strong>rc*.d</strong> folder and my scripts link exist under [2,3,4,5]</p>
  
  <p>But when I reboot server it does not run my app. </p>
  
  <p>I also tried <strong>crontab</strong></p>
  
  <pre><code>@reboot /home/forte/apps/start-app
  </code></pre>
  
  <p>But none of them does not work 
  Is there any other way?</p>
  
  <p><strong>extra note</strong>
  when I execute</p>
  
  <pre><code>/etc/init.d/start-app start
  </code></pre>
  
  <p>my app works normally</p>