I am using magento 2.2 on ubunto with lastest php and sql version but now i want to install magento 1.5 CE on these but don't work. Are these lastest versions support 1.5 ver or not?
Well magento 1.5 installation is not depends on the Ubuntu os version if its 16.X then it will also works !
But in your case its not working because of PHP version and mysql version as well !
So you need to use PHP version which is supported by Magento version 1.5
installed all that technology stack on this ubuntu version only and then try !
It will works for the same !
Probably the problem is you're using unsupported versions.
Since Magento 2.2 needs these versions: https://devdocs.magento.com/guides/v2.2/install-gde/system-requirements-tech.html
Magento 1 needs these ones: https://docs.magento.com/m1/ce/user_guide/magento/system-requirements.html
But Magento 1.5 needs even older versions of PHP and Mysql.
Why you could need to choose between Magento 2.2 or 1.5? There is a huge difference.