omega8cc / boa

Barracuda Octopus Aegir 5.5.0-PRO
https://omega8.cc/compare
394 stars 75 forks source link

New server install using BOA-3.0.2 not installing octopus #928

Closed attiks closed 8 years ago

attiks commented 8 years ago

I installed a minimal debian jessie and ran

cd;wget -q -U iCab http://files.aegir.cc/BOA.sh.txt;bash BOA.sh.txt
boa in-stable public xxx.attiks.com attiks@xxx.com o1 none php-5.5

Install worked for system part, but failed on octopus, complaining /data/disk/o1/aegir/distro/001/sites/o1.xxx.attiks.com/settings.php does not exist.

I re-installed my server from scratch, but got the same error

BOA [17:22:48] ==> INFO: Congratulations, Aegir have been installed successfully!
BOA [17:22:48] ==> NOTE! Please wait 2 min before visiting Aegir at:

BOA [17:22:48] ==> LINK: http://master.xxx.attiks.com/user/reset/1/1462375254/k8ljKxBUeNiLDZrIB25R1Ih3vqvqi2BvuIEmFF-4UDw/login

BOA [17:22:59] ==> INFO: Installing csf/lfd firewall...
BOA [17:23:02] ==> TEST: csf/lfd firewall should work fine on this system
BOA [17:23:03] ==> INFO: csf/lfd firewall installed
BOA [17:23:03] ==> INFO: Upgrading csf/lfd firewall...
BOA [17:23:05] ==> TEST: csf/lfd firewall should work fine on this system
BOA [17:23:06] ==> INFO: csf/lfd firewall upgrade completed
BOA [17:23:06] ==> INFO: Installing DNS cache pdnsd server...
BOA [17:23:48] ==> CARD: Now charging your credit card for this magic show...
BOA [17:23:51] ==> CARD: It will take a moment to process your payment...
BOA [17:23:57] ==> JOKE: Just kidding !!! Enjoy your Aegir Hosting System :)

BOA [17:24:01] ==> Final post-install cleaning, one moment...
BOA [17:24:05] ==> BYE!

BOA [17:24:07] ==> Skynet Agent v.BOA-3.0.2 welcomes you aboard!

BOA [17:24:11] ==> INFO: Creating your /root/.o1.octopus.cnf config file
BOA [17:24:12] ==> New Octopus Setup on xxx.attiks.com in progress...

    * Your e-mail address is attiks@gmail.com
    * Your client e-mail address is attiks@gmail.com
    * Your Aegir control panel for this instance will be available at:
        https://o1.xxx.attiks.com
    * Your Aegir system user for this instance will be o1
    * This Octopus will use PHP-CLI 5.5 for all sites
    * This Octopus will use PHP-FPM 5.5 for all sites
    * This Octopus includes platforms: none
    * This Octopus options are listed as SSD / Y / 8 C

BOA [17:24:20] ==> INIT A: Shared platforms code v.001 (new) will be created
BOA [17:24:20] ==> INIT A: Adding user...
BOA [17:24:23] ==> INIT B: Downloading drush micro-8-24-04-2016...
BOA [17:24:26] ==> INIT B: Installing Aegir Provision backend...
BOA [17:24:26] ==> INIT B: Downloading Drush and Provision extensions...
BOA [17:24:27] ==> INIT B: Running hostmaster-install, please wait...
BOA [17:24:53] ==> INIT B: FATAL ERROR: Required file does not exist:
BOA [17:24:53] ==> INIT B: FATAL ERROR: /data/disk/o1/aegir/distro/001/sites/o1.xxx.attiks.com/settings.php
BOA [17:24:53] ==> INIT B: FATAL ERROR: Aborting AegirSetupB installer NOW!
BOA [17:24:53] ==> INIT A: FATAL ERROR: AegirSetupB installer failed
BOA [17:24:53] ==> INIT A: FATAL ERROR: Aborting AegirSetupA installer NOW!
BOA [17:24:53] ==> FATAL ERROR: AegirSetupA installer failed
BOA [17:24:53] ==> FATAL ERROR: Aborting Octopus installer NOW!

BOA in-stable completed
Bye

Seems a lot like #924

boa info

Aegir on Debian/jessie x86_64
  VPS XEN
  CPU 12
  RAM 64326
  XTR _XTRAS_LIST="CSF CHV FTP"
  MFX _MODULES_FIX=YES
  PFX _PERMISSIONS_FIX=YES
  DBS _DB_SERIES=5.5
  DNS _DNS_SETUP_TEST=YES
  PKG _EXTRA_PACKAGES=
  NGX nginx/1.9.15
  SSL 1.0.1k
  CRL 7.45.0
  SSH 7.2p2
