new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Mohammad Nabil -
Number of replies: 5

|I have production moodle 3.7
now i want to install a clean 3.11 on the same server and same domain ( different folder, data folder ,database )
3.11 need php 7.3
my 3.7 run on php 7.2
and cron job as:
"/opt/cpanel/ea-php72/root/usr/bin/php -q /home/mnabil/public_html/admin/cli/cron.php "
can i upgrade php via this button ?
is it revirsible ?
do i change my cron jop string for my moodle 3.7?

Average of ratings: -
In reply to Mohammad Nabil

Re: new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Ken Task -
Picture of Particularly helpful Moodlers

Before answering and providing links for how 2's in Moodle docs, please expand upon this:

"now i want to install a clean 3.11 on the same server and same domain"

especially the 'same domain' part ... do you mean same top level domain or another fresh 3.11 in a sub domain of the top level domain? ... like m311.smartlearn.education.

Easy Apache is outside of Moodle ... via cPanel ... it can set the version of PHP to run per domain ... top level or subdomain as your screen shot shows.

Yes, any higher version of moodle installed it would be advised to add another cron job that points to the version of PHP a Moodle is running under.

Moodle 3.11 under PHP 7.3 then the path to the php-cli to execute the code/admin/cli/cron.php script should point to the Easy Apache 7.3.

Any reason not to just upgrade the 3.7?    That would require hops as one cannot upgrade to 3.11.highest straight from 3.7.highest.   Is that what we are trying to avoid?

'SoS', Ken

Average of ratings: Useful (1)
In reply to Ken Task

Re: new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Mohammad Nabil -

The new installation id for s client want to try on my server

In reply to Mohammad Nabil

Re: new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers
I am not the expert about this, but you first need to upgrade your PHP on your server using whatever tools that you might have to do so. I forget if you are using cPanel, if you have a VPS, or are running your own server.

Then, you need to identify the path to your PHP file. It might be something like .../ea-php73/... and make this change to your cron job. Your Moodle 3.7 should work fine with php73.
Average of ratings: Useful (1)
In reply to Mohammad Nabil

Re: new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Ken Task -
Picture of Particularly helpful Moodlers

Ok, so a new subdomain ... clienttest.smartlearn.education.

The directory for code of that subdomain is in /var/www/yourcustomerid/clienttest.smartlearn.education/public_html/ (something like that).  Check the config of your moodles to see.  

That directory is set via Easy Apache to run the PHP version needed for the version of Moodle running.

Cron job is pointed to use EA/phpversion/ and that clienttest code/admin/cli/cron.php via EA/phpversion/.

Nice of you to give someone a look see at Moodle ... just remember, config's might need to be tweaked upwards - mysql/apache configs.   Multiple virtual apaches still use the same MySQL DB server and same Apache server.  And even if the clienttest instance has separate moodledata directory, it's the total space usage of that site + yours.

Basically, be careful not to overload what you run as production due to another tinker instance.

'SoS'. Ken

In reply to Mohammad Nabil

Re: new install 3.11 need php upgrade to 7.3 , can it affect current moodle3.7 ?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
How to upgrade PHP depends on the operating system viz. control panel you have been given. As such it is outside Moodle. Some even support running two PHP versions in parallel.

Personally I won't upgrade or touch my production server any other way just because of a test Moodle. If you plan to upgrade your production Moodle from 3.7 to a supported release, it is a different matter. But then I would go through the process in a different (staging) server.
Average of ratings: Useful (2)