[SOLVED] Tried everything, searched and searched: Php7 (LAMP install)
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Ubuntu Linux 16.04, Debian 10, LineageOS 14.1
Posts: 1,572
Rep:
It was a while ago that I had WordPress going on a home webserver. Can't remember much. But, rather than Apache, I found that lighttpd was easier. Install that and lighttpd-doc, do some reading, and I'm sure eventually you'll get it working.
Of course, if you do get Apache connecting, and the issue is getting WordPress going with it, then ignore my advice. But, if you've not yet had luck with Apache, then I do recommend trying lighttpd instead.
Last edited by mark_alfred; 07-20-2017 at 06:19 PM.
Guys, I will try that tutorial and much thanks for the responses. I hope I get some more time to work on this, but I'm going to be gone for a good part of the week tomorrow.
I take it from you all that Apache has been broken too. I don't know if I have to uninstall or wipe anything first, but if I don't hear from you all, I'll just run through that tutorial, it looks pretty much like what I've already done, but maybe it has something critical that will make the difference!
Ok, when I try to start that tutorial, I get this in the beginning:
Code:
$ sudo apt-get install apache2
[sudo] password for wutsinterweb:
Reading package lists... Done
Building dependency tree
Reading state information... Done
apache2 is already the newest version (2.4.18-2ubuntu3.3).
0 upgraded, 0 newly installed, 0 to remove and 63 not upgraded.
wutsinterweb@Beast-Wutsinterweb ~ $ sudo su
Beast-Wutsinterweb wutsinterweb # systemctl enable apache2
apache2.service is not a native service, redirecting to systemd-sysv-install
Executing /lib/systemd/systemd-sysv-install enable apache2
Beast-Wutsinterweb wutsinterweb # systemctl start apache2
Job for apache2.service failed because the control process exited with error code. See "systemctl status apache2.service" and "journalctl -xe" for details.
systemctl status apache2.service
● apache2.service - LSB: Apache2 web server
Loaded: loaded (/etc/init.d/apache2; bad; vendor preset: enabled)
Drop-In: /lib/systemd/system/apache2.service.d
└─apache2-systemd.conf
Active: failed (Result: exit-code) since Thu 2017-07-20 18:21:42 EDT; 2min 0s ago
Docs: man:systemd-sysv-generator(8)
Process: 27638 ExecStart=/etc/init.d/apache2 start (code=exited, status=1/FAILURE)
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: Output of config test was:
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: AH00112: Warning: DocumentRoot [/var/www/html/example.com/public_html] does not exist
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: (2)No such file or directory: AH02291: Cannot access directory '/var/www/html/example.com/logs/' f
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: AH00014: Configuration check failed
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: Action 'configtest' failed.
Jul 20 18:21:42 Beast-Wutsinterweb apache2[27638]: The Apache error log may have more information.
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: apache2.service: Control process exited, code=exited status=1
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: Failed to start LSB: Apache2 web server.
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: apache2.service: Unit entered failed state.
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: apache2.service: Failed with result 'exit-code'.
lines 1-18/18 (END)
Code:
-- The result is failed.
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: apache2.service: Unit entered failed state.
Jul 20 18:21:42 Beast-Wutsinterweb systemd[1]: apache2.service: Failed with result 'exit-code'.
lines 1131-1157/1157 (END)
DocumentRoot [/var/www/html/example.com/public_html] does not exist
Definitely a problem. httpd.conf might be at /etc/httpd/conf/httpd.conf , but wherever it is is, DocumentRoot is not set correctly. Having "example.com" in the path is very strange.
Out of the box, I'd expect it to be set to /var/www/html
use
Code:
find / -name httpd.conf -ls
to figure out where it is, then set DocumentRoot to a valid directory path. Read the internal comments in the config file for guidance. They're very clear.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.