oroinc / crm

Main OroCRM package with core functionality.
Other
653 stars 212 forks source link

Detect & warn about old data on install #155

Open vfbsilva opened 8 years ago

vfbsilva commented 8 years ago

Folks seems some files are missing on the commit from 1.9.0. I have an open discussion on the forums

[Tue Mar 01 15:10:06.627851 2016] [:error] [pid 24592] [client 10.32.83.51:47569] PHP Warning:  require(/var/www/html/crm-application/app/../vendor/autoload.php): failed to open stream: No such file or directory in /var/www/html/crm-application/app/autoload.php on line 5
[Tue Mar 01 15:10:06.627940 2016] [:error] [pid 24592] [client 10.32.83.51:47569] PHP Fatal error:  require(): Failed opening required '/var/www/html/crm-application/app/../vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /var/www/html/crm-application/app/autoload.php on line 5

I was able to find the mentioned files in other versions of the package but just adding them did not solve the problem.

rodolfobandeira commented 8 years ago

@vfbsilva answered you on forum.

It's compaining that you don't have /var/www/html/crm-application/vendor/autoload.php which must be generated automatically when you run composer install

vfbsilva commented 8 years ago

@rodolfobandeira I have it in many places: `

In many places:

./html/orocrm/app/autoload.php
./html/orocrm/vendor/zendframework/zend-stdlib/src/compatibility/autoload.php
./html/orocrm/vendor/autoload.php
./html/orocrm/vendor/symfony/symfony/src/Symfony/Component/Intl/Resources/bin/autoload.php
./html/crm-application/app/autoload.php
./html/orocrm/app/autoload.php
./html/orocrm/vendor/zendframework/zend-stdlib/src/compatibility/autoload.php
./html/orocrm/vendor/autoload.php
./html/orocrm/vendor/symfony/symfony/src/Symfony/Component/Intl/Resources/bin/autoload.php
./html/crm-application/app/autoload.php

`

All owned by the apache user.

mbessolov commented 8 years ago

If I understand your setup correctly /var/www/html/orocrm and /var/www/html/crm-application are two different installations. And it seems that you have never run composer install command inside the /var/www/html/crm-application folder.

vfbsilva commented 8 years ago

@mbessolov the files are just copies of the same install sorry I forgot to supress it from the ls output this was due a suggestion from a guy here on the support forum.

At the official docs listed here it does not explicitly asks me to run composer install inside the app folder. Instead it asks for an update there. According to this. Oki running the command inside the folder yelded another (better) error. php -dmemory_limit=4G /bin/composer update

The following exception is caused by a lack of memory and not having swap configured Check https://getcomposer.org/doc/articles/troubleshooting.md#proc-open-fork-failed-errors for details

PHP Fatal error: Uncaught exception 'ErrorException' with message 'proc_open(): fork failed - Cannot allocate memory' in phar:///usr/bin/composer/vendor/symfony/console/Application.php:954 Stack trace:

0 [internal function]: Composer\Util\ErrorHandler::handle(2, 'proc_open(): fo...', 'phar:///usr/bin...', 954, Array)

1 phar:///usr/bin/composer/vendor/symfony/console/Application.php(954): proc_open('stty -a | grep ...', Array, NULL, NULL, NULL, Array)

2 phar:///usr/bin/composer/vendor/symfony/console/Application.php(754): Symfony\Component\Console\Application->getSttyColumns()

3 phar:///usr/bin/composer/vendor/symfony/console/Application.php(715): Symfony\Component\Console\Application->getTerminalDimensions()

4 phar:///usr/bin/composer/vendor/symfony/console/Application.php(648): Symfony\Component\Console\Application->getTerminalWidth()

5 phar:///usr/bin/composer/vendor/symfony/console/Application.php(130): Symfony\Component\Console\Application->renderException(Object(ErrorException), Object(Symfony\Component\Console\Out in phar:///usr/bin/composer/vendor/symfony/console/Application.php on line 954

