Clearing cache in Drupal 8 on ISPConfig 3.1dev results in crashed site

Discussion in 'General' started by seizethecarp, Jul 14, 2017.

  1. seizethecarp

    seizethecarp New Member

    Ubuntu 16.04
    ISPConfig 3.1dev
    Maria/MySql 5.6+
    PHP 7.0
    Drupal 8

    We follow the instructions from https://www.howtoforge.com/tutorial/how-to-install-drupal_8-with-apache-and-ssl-on-ubuntu-15-10/ to set it up
    We have multiple sites on this server. I've had an issue on two different sites on the same server. I have not maintained any of the other sites, so I haven't tested. After I have installed a theme (not the same one on both) if I clear the cache the site breaks. One the first one the pages are blank white.
    The problem first started like this:
    Theme Bootstrap. I’ve was unable to access the site. It worked the day before but today every page gave me a 404 error except the home page. The problem started on my PC and then later it started happening on the Mac.
    I found a fix:
    I went through this troubleshooting guide and apparently I needed to have “mod_rewrite” enabled. Of course. Duh. (and why did it work until today?)
    https://www.drupal.org/node/228462
    So I had to go here to figure out how to do that:
    https://stackoverflow.com/questions/869092/how-to-enable-mod-rewrite-for-apache-2-2
    Which had these instructions:
    ==============================
    use the following .htaccess file.

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    The above .htaccess file (if placed in your DocumentRoot) will redirect all traffic to an index.php file in the DocumentRoot unless the file exists.

    So, let's say you have the following directory structure and httpdocs is the DocumentRoot

    httpdocs/
    .htaccess
    index.php
    images/
    hello.png
    js/
    jquery.js
    css/
    style.css
    includes/
    app/
    app.php

    Any file that exists in httpdocs will be served to the requester using the .htaccess shown above, however, everything else will be redirected to httpdocs/index.php. Your application files in includes/app will not be accessible.
    ================

    So I tried that and it worked. But then when I cleared the cache after that (Performance > Clear cache) it gave me: "The website encountered an unexpected error. Please try again later."
    So I removed the above code and now the pages are just blank.
    If I go to install.php it says file not found.

    That's the first one-- the second one where I had installed Zircon does this after I cleared the cache, for anything at all, login logout, anything:
    "The website encountered an unexpected error. Please try again later."
    I go to the install.php I get this:
    Additional uncaught exception thrown while handling exception.
    Original
    Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: The service "password_migrate" has a dependency on a non-existent service "password_original". in Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processReferences() (line 58 of /var/www/clients/client1/web9/web/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php).

    Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processReferences(Array) (Line: 42)
    Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processDefinition(Object) (Line: 36)
    Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->process(Object) (Line: 104)
    Symfony\Component\DependencyInjection\Compiler\Compiler->compile(Object) (Line: 590)
    Symfony\Component\DependencyInjection\ContainerBuilder->compile() (Line: 1284)
    Drupal\Core\DrupalKernel->compileContainer() (Line: 873)
    Drupal\Core\DrupalKernel->initializeContainer() (Line: 18)
    Drupal\Core\Installer\InstallerKernel->initializeContainer() (Line: 465)
    Drupal\Core\DrupalKernel->boot() (Line: 414)
    install_begin_request(Object, Array) (Line: 114)
    install_drupal(Object) (Line: 44)

    Additional
    Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: You have requested a non-existent service "theme.manager". in Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition() (line 816 of /var/www/clients/client1/web9/web/vendor/symfony/dependency-injection/ContainerBuilder.php).

    Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition('theme.manager') (Line: 456)
    Symfony\Component\DependencyInjection\ContainerBuilder->get('theme.manager') (Line: 674)
    Drupal::theme() (Line: 22)
    _drupal_maintenance_theme() (Line: 710)
    drupal_maintenance_theme() (Line: 967)
    install_display_output(Array, Array, Array) (Line: 264)
    _drupal_log_error(Array, 1) (Line: 570)
    _drupal_exception_handler(Object)
     
    Last edited: Jul 14, 2017
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    This tutorial is for a standalone Drupal server without a control panel, it is not compatible with servers that run ISPConfig and ISPConfig can be damaged when you follow these steps. For an ispconfig server, you simply create a website and database in ispconfig, upload Drupal to the web directory of that site and then open the browser and follow the Drupal web install wizard.

    Regarding your current issue, it seems as if some files are missing in that website. If you migrated the site from another server and did not clear the cache before, then it might be that the site never worked, it was just delivered from cache so you did not notice that files to regenerate the pages are missing.
     
  3. seizethecarp

    seizethecarp New Member

    I will pass along to my betters the message that the install process may break ISPConfig.
    Regarding the missing files, these sites are all fresh and new and have zero content on them.
    Thank you for the helpful reply.
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Ok, bit Symfony is telling you this:

    Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: The service "password_migrate" has a dependency on a non-existent service "password_original". in

    So there must be some files missing in that site.
     
  5. seizethecarp

    seizethecarp New Member

    Strange. I have no idea how that would happen-- I guess the one bit of content they all share is that I tried to put a theme on them. I must have done something wrong there. Do you have any pointers on how to browse for what's missing? The real technical wizard here is out for the week but I would like to keep plugging away at it if I can.

    I can't get a fresh box to try it on, but to try to eliminate possible bugs I want to do a fresh Drupal install at the very least. You mentioned the basic plan of how to set it up, is this an appropriate install tutorial for ISPConfig3.1 and Drupal8?
    https://www.howtoforge.com/drupal_ispconfig
     
    Last edited: Jul 19, 2017
  6. seizethecarp

    seizethecarp New Member

Share This Page