Upgrade magento from 2.2.3 to 2.3 using command line issues

Hi,

I am upgrading the magento from 2.2.3 to 2.3 using command line in localserver as per this reference link

http://www.codextblog.com/magento-2/upgrade-magento-version-2-2-x-2-3-0/ .
php version for required for magento 2.3 is php 7.2 , and my localserver php version is:
PHP Version 7.2.27-1+ubuntu18.04.1+deb.sury.org+1

I have followed all the steps as per the above given reference link but in step 6 as I using the command –
php bin/magento setup:upgrade

Step 6: Clear cache and regenerate code.

php bin/magento setup:upgrade
After running this command it shows the errors.

PHP Fatal error: Uncaught Error: Call to undefined function MagentoFrameworkEncryptionmcrypt_module_open() in /var/www/html/venoor/vendor/magento/framework/Encryption/Crypt.php:59
Stack trace:
#0 /var/www/html/venoor/vendor/magento/framework/Encryption/Encryptor.php(401): MagentoFrameworkEncryptionCrypt->__construct(‘21048dae9013bbe…’, ‘MCRYPT_RIJNDAEL…’, ‘MCRYPT_MODE_CBC’, ‘gsLinqLEzEIfffO…’)
#1 /var/www/html/venoor/vendor/magento/framework/Encryption/Encryptor.php(313): MagentoFrameworkEncryptionEncryptor->getCrypt(‘21048dae9013bbe…’, 2, ‘gsLinqLEzEIfffO…’)
#2 /var/www/html/venoor/vendor/magento/module-config/Model/Config/Backend/Encrypted.php(113): MagentoFrameworkEncryptionEncryptor->decrypt(‘OiNuTLMClOcKG4U…’)
#3 /var/www/html/venoor/generated/code/Magento/Config/Model/Config/Backend/Encrypted/Interceptor.php(37): MagentoConfigModelConfigBackendEncrypted->processValue(‘0:2:gsLinqLEzEI…’)
#4 /var/www/html/venoor/vendor/magento/framework/App/Config/MetadataConfigTypeProcessor.php(123): Magent in /var/www/html/venoor/vendor/magento/framework/Encryption/Crypt.php on line 59

so could, you please help me to resolve these issue and upgrade the magento from 2.2.3 to 2.3

Thanks