Fatal error: Uncaught exception 'ErrorException' with message 'proc_open(): fork failed - Cannot allocate memory' in phar:///usr/bin/composer/vendor/symfony/console/Application.php:954 Stack trace:

0 [internal function]: Composer\Util\ErrorHandler::handle(2, 'proc_open(): fo...', 'phar:///usr/bin...', 954, Array)

1 phar:///usr/bin/composer/vendor/symfony/console/Application.php(954): proc_open('stty -a | grep ...', Array, NULL, NULL, NULL, Array)

2 phar:///usr/bin/composer/vendor/symfony/console/Application.php(754): Symfony\Component\Console\Application->getSttyColumns()

3 phar:///usr/bin/composer/vendor/symfony/console/Application.php(715): Symfony\Component\Console\Application->getTerminalDimensions()

4 phar:///usr/bin/composer/vendor/symfony/console/Application.php(648): Symfony\Component\Console\Application->getTerminalWidth()

5 phar:///usr/bin/composer/vendor/symfony/console/Application.php(130): Symfony\Component\Console\Application->renderException(Object(ErrorException), Object(Symfony\Component\Console\Out in phar:///usr/bin/composer/vendor/symfony/console/Application.php on line 954

mbessolov commented 8 years ago

According to the installation instructions at http://www.orocrm.com/documentation/index/current/book/installation here is the list of what has to be done to install the latest version of OroCRM:

cd /var/www
git clone -b 1.9.0 https://github.com/orocrm/platform-application.git orocrm-1.9.0
cd orocrm-1.9.0
composer install
php app/console oro:install --env prod
php app/console clank:server --env prod
pwd
# pwd will print the full path to your installation, use it below
# add the following string to the crontab to be executed every minute
# replace THE_PWD_RESULT with what pwd command printed on the previous step
# php THE_PWD_RESULT/app/console oro:cron --env prod

or, if you are using a downloaded archive instead of GitHub:

# extract the contents of the archive into orocrm-1.9.0 directory,
# after the extraction the orocrm-1.9.0 directory should have app, src and vendor folders, and a number of files.
cd orocrm-1.9.0
composer install
pwd
# pwd will print the full path to your installation, use it below
# add the following string to the crontab to be executed every minute
# replace THE_PWD_RESULT with what pwd command printed on the previous step
# php THE_PWD_RESULT/app/console oro:cron --env prod
vfbsilva commented 8 years ago

Oki done as suggested. Still a problem:

php -dmemory_limit=2G /bin/composer -vvv --no-dev install

Reading ./composer.json Loading config file /root/.composer/config.json Loading config file /root/.composer/auth.json Loading config file ./composer.json Checking CA file /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem Executing command (/var/www/html/crm-application): git branch --no-color --no-abbrev -v Executing command (/var/www/html/crm-application): git describe --exact-match --tags Failed to initialize global composer: Composer could not find the config file: /root/.composer/composer.json To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" section Reading /var/www/html/crm-application/vendor/composer/installed.json Loading plugin ComponentInstaller\ComponentInstallerPlugin Reading ./composer.lock Loading composer repositories with package information Installing dependencies from lock file Reading ./composer.lock Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them. Analyzed 273 packages to resolve dependencies Analyzed 847 rules to resolve dependencies Nothing to install or update Generating autoload files post-autoload-dump: ComponentInstaller\Installer::postAutoloadDump Compiling component files post-install-cmd: Incenteev\ParameterHandler\ScriptHandler::buildParameters Updating the "app/config/parameters.yml" file post-install-cmd: Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap post-install-cmd: Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile post-install-cmd: Oro\Bundle\InstallerBundle\Composer\ScriptHandler::setPermissions post-install-cmd: Oro\Bundle\InstallerBundle\Composer\ScriptHandler::installAssets post-install-cmd: Oro\Bundle\InstallerBundle\Composer\ScriptHandler::setAssetsVersion Initializing the "assets_version_strategy" parameter service httpd restart Redirecting to /bin/systemctl restart httpd.service

Same behavior.

rodolfobandeira commented 8 years ago

I would remove this folder and reinstall everything again following the instructions they gave to you.

vfbsilva commented 8 years ago

I've done it. Started with a folder from scratch same result.


#  php -d memory_limit=2G composer.phar install --prefer-dist --no-dev
Loading composer repositories with package information
Installing dependencies from lock file
  - Installing behat/transliterator (v1.1.0)
    Loading from cache

  - Installing twig/twig (v1.20.0)
    Loading from cache

  - Installing psr/log (1.0.0)
    Loading from cache

  - Installing doctrine/lexer (v1.0.1)
    Loading from cache

  - Installing doctrine/inflector (v1.1.0)
    Loading from cache

  - Installing doctrine/collections (v1.3.0)
    Loading from cache

  - Installing doctrine/cache (v1.5.4)
    Loading from cache

  - Installing doctrine/annotations (v1.2.7)
    Loading from cache

  - Installing doctrine/common (v2.5.3)
    Loading from cache

  - Installing symfony/symfony (v2.7.6)
    Loading from cache

  - Installing evenement/evenement (v1.0.0)
    Loading from cache

  - Installing react/stream (v0.3.4)
    Loading from cache

  - Installing react/event-loop (v0.3.4)
    Loading from cache

  - Installing react/socket (v0.3.4)
    Loading from cache

  - Installing guzzle/guzzle (v3.7.4)
    Loading from cache

  - Installing cboden/ratchet (v0.2.8)
    Loading from cache

  - Installing doctrine/doctrine-cache-bundle (1.3.0)
    Loading from cache

  - Installing doctrine/instantiator (1.0.5)
    Loading from cache

  - Installing imagine/imagine (v0.5.0)
    Loading from cache

  - Installing jdorn/sql-formatter (v1.2.17)
    Loading from cache

  - Installing jms/cg (1.1.0)
    Loading from cache

  - Installing jms/metadata (1.5.1)
    Loading from cache

  - Installing jms/aop-bundle (1.2.0)
    Loading from cache

  - Installing jms/di-extra-bundle (1.6.0)
    Loading from cache

  - Installing phpoption/phpoption (1.5.0)
    Loading from cache

  - Installing jms/parser-lib (1.0.0)
    Loading from cache

  - Installing justinrainbow/json-schema (1.6.1)
    Loading from cache

  - Installing knplabs/gaufrette (v0.1.9)
    Loading from cache

  - Installing kriswallsmith/buzz (v0.15)
    Loading from cache

  - Installing michelf/php-markdown (1.6.0)
    Loading from cache

  - Installing kriswallsmith/assetic (v1.1.2)
    Loading from cache

  - Installing robloach/component-installer (0.2.3)
    Loading from cache

  - Installing moment/moment (2.11.2)
    Loading from cache

  - Installing zendframework/zend-stdlib (2.1.5)
    Loading from cache

  - Installing zendframework/zend-servicemanager (2.1.5)
    Loading from cache

  - Installing zendframework/zend-i18n (2.1.5)
    Loading from cache

  - Installing zendframework/zend-validator (2.1.5)
    Loading from cache

  - Installing zendframework/zend-mime (2.1.5)
    Loading from cache

  - Installing zendframework/zend-loader (2.1.5)
    Loading from cache

  - Installing zendframework/zend-math (2.1.5)
    Loading from cache

  - Installing zendframework/zend-crypt (2.1.5)
    Loading from cache

  - Installing zendframework/zend-mail (2.1.5)
    Loading from cache

  - Installing components/jquery (2.1.4)
    Loading from cache

  - Installing vakata/jstree (3.2.1)
    Loading from cache

  - Installing twig/extensions (v1.0.1)
    Loading from cache

  - Installing tinymce/tinymce (4.1.10)
    Loading from cache

  - Installing swiftmailer/swiftmailer (v5.4.1)
    Loading from cache

  - Installing symfony/swiftmailer-bundle (v2.3.11)
    Loading from cache

  - Installing monolog/monolog (1.8.0)
    Loading from cache

  - Installing symfony/monolog-bundle (v2.7.1)
    Loading from cache

  - Installing symfony/icu (v1.2.2)
    Loading from cache

  - Installing symfony/assetic-bundle (v2.3.0)
    Loading from cache

  - Installing sylius/flow-bundle (v0.6.0)
    Loading from cache

  - Installing gedmo/doctrine-extensions (v2.3.12)
    Loading from cache

  - Installing stof/doctrine-extensions-bundle (v1.1.0)
    Loading from cache

  - Installing sensio/framework-extra-bundle (v2.3.4)
    Loading from cache

  - Installing sensiolabs/security-checker (v3.0.2)
    Loading from cache

  - Installing sensio/distribution-bundle (v4.0.3)
    Loading from cache

  - Installing mustangostang/spyc (0.5.1)
    Loading from cache

  - Installing piwik/device-detector (3.5.2)
    Loading from cache

  - Installing oro/moment-timezone (0.3.1)
    Loading from cache

  - Installing oro/jsplumb (1.7.6)
    Loading from cache

  - Installing doctrine/dbal (v2.5.1)
    Loading from cache

  - Installing doctrine/orm (v2.5.1)
    Loading from cache

  - Installing oro/doctrine-extensions (1.0.11)
    Loading from cache

  - Installing zendframework/zend-eventmanager (2.1.5)
    Loading from cache

  - Installing zendframework/zend-code (2.1.5)
    Loading from cache

  - Installing ocramius/proxy-manager (0.4.1)
    Loading from cache

  - Installing nesbot/carbon (1.8.0)
    Loading from cache

  - Installing nelmio/api-doc-bundle (2.9.0)
    Loading from cache

  - Installing mtdowling/cron-expression (v1.0.4)
    Loading from cache

  - Installing liip/imagine-bundle (v0.17.1)
    Loading from cache

  - Installing lexik/maintenance-bundle (1.0.3)
    Loading from cache

  - Installing leafo/lessphp (v0.4.0)
    Loading from cache

  - Installing knplabs/knp-menu (v2.0.0-alpha2)
    Loading from cache

  - Installing knplabs/knp-menu-bundle (v2.0.0-alpha2)
    Loading from cache

  - Installing knplabs/knp-gaufrette-bundle (v0.1.7)
    Loading from cache

  - Installing phpcollection/phpcollection (0.2.0)
    Loading from cache

  - Installing jms/serializer (0.14.0)
    Loading from cache

  - Installing jms/serializer-bundle (0.13.0)
    Loading from cache

  - Installing jms/job-queue-bundle (1.2.0)
    Loading from cache

  - Installing jdare/clank-bundle (0.1.6)
    Loading from cache

  - Installing incenteev/composer-parameter-handler (v2.1.0)
    Loading from cache

  - Installing hwi/oauth-bundle (0.4.0)
    Loading from cache

  - Installing genemu/form-bundle (v2.2.1)
    Loading from cache

  - Installing willdurand/negotiation (1.5.0)
    Loading from cache

  - Installing willdurand/jsonp-callback-validator (v1.1.0)
    Loading from cache

  - Installing friendsofsymfony/rest-bundle (1.7.1)
    Loading from cache

  - Installing friendsofsymfony/jsrouting-bundle (1.5.4)
    Loading from cache

  - Installing ezyang/htmlpurifier (v4.6.0)
    Loading from cache

  - Installing escapestudios/wsse-authentication-bundle (1.0.2)
    Loading from cache

  - Installing doctrine/doctrine-bundle (v1.4.0)
    Loading from cache

  - Installing doctrine/data-fixtures (v1.1.1)
    Loading from cache

  - Installing doctrine/doctrine-fixtures-bundle (v2.2.0)
    Loading from cache

  - Installing seld/jsonlint (1.4.0)
    Loading from cache

  - Installing composer/composer (1.0.0-p1)
    Loading from cache

  - Installing components/underscore (1.7.0)
    Loading from cache

  - Installing components/font-awesome (4.3.0)
    Loading from cache

  - Installing components/backbone (1.1.2)
    Loading from cache

  - Installing ass/xmlsecurity (v1.0.0)
    Loading from cache

  - Installing besimple/soap (v0.2.2)
    Loading from cache

  - Installing akeneo/batch-bundle (0.4.2)
    Loading from cache

  - Installing a2lix/translation-form-bundle (1.3)
    Loading from cache

  - Installing oro/platform (1.9.0)
    Loading from cache

  - Installing oro/crm (1.9.0)
    Loading from cache

Generating autoload files
> ComponentInstaller\Installer::postAutoloadDump
Compiling component files
> Incenteev\ParameterHandler\ScriptHandler::buildParameters
Creating the "app/config/parameters.yml" file
Some parameters are missing. Please provide them.
database_driver (pdo_mysql): 
database_host (127.0.0.1): 
database_port (null): 3306
database_name (oro_crm): 
database_user (root): 
database_password (null): 
mailer_transport (smtp): 
mailer_host (127.0.0.1): 
mailer_port (null): 
mailer_encryption (null): 
mailer_user (null): 
mailer_password (null): 
websocket_bind_address (0.0.0.0): 
websocket_bind_port (8080): 
websocket_frontend_host ('*'): 
websocket_frontend_port (8080): 
websocket_backend_host ('*'): 
websocket_backend_port (8080): 
session_handler (session.handler.native_file): 
locale (en): 
secret (ThisTokenIsNotSoSecretChangeIt): 
installed (null): 
assets_version (null): 
assets_version_strategy (time_hash): 
> Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap
> Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile
> Oro\Bundle\InstallerBundle\Composer\ScriptHandler::setPermissions
> Oro\Bundle\InstallerBundle\Composer\ScriptHandler::installAssets
> Oro\Bundle\InstallerBundle\Composer\ScriptHandler::setAssetsVersion
Updating the "assets_version" parameter
[root@lojacrmdes crm-application]#  php app/console oro:install –env prod
^C
[root@lojacrmdes crm-application]#  php app/console oro:install --env prod
Installing Oro Application.

Oro requirements check:
+---------+-----------------------------------------------------------------------------------------------+
| Check   | Mandatory requirements                                                                        |
+---------+-----------------------------------------------------------------------------------------------+
| OK      | Vendor libraries must be installed                                                            |
| OK      | app/cache/ or var/cache/ directory must be writable                                           |
| OK      | app/logs/ or var/logs/ directory must be writable                                             |
| OK      | Configured default timezone "America/Sao_Paulo" must be supported by your installation of PHP |
| OK      | iconv() must be available                                                                     |
| OK      | json_encode() must be available                                                               |
| OK      | session_start() must be available                                                             |
| OK      | ctype_alpha() must be available                                                               |
| OK      | token_get_all() must be available                                                             |
| OK      | simplexml_import_dom() must be available                                                      |
| OK      | PCRE extension must be available                                                              |
| OK      | Cache folder should not be inside encrypted directory                                         |
+---------+-----------------------------------------------------------------------------------------------+
+---------+--------------------------------------------+
| Check   | PHP settings                               |
+---------+--------------------------------------------+
| OK      | date.timezone setting must be set          |
| OK      | detect_unicode must be disabled in php.ini |
| OK      | string functions should not be overloaded  |
| OK      | memory_limit should be at least 512M       |
+---------+--------------------------------------------+
+---------+-------------------------------------------------------+
| Check   | Oro specific requirements                             |
+---------+-------------------------------------------------------+
| OK      | PHP version must be at least 5.4.9 (5.4.16 installed) |
| OK      | GD extension must be at least 2.0                     |
| OK      | cURL extension must be at least 7.0                   |
| OK      | mcrypt_encrypt() should be available                  |
| OK      | intl extension should be available                    |
| OK      | icu library must be at least 3.8                      |
| OK      | web/uploads/ directory must be writable               |
| OK      | web/media/ directory must be writable                 |
| OK      | web/bundles/ directory must be writable               |
| OK      | app/attachment/ directory must be writable            |
| OK      | web directory must be writable                        |
| OK      | app/config/parameters.yml file must be writable       |
+---------+-------------------------------------------------------+
+---------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Check   | Optional recommendations                                                                                                                                                                                                                  |
+---------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| OK      | Requirements file should be up-to-date                                                                                                                                                                                                    |
| OK      | When using the logout handler from the Symfony Security Component, you should have at least PHP 5.4.11 due to PHP bug #63379 (as a workaround, you can also set invalidate_session to false in the security logout handler configuration) |
| OK      | PCRE extension should be at least version 8.0 (8.32 installed)                                                                                                                                                                            |
| OK      | PHP-DOM and PHP-XML modules should be installed                                                                                                                                                                                           |
| OK      | mb_strlen() should be available                                                                                                                                                                                                           |
| OK      | iconv() should be available                                                                                                                                                                                                               |
| OK      | utf8_decode() should be available                                                                                                                                                                                                         |
| OK      | filter_var() should be available                                                                                                                                                                                                          |
| OK      | posix_isatty() should be available                                                                                                                                                                                                        |
| OK      | intl extension should be available                                                                                                                                                                                                        |
| OK      | intl extension should be correctly configured                                                                                                                                                                                             |
| OK      | intl ICU version should be at least 4+                                                                                                                                                                                                    |
| OK      | intl.error_level should be 0 in php.ini                                                                                                                                                                                                   |
| WARNING | Install and/or enable a PHP accelerator (highly recommended).                                                                                                                                                                             |
| OK      | short_open_tag should be disabled in php.ini                                                                                                                                                                                              |
| OK      | magic_quotes_gpc should be disabled in php.ini                                                                                                                                                                                            |
| OK      | register_globals should be disabled in php.ini                                                                                                                                                                                            |
| OK      | session.auto_start should be disabled in php.ini                                                                                                                                                                                          |
| OK      | PDO should be installed                                                                                                                                                                                                                   |
| OK      | PDO should have some drivers installed (currently available: mysql, sqlite)                                                                                                                                                               |
| OK      | SOAP extension should be installed (API calls)                                                                                                                                                                                            |
| OK      | A JS Engine (node) is installed                                                                                                                                                                                                           |
+---------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Setting up database.
Process migrations...
  > Oro\Bundle\EntityExtendBundle\Migration\LoadEntityConfigStateMigration
  > Oro\Bundle\MigrationBundle\Migration\UpdateBundleVersionMigration
  > Oro\Bundle\EntityExtendBundle\Migration\RefreshExtendCacheMigration
  > Oro\Bundle\EntityConfigBundle\Migration\UpdateEntityConfigMigration
  > Oro\Bundle\EntityExtendBundle\Migration\UpdateExtendConfigMigration
  > OroCRM\Bundle\ActivityContactBundle\Migration\ActivityContactMigration
  > Oro\Bundle\ActivityListBundle\Migration\ActivityListMigration
  > Oro\Bundle\EntityExtendBundle\Migration\UpdateExtendIndicesMigration
  > Oro\Bundle\EntityConfigBundle\Migration\WarmUpEntityConfigCacheMigration
Loading workflow definitions...
  > task_flow
  > b2b_flow_lead
  > b2b_flow_sales
  > b2b_flow_sales_funnel
  > b2c_flow_abandoned_shopping_cart
  > b2c_flow_order_follow_up
Loading process definitions...
  > sync_email_flag_after_changed
  > schedule_integration
  > clear_user_email_origin_on_deactivation
  > clear_imap_email_folder_on_sync_enabled_change
  > analytics_channel_calculate_rfm
  > convert_mailbox_email_to_lead
  > magento_customer_creation
  > magento_customer_export
  > magento_customer_address_export
  > magento_analytics_customer_calculate
  > magento_analytics_customer_calculate_imported
  > magento_schedule_integration
  > convert_mailbox_email_to_case
Loading process triggers...
  > sync_email_flag_after_changed:update
  > schedule_integration:update
  > schedule_integration:create
  > clear_user_email_origin_on_deactivation:update
  > clear_imap_email_folder_on_sync_enabled_change:update
  > analytics_channel_calculate_rfm:update
  > magento_customer_creation:create
  > magento_customer_export:update
  > magento_customer_address_export:update
  > magento_analytics_customer_calculate_imported:create
  > magento_analytics_customer_calculate:update
  > magento_schedule_integration:update
No enabled process triggers with cron expression found.