tourtools commented 8 years ago

quite the same issue on upgrade from 3.0.1 to 3.0.2

BOA [17:30:48] ==> UPGRADE B: Hostmaster STATUS: Upgrade completed
BOA [17:30:48] ==> UPGRADE B: Simple check if Aegir upgrade is successful
BOA [17:30:48] ==> UPGRADE B: FATAL ERROR: Required file does not exist:
BOA [17:30:48] ==> UPGRADE B: FATAL ERROR: /data/disk/o1/aegir/distro/040/sites/o1.server2.sediciweb.it/settings.php
BOA [17:30:48] ==> UPGRADE B: FATAL ERROR: Aborting AegirSetupB installer NOW!
BOA [17:30:48] ==> UPGRADE A: FATAL ERROR: AegirSetupB installer failed
BOA [17:30:48] ==> UPGRADE A: FATAL ERROR: Aborting AegirSetupA installer NOW!
BOA [17:30:48] ==> FATAL ERROR: AegirSetupA installer failed
BOA [17:30:48] ==> FATAL ERROR: Aborting Octopus installer NOW!
Waiting 8 seconds...
Done for /data/disk/o1

OCTOPUS upgrade completed
Bye
attiks commented 8 years ago

Might have found the problem

May  4 17:34:40 Debian-84-jessie-64-minimal systemd[1]: Reloading A high performance web server and a reverse proxy server.
May  4 17:34:40 Debian-84-jessie-64-minimal nginx[6052]: nginx: [emerg] invalid parameter "5153049" in /var/aegir/config/server_master/nginx/vhost.d/chive.master.xxx.attiks.com:17
May  4 17:34:40 Debian-84-jessie-64-minimal systemd[1]: nginx.service: control process exited, code=exited status=1
May  4 17:34:40 Debian-84-jessie-64-minimal systemd[1]: Reload failed for A high performance web server and a reverse proxy server.
May  4 17:34:40 Debian-84-jessie-64-minimal systemd[1]: Reloading A high performance web server and a reverse proxy server.
May  4 17:34:40 Debian-84-jessie-64-minimal systemd[1]: Reloaded A high performance web server and a reverse proxy server.
attiks commented 8 years ago

The offending line is no longer part of the vhost, so I tried running the following, but didn't work

# barracuda up-stable

BOA [17:45:56] ==> Skynet Agent v.BOA-3.0.2 welcomes you aboard!

BOA [17:45:59] ==> INFO: FORCED INIT
BOA [17:45:59] ==> FATAL ERROR: You must define also _EASY_HOSTNAME

BARRACUDA upgrade completed
Bye

# boa in-stable public xxx.attiks.com attiks@xxx.com o1 none php-5.5
ERROR: BOA requires minimal, supported OS, with no services installed
ERROR: The only acceptable exceptions are: sshd and mail servers
Bye

# boa in-stable public xxx.attiks.com attiks@xxx.com o2 none php-5.5
ERROR: BOA requires minimal, supported OS, with no services installed
ERROR: The only acceptable exceptions are: sshd and mail servers
Bye

# boa in-octopus attiks@xxx.com o2 none stable
ERROR: Please install complete BOA system before trying
ERROR: to install additional Aegir / Octopus instances
Bye
attiks commented 8 years ago

FYI: Trying again with chive disabled

attiks commented 8 years ago

Same problems

omega8cc commented 8 years ago

@attiks Can you attach/link the (anonymized) contents of the file /data/disk/o1/log/install.log (from the failed initial install, not upgrade)

omega8cc commented 8 years ago

@tourtools We can't reproduce this. Please enable debug mode in the octopus .cnf file to get more verbose output and attach/link it here.

attiks commented 8 years ago

I just restarted a new install, will post the log once finished

attiks commented 8 years ago

Installed using boa in-stable public xxx.attiks.com attiks@xxx.com o1 mini nodns

Last lines of /data/disk/o1/log/install.log

Changed group ownership of <code>sites/o1.xxx.attiks.com/files/civicrm/custom</code> to www-data                                                                                                         [success]
Changed group ownership of <code>sites/o1.xxx.attiks.com/files/civicrm/dynamic</code> to www-data                                                                                                        [success]
Changed group ownership of <code>sites/o1.xxx.attiks.com/files/civicrm/persist</code> to www-data                                                                                                        [success]
Login url: http://o1.xxx.attiks.com/user/reset/1/146xxxxxxxn0j-7e5sByjOd4E/login                                                                                            [success]
Sent welcome mail to attiks@xxx.com                                                                                                                                                                     [success]
Generated config in write(): Drupal sites.php file (/data/disk/o1/aegir/distro/001/sites/sites.php)                                                                                                       [success]
Changed permissions of /data/disk/o1/aegir/distro/001/sites/sites.php to 644                                                                                                                              [success]
Could not find the alias @hostmaster                                 [error]
The command could not be executed successfully (returned: Could not find the alias @hostmaster                                 [error]                                                    [error]
, code: 1)
attiks commented 8 years ago

