Please help Problem updating from 2.3.4 to 3.0.0

When I update by Composer 

I am writing the order 

[toevxjzw@premium32 toevolution.com]$ composer self-update
[toevxjzw@premium32 toevolution.com]$
[toevxjzw@premium32 toevolution.com]$ cd ./path/to/project/root
-bash: cd: ./path/to/project/root: No such file or directory
[toevxjzw@premium32 toevolution.com]$ composer require elgg/elgg:~3.0.0
[toevxjzw@premium32 toevolution.com]$ composer update
[toevxjzw@premium32 toevolution.com]$ vendor/bin/elgg-cli upgrade async -v
-bash: vendor/bin/elgg-cli: No such file or directory
 
I checked the files of the site and did not find the files elgg-cli (note that the version is at 2.3.4) I downloaded the latest version where they found this file and you moved it to my site, but once showed this message
[toevxjzw@premium32 toevolution.com]$ composer self-update
[toevxjzw@premium32 toevolution.com]$
[toevxjzw@premium32 toevolution.com]$ cd ./path/to/project/root
-bash: cd: ./path/to/project/root: No such file or directory
[toevxjzw@premium32 toevolution.com]$ composer require elgg/elgg:~3.0.0
[toevxjzw@premium32 toevolution.com]$ composer update
[toevxjzw@premium32 toevolution.com]$ vendor/bin/elgg-cli upgrade async -v
-bash: vendor/bin/elgg-cli: Permission denied
 
  • You need to replace 

    ./path/to/project/root

     

    with your own project root path

  • I have modified the path to the files directly but the site is not given a fault
    Which route is the closest to the root

    [toevxjzw@premium32 toevolution.com]$ cd ./home/toevxjzw/toevolution.com
    -bash: cd: ./home/toevxjzw/toevolution.com: No such file or directory
    [toevxjzw@premium32 toevolution.com]$ composer require elgg/elgg:~3.0.2
    [toevxjzw@premium32 toevolution.com]$ composer update
    [toevxjzw@premium32 toevolution.com]$ vendor/bin/elgg-cli upgrade async -v
    -bash: vendor/bin/elgg-cli: Permission denied

     

  • Maybe,

    /home/toevxjzw/toevolution.com

    not

    ./home/toevxjzw/toevolution.com

    ?

  • No steel doesn't work 

    What I think was two problems and what I said was true but the problem remains and what I think is in

    [toevxjzw@premium32 toevolution.com]$ vendor/bin/elgg-cli upgrade async -v
    -bash: vendor/bin/elgg-cli: Permission denied

    [toevxjzw@premium32 toevolution.com]$ composer self-update
    [toevxjzw@premium32 toevolution.com]$
    [toevxjzw@premium32 toevolution.com]$ cd /home/toevxjzw/toevolution.com
    [toevxjzw@premium32 toevolution.com]$ composer require elgg/elgg:~3.0.0
    [toevxjzw@premium32 toevolution.com]$ composer update
    [toevxjzw@premium32 toevolution.com]$ vendor/bin/elgg-cli upgrade async -v
    -bash: vendor/bin/elgg-cli: Permission denied

     

  • Problem with using elgg-cli is that the shell user you are logged in as might not have the necessary permissions to read/write the files and folders (e.g. data directory of Elgg) that would have to be accessed during the upgrade.

    To be honest, I haven't figured out myself how I would make use of elgg-cli without breaking things. With the normal user I also get permission denied issues. The webserver user (who owns for example the files in the data directory) is not allowed to execute any shell stuff and when doing stuff as root user there's no immediate problem with permissions (as root can read/write everywhere) but with any newly created files and folders you most likely get problems later when these files and folders are supposed to be accessed by the webserver who fails to do so if the files and folders are owned by root.

    The upgrades can be run when logged in to your site from the admin area, too, after composer has upgraded the Elgg version. Maybe that's less troublesome.

  • It seems that this method does not work for Do you use the other manual way is by scanning the site files and add files of the new version, but this way will enable me to maintain the posts and evidence on the site?

  • Have you upgraded Elgg before or have you never tried it?

    Have you installed Elgg with composer or had you installed it by using the zip archive available here on the site?

    composer only deals with upgrading the content of the install folder of Elgg. By default it wouldn't deal with additional plugins and it's a certain knowledge necessary to handle it.

    If you have not used composer so far, there's no need to use it now. The legacy way with using the zip archives of Elgg versions can still be used also for Elgg 3 (http://learn.elgg.org/en/stable/admin/upgrading.html#b-manual-upgrade-legacy-approach). Some might prefer using composer, but I would definitely suggest to learn how to use composer by trying it on a separate test installation and not on your production site.

    The data of your Elgg site is in the database and in the data directory. Changing the content of the Elgg install folder (i.e. replacing the files with a new version) does not result in losing the data. Just read the upgrade instructions BEFORE trying to do the upgrade. And always BACKUP the install folder, database and data directory BEFORE starting an upgrade.

    You don't have to compare every single file of the old and new Elgg version to find out which files to replace. When using composer the replacement of the files would be done by composer. But also when using the zip archive (legacy) method to upgrade to a new Elgg version you don't have to manually replace every single file. Backup first! You can just delete the old files of Elgg within the Elgg install folder with a few exceptions (keep .htaccess, keep elgg-config/settings.php and keep the plugin folders of 3rd party plugins in the mod directory and in case you have other files in the install folder not belonging to Elgg also keep these). All the other files can be deleted and then the new version of Elgg can be copied into the install folder. Then you need to upgrade elgg-config/settings.php and .htaccess (especially when upgrading from Elgg 2 to 3). The templates of these two files are vendor/elgg/elgg/install/config/htaccess.dist and /home/daniel/public_html/elgg20zip/vendor/elgg/elgg/elgg-config/settings.example.php. You would take these template files and edit them to add your site-specific data (in the settings file you would add for example the database credentials, in the htaccess file you might need to change something if you made changes in .htaccess on your own in your current Elgg installation). Then you would save the edited template files as .htaccess and elgg-config/settings.php respectively. The install folder would be updated now. The next step would be to upgrade the database as described in step 6 and 7 at http://learn.elgg.org/en/stable/admin/upgrading.html#b-manual-upgrade-legacy-approach.

    If you upgrade from Elgg 2 to 3 you should only do so if there are compatible versions available of all 3rd party plugins you use. Otherwise, it's very likely that they won't work on Elgg 3. Best would be to try the whole upgrade process with a test installation if you have never done it before. While backups are a MUST and the site can be restored using the backups in case something unexpected happens or something simply goes wrong it is surely better to know before what exactly happens during an upgrade. And learning it on a test installation where no important user data is involved is surely a good way.