bin/magento deleted when upgrading to Magento 2.2.0 using composer
I've bumped into this issue as well, which I believe to be related to the package magento/magento2-base
that might have been installed already, while actually only a reinstall of that package triggers a post-install procedure that copies files from that very same package to the root of Magento (like the file bin/magento
). My remedy is to remove the vendor
folder and do composer install
.
I had the same problem.
It seems to be some kind of configuration error or some composer related issue. There is a trace of the same issue on the Magento Forum and on Magento2 Github Issue tracker.
There is a solution suggested by a Magento2 contributor here (for Enterprise Edition): https://github.com/magento/magento2/issues/4792#issuecomment-352069899
It seems that running:
composer clear-cache
composer update
would restore all eventually removed files. But it didn't work for me :-|
What I did to solve the issue was to downgrade and upgrade again.
Be very careful with filesystem permissions, you should always follow the official documentation at http://devdocs.magento.com/guides/v2.0/install-gde/prereq/file-system-perms.html