Author Topic: Allmon project - Apache not loading following a reboot after installation  (Read 758 times)

K6jrm

  • Guest
Good morning Loren and viewers,  I'd like to apologize for this lengthy post.

First of all, I would like to thank Loren for the tutorial videos that were done on the Allmon2 installation and configuration.  I viewed both the 1:03:00 and around 00:08:00 minute video and found them very helpful.  I followed each step and Allmon2 was up and running and I was able to control my node.
Here is the issue,

I'm running my node on a Raspberry pi3 using a microSD card with the latest Dial distro image.  As soon as I reboot my node, Apache will not run.  I've restored back up copies and perform the installation 3 times, and the same results.  This last time, I just installed apache (with no allmon components), and confirmed it was running.  I then reset the pi, and bam!, Apache won't load.  When I try running it manually, I get a  "Warning: Unit file of apache2.service changed on disk, 'systemctl daemon-reload' recommended."  When I run the systemctl daemon-reload it runs and brings me back to the command line.  Then I try to start Apache with service apache2 start command and get this message.  Job for apache2.service failed. See 'systemctl status apache2.service' and 'journalctl -xn' for details.

I Googled the errors, but the solution isn't clear to me, but maybe if I read between the lines, it's something about the microSD being the media?  It's almost like the install and configuration of Apache are being kept in RAM and not written to the microSD and when I reset, that instance is gone and won't reload.  The apache directory structure and files are still there.

I am hoping others see this and might have a direction to point me in.

Thanks in advance for any info.

kc9zhv

  • Administrator
  • Newbie

  • Offline
  • *****
  • Owner of Voipham.com and KC9ZHV.com
  • 24
  • Karma:
    +0/-0
  • Personal Text
    I enjoy helping others with allstarlink!
    • View Profile
    • KC9ZHV
  • Callsign: KC9ZHV
Re: Allmon project - Apache not loading following a reboot after installation
« Reply #1 on: November 02, 2016, 02:12:15 PM »
I ran into this with another friend the reason why apache does not load is because it removes the apache folder..

What i did was in rc.local n
Code: [Select]
nano /etc/rc.local/
I put this code in rc.local to make a directory in /var/log/apache
Example
Code: [Select]
mkdir /var/log/apache2
I hate to say this but I can't remember if it is apache or apache2 that needs created..

You can test this theory by created the directory manually by command line like this
Code: [Select]
mkdir /var/log/apache2
then run
Code: [Select]
service apache2 start
This should get you close to fixing the issue.. It definitely is a folder related issue that causes apache the web service to crash..

I failed to mention that most of the log file is written to ram meaning that once you reboot your device you will have to create that folder again.. Now if you put the mkdir /var/log/apache2 in your rc.local it will create that directory on boot up.. Again i can't remember if it is apache or apache2 that needs created in the log file.. I don't have any pis personally..
« Last Edit: November 02, 2016, 02:22:25 PM by kc9zhv »

K6jrm

  • Guest
Re: Allmon project - Apache not loading following a reboot after installation
« Reply #2 on: November 02, 2016, 06:15:39 PM »
Loren,
I did as you suggested and that appears to work.  After completing the Allmon2 install and config (using your tutorial), I created the directory and placed the command in the rc.local and reset the Pi multiple times.  Allmon is staying up and running.  Thank you so much for your suggestion.  No I'm just creating a new backup image for safekeeping.

Regards,
John
K6jrm

kc9zhv

  • Administrator
  • Newbie

  • Offline
  • *****
  • Owner of Voipham.com and KC9ZHV.com
  • 24
  • Karma:
    +0/-0
  • Personal Text
    I enjoy helping others with allstarlink!
    • View Profile
    • KC9ZHV
  • Callsign: KC9ZHV
Re: Allmon project - Apache not loading following a reboot after installation
« Reply #3 on: November 02, 2016, 08:25:37 PM »
Good news!!