Administration setup.
Application URL (http://localhost/oro): http://localhost/crm-application 
Organization name (OroCRM): serpro

  [Doctrine\ORM\NoResultException]                                       
  No result was found for query although at least one row was expected.  

oro:organization:update [--organization-name [ORGANIZATION-NAME]] [--organization-description [ORGANIZATION-DESCRIPTION]] [--organization-enabled [ORGANIZATION-ENABLED]] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-s|--shell] [--process-isolation] [-e|--env ENV] [--no-debug] [--jms-job-id JMS-JOB-ID] [--disabled-listeners DISABLED-LISTENERS] [--] <command> <organization-name>

  [RuntimeException]                            
  The command terminated with an exit code: 1.  

oro:install [--application-url [APPLICATION-URL]] [--organization-name [ORGANIZATION-NAME]] [--user-name [USER-NAME]] [--user-email [USER-EMAIL]] [--user-firstname [USER-FIRSTNAME]] [--user-lastname [USER-LASTNAME]] [--user-password [USER-PASSWORD]] [--force] [--symlink] [--sample-data [SAMPLE-DATA]] [--drop-database] [--force-debug] [--timeout [TIMEOUT]] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-s|--shell] [--process-isolation] [-e|--env ENV] [--no-debug] [--jms-job-id JMS-JOB-ID] [--disabled-listeners DISABLED-LISTENERS] [--] <command>
dxops commented 8 years ago

looks like database contains data from previous installation attempts

Process migrations...
  > Oro\Bundle\EntityExtendBundle\Migration\LoadEntityConfigStateMigration

please drop and recreate database before install

vfbsilva commented 8 years ago

@sergeyz I've selected on the gui installer to do such thing I've dropped the database manually now and it did work. So I think part of the problem was that the guy installer is not dropping the DB. Maybe it could pop a bigger warning?

dxops commented 8 years ago

Will check drop database for gui installer, thanks for report!

woei66 commented 8 years ago

Thanks to @sergeyz 's suggestion of oro-crom, you have excellent experience and identify the root cause is "database contains data from previous installation"

Some suggestions to oro-crm development teams: If the database contains old data of previous installation and it will cause the installation failure, please add the problem detection or warning message at the console mode and tell users how to do. Or, it should detect the problem and stop the installation and ask users drop the database and displays warning/error messages to users and ask them if they want to drop previous database to continue ..

It's important that without these information and experiences that will waste your time and our time to figure out the root cause.

I am Magento2 users and I faced the same case. This problem should be fixed permanently.

artml commented 8 years ago

@woei66 I have created a ticket in our backlog, but it's hard to say now when we will be able to provide a permanent fix. I am marking this as open for community contribution for now, and will change the status as soon as we'll schedule the fix for some version. I've also updated the issue title to make it more clear.

Thanks for your contribution!