0

I have just installed LAMP and VestaCP and nothing else.

After checking the error log among those line I saw also:

AH00558: apache2: Could not reliably determine the server's fully qualified domain
  name, using 1st.example.com.
  Set the 'ServerName' directive globally to suppress thi$

AH00558: apache2: Could not reliably determine the server's fully qualified domain
  name, using 127.0.1.1.
  Set the 'ServerName' directive globally to suppress this mess$

Here is also the full paste bin error log file https://pastebin.com/dhAHiGb7

1
  • Comments are not for extended discussion; this conversation has been moved to chat.
    – Thomas Ward
    Dec 21, 2017 at 0:08

2 Answers 2

0

Unfortunally there is no single guide on installing LAMP -that I know of-; however as you have not edited the .htaccess file manually, my educated guess would be, that in the main configuration file (or in the Virtual Host config file the directive AllowOverride AuthConfig is missing.

The tricky part is to find the right file. For VestaCP (https://vestacp.com/docs/#config-log-location-debian-ubuntu) you have the following default configs:

  • /etc/apache2/apache2.conf
  • /etc/apache2/conf.d/*
  • /home/$user/conf/web/apache2.conf
  • /home/$user/conf/web/sapache2.conf

You have to locate the config containing the directives for PHPMyAdmin.

Try something like

grep -r phpmyadmin /etc/apache2/*

In the corresponding file you should find

<Directory /usr/share/phpmyadmin>
...
</Directory>

If so, you could add

AllowOverride AuthConfig

within the <Directory ..> </Directory> Section and restart the apache2 service.

5
  • grep -r phpmyadmin /etc/apache2/* does not open anything
    – Mark178
    Dec 19, 2017 at 23:06
  • This is not looking good; as you run your LAMP Server as a Droplet, I am not sure about the internal configuration of the apache webserver. Have you tried to pose your question on the VestaCP Forum (forum.vestacp.com)? Otherwise you would have to "reverse engineer your apache config by follwoing the apache process. I could try to guide you through the apache runtime configuration - but this will take some time an effort (and not tonight!).
    – Stefan
    Dec 19, 2017 at 23:14
  • When installing phpMyAdmin in a secure way(a guide I found online), I created a .htaccess file in order to secure phpMyadmin ----- it was something like this ------ AuthType Basic AuthName "Restricted Files" AuthUserFile /etc/phpmyadmin/.htpasswd Require valid-user
    – Mark178
    Dec 19, 2017 at 23:15
  • How can I contact another time?
    – Mark178
    Dec 19, 2017 at 23:17
  • I will try to find some time tomorrow and post another anwser detailing the first steps; and you can follow up in comments.
    – Stefan
    Dec 19, 2017 at 23:23
0

How to find the current apache webserver config:

  1. Find the main httpd process ps axuww | grep 'root.*http[d]' which should yield something like

root 1480 0.0 0.0 90788 7756 - SsJ 20:25 0:00.03 /usr/local/sbin/httpd

Lookout for the command, note if any config file is stated e.g. /usr/sbin/httpd -f /etc/apache2/conf/httpd.conf

  1. If no startup configfile is referenced with -f , we have to find the default config directory:
/usr/sbin/httpd -V
Server version: Apache/2.4.25
...
 -D HTTPD_ROOT="/usr/local"
 -D SERVER_CONFIG_FILE="etc/apache24/httpd.conf"

We are looking for the compiletime variables HTTPD_ROOT and SERVER_CONFIG_FILE. If the latter is not an absolute filepath, as above, it is expanded by the HTTPD_ROOT dir path; if SERVER_CONFIG_FILE is empty it defaults to $HTTPD_ROOT/conf/httpd.conf.

  1. Parsing the main configfile

We should have located the runtime configfile and are now parsing for the relevant directives. Among these are

  • ServerRoot
  • Include or IncludeOptional
  • DocumentRoot
  • Alias / ScriptAlias
  • and all and Containers

Firstly we have to locate the directory container for phpmyadmin. Therefore parse all configfiles that are referenced by the Include directives for 'php'. In the good old days you had a Alias/ScriptAlias directive and a corresponding or Container for PHP together with a SetHandler directive. Nowadays you could have a php-fpm daemon running on your system which is connected through proxy_fcgi.

3
  • Stefan, I found an answer in the morning in VetstaCP forum. Since VestaCP by default would install apache server and some other features(by doing so VestaCP rewrites previews configuration). I wanted VestaCP to create a database, now I did create a database with a few lines of codes. I would like to keep a contact with you if I would have any questions as I am still in the process of completing this VPS. How can we remain in touch? Thanks so much so far.
    – Mark178
    Dec 20, 2017 at 20:58
  • No problem; I am not aware, that you can contact individual users directly, but just tag your question here on AskUbuntu with VestaCP and I should receive a notification.
    – Stefan
    Dec 20, 2017 at 21:37
  • Hey Stefan, hope you are doing well. I have a problem but haven't found a solution yet. This is the url question that I have asked askubuntu.com/questions/992645/…
    – Mark178
    Jan 5, 2018 at 17:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .