I am tying to upgrade a Magento 2.1 site to Magento 2.2.0 but it seems to be dropping out during the process and the bin/magento file is removed but not replaced so nothing at all works after this.
I am using these commands:
cd /var/www/html
bin/magento maintenance:enable
composer require magento/product-community-edition 2.2.0 --no-update
composer update
It seems to work nicely upgrading all the files but then it seems to stop (as if it has actually finished) but I get the following and the file bin/magento has completely gone.
I am definitely using the same user account to do the upgrade as was used to install Magento so I don’t think it’s a permissions problem.
....truncated lots of updates....
- Removing theseer/fdomdocument (1.6.5)
- Installing theseer/fdomdocument (1.6.6)
Downloading: 100%
zendframework/zend-session suggests installing mongodb/mongodb (If you want to use the MongoDB session save handler)
zendframework/zend-session suggests installing zendframework/zend-cache (Zend\Cache component)
paragonie/random_compat suggests installing ext-libsodium (Provides a modern crypto API that can be used to generate random bytes.)
zendframework/zend-captcha suggests installing zendframework/zend-i18n-resources (Translations of captcha messages)
zendframework/zend-captcha suggests installing zendframework/zendservice-recaptcha (ZendService\ReCaptcha component)
ramsey/uuid suggests installing ircmaxell/random-lib (Provides RandomLib for use with the RandomLibAdapter)
ramsey/uuid suggests installing ext-libsodium (Provides the PECL libsodium extension for use with the SodiumRandomGenerator)
ramsey/uuid suggests installing ext-uuid (Provides the PECL UUID extension for use with the PeclUuidTimeGenerator and PeclUuidRandomGenerator)
ramsey/uuid suggests installing moontoast/math (Provides support for converting UUID to 128-bit integer (in string form).)
ramsey/uuid suggests installing ramsey/uuid-doctrine (Allows the use of Ramsey\Uuid\Uuid as Doctrine field type.)
ramsey/uuid suggests installing ramsey/uuid-console (A console application for generating UUIDs with ramsey/uuid)
Package fabpot/php-cs-fixer is abandoned, you should avoid using it. Use friendsofphp/php-cs-fixer instead.
Writing lock file
Generating autoload files
File doesn't exist: bin/magento
Check "chmod" section in composer.json of magento/magento2-base package.
chmod -Rf 777 bin/magento
-rwxrwxrwx 1 magentouser apache 783 Apr 25 08:20 magento
and it's enclosing folderdrwxrwxrwx 2 magentouser apache 4096 Apr 25 08:20 bin
. I'm definitely using su magentouser before running the composer commands, also the magento file is definitely there before I run the upgrade.