Tried as o1

su - o1 -s /bin/bash
o1@h017:~$ drush @hostmaster
Could not find the alias @hostmaster 
omega8cc commented 8 years ago

We would need to see complete /data/disk/o1/log/install.log to guess what exactly happens.

omega8cc commented 8 years ago

I'm trying to reproduce this on digital ocean now.

attiks commented 8 years ago

I can give you root access if you want

omega8cc commented 8 years ago

OK, but let's see what happens with my test on digital ocean first. Maybe it is some regression we didn't catch, but we have installed and upgraded a ton of servers last night with zero issues, so we need to find what exactly happens here.

attiks commented 8 years ago

install.log at https://gist.github.com/attiks/13319230c19fcbb3d60f0dc16d5a4faa

omega8cc commented 8 years ago

Hmmm..

WD node: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '10' for key 'PRIMARY': INSERT INTO {hosting_cron} (nid, cron_interval) VALUES (:db_insert_placeholder_0,    [error]
:db_insert_placeholder_1); Array
(
    [:db_insert_placeholder_0] => 10
    [:db_insert_placeholder_1] => 3600
)
 in hosting_cron_node_insert() (line 270 of /data/disk/o1/aegir/distro/001/profiles/hostmaster/modules/aegir/hosting/cron/hosting_cron.module).
DRUPAL_INSTALL_FAILED                                                                                                                                                                                     [error]
Site installation caused an exception.                                                                                                                                                                    [error]
omega8cc commented 8 years ago

I just reproduced this on do, weird!

attiks commented 8 years ago

I'm glad it isn't just me, anything I can do?

attiks commented 8 years ago

Is there an - easy - way to re-install octopus?

omega8cc commented 8 years ago

To re-install octopus:

deluser o1
deluser o1.ftp
mv /data/disk/o1 /var/backups/
mv /home/o1.ftp /var/backups/

Now install it with boa in-octopus -- but it will fail again, we need to fix this now.

attiks commented 8 years ago

FYI: I tried it, but didn't work, running boa in-octopus gives the following

ERROR: Please install complete BOA system before trying
ERROR: to install additional Aegir / Octopus instances
Bye
attiks commented 8 years ago

Seems /var/aegir/.drush/hostmaster.alias.drushrc.php does not exist

omega8cc commented 8 years ago

The weird thing is that it always fails when I run:

boa in-octopus my@email oct1 mini stable

But works with head:

boa in-octopus my@email oct1 mini head

But we have run ton of upgrades to stable and there were no issues.

attiks commented 8 years ago

Did something change between yesterday and today? So installing head might work?

omega8cc commented 8 years ago

There were no changes, no hot-fixes, nothing. We are trying to determine what/where is the difference.

omega8cc commented 8 years ago

Even octopus up-stable oct1 force upgrade works with no issues on instance created with boa in-octopus my@email oct1 mini head (because they are the same).

omega8cc commented 8 years ago

Testing various things now, and head can be occasionally broken.

omega8cc commented 8 years ago

We have exported all packages again, forced mirrors re-sync and it works: https://gist.github.com/omega8cc/c993822e81d02052385b49f0863e80bd

We can investigate this later using old exports, but fixing this was a priority.

Thanks to all for the reports and help in debugging!

attiks commented 8 years ago

So a clean in-head install should work?

attiks commented 8 years ago

BTW thanks for the quick fix

attiks commented 8 years ago

Grrr I meant in-stable

omega8cc commented 8 years ago

Both head and stable should work. We have tested this only with boa in-octopus, though.

omega8cc commented 8 years ago

Note that boa in-octopus now allows you to define version to install:

$ boa {in-octopus} {email} {o2} {mini|max|none} {stable|head|2.4}

attiks commented 8 years ago

Will try tomorrow

omega8cc commented 8 years ago

Confirmed as fixed / tested from scratch again: https://gist.github.com/omega8cc/372c070857e97a1a9cac246546a2017e

attiks commented 8 years ago

Works like a charm, thanks!

omega8cc commented 4 years ago

@impara Please don't comment on so old and closed issues, even if you think something looks similar, because it's not. You should use BOA head, not "stable" to avoid issues, at least until we make it official that head is the new stable after we have switched away from point releases to rolling releases policy over a year ago. If you still experience problems with BOA head, please open new issue.