Page 1 of 1

httpd fails to stop, start, or restart

Posted: Mon May 21, 2012 5:49 pm
by coffeehedake
Hey guys, not sure if this is the right place to ask this, I apologize in advance if I've misplaced it.

I've actually been using Amahi for quite a while, but never had the need to ask a question or post on the forums, since I've found all of the information on the forums, wiki, and around the net to be quite complete whenever I've had an issue.

At the moment, I am unable to access my HDA via a web browser directed to either http://hda or http://ipaddresshere from any of the machines on my network, nor from the HDA itself.
I've tried restarting the Apache daemon, but get this:

Code: Select all

service httpd restart Stopping httpd: [FAILED] Starting httpd: [FAILED]
I'm not sure what log files to present in starting to troubleshoot this issue. Webmin is working currently, but the Amahi dashboard, and all other apps relying on Apache except web-apps I have created myself are offline.

I can't think of anything I've done to cause this, but I'm sure it was something silly that I accidentally modified.
The server is also running McMyAdmin (Minecraft Server), and I was updating McMyAdmin when this issue began. Coincidentally, McMyAdmin is working properly, on port 8383, and shouldn't be interfering with Apache, as far as I am aware. I actually used Webmin to schedule a CRON job to start the Minecraft server at boot, which is not working, and I've been starting it manually.

Any help or advice you can offer would be greatly appreciated, and thank you in advance for your time.

Re: httpd fails to stop, start, or restart

Posted: Mon May 21, 2012 7:24 pm
by bigfoot65
This is typically the result of bad .conf file in the /etc/httpd/conf.d directory. Check there and if there is one there for McMyAdmin then it needs to be removed. There are certain ones required, but if you can find the bad one and remove it, httpd should start.

Re: httpd fails to stop, start, or restart

Posted: Tue May 22, 2012 12:37 pm
by coffeehedake
...Check there and if there is one there for McMyAdmin then it needs to be removed...
Thanks BigFoot, I'll take a look as soon as I get home tonight. I appreciate the help!

Re: httpd fails to stop, start, or restart

Posted: Tue May 22, 2012 5:14 pm
by coffeehedake
This is typically the result of bad .conf file in the /etc/httpd/conf.d directory. Check there and if there is one there for McMyAdmin then it needs to be removed.
You were exactly, and precisely right.

I believe the erroneous piece of the config is the path to a depreciated part of McMyAdmin's former web files:

Code: Select all

DocumentRoot /var/hda/web-apps/mcmyadmin/html <Directory "/var/hda/web-apps/mcmyadmin/html">
After upgrading, I noticed that the new installer script for McMyAdmin no longer creates these folders... in fact I'm not sure where the files for the webui/webapp are located, but I can probably find the answer on McMyAdmin's wiki. It's too bad there isn't a purchasable app for Amahi to run McMyAdmin, but I see why that would be problematic, as it's already a paid server app. One can dream... I did notice this gem in beta but unfortunately I'm not on the beta team. :(

Thanks for your advice, do you mind if I post my results with McMyAdmin back here, so that future searchers may find it?

Re: httpd fails to stop, start, or restart

Posted: Tue May 22, 2012 5:38 pm
by coffeehedake
I found this forum posting helpful:
Got it working with a simple file containing:

Put this in a file called start.sh and run "sh /path/to/folder/start.sh"

cd /path/to/folder
./MCMA2
Cron job scheduled to run a shell script that CD into the appropriate McMyAdmin directory, then runs the executable for the server.

I was able to successfully schedule the job with the appropriate shell script. All is well, and my HDA is even accessible again, yay!

Thanks again!

Re: httpd fails to stop, start, or restart

Posted: Tue May 22, 2012 7:41 pm
by bigfoot65
Awesome, glad it worked out. Is this something for McMyAdmin that needs updated in the wiki? If so, we would appreciate if you could make those revisions :)

Re: httpd fails to stop, start, or restart

Posted: Wed May 23, 2012 5:40 am
by coffeehedake
I'd be glad to. Really the only difference that I experienced, is that the McMyAdmin package no longer includes start.sh, and several of the folders that were previously there for the webui portion of McMyAdmin. I believe most of the instructions here are still relevant, but mostly pertain to the older (pre 2.0) version of McMyAdmin. That was my experience, but YMMV.

I'll see about throwing some information together, and updating the page. I'm still trying to locate the actual web files themselves for McMyAdmin... the new version uses Java for the WebUI, whereas the old one was mostly an HTML front-end.