Need Assistance on Jenkins Upgrade from 2.31x to 2. in Ubuntu 22.04

I am using jenkins 2.319.1 currently in ubuntu 22.04 LTS and accessible by 8443 port . i tried to upgrade it to 2.426.3 directly by replacing the war file under /usr/share/jenkins path and started the jenkins service. jenkins service is active but there are lot of errors in log saying winstone.WinstoneException: Please set --httpsKeyStore and jenkins is no more accessible to 8443 port anymore .

Can someone help me to identify whats going wrong .

You service is probably still an init service and not a service based on systemd. With 2.332.x Jenkins changed the service to use systemd (Upgrading to Jenkins LTS 2.332.x)
Instead of replacing the war file you should update your package with your package manager.

Thanks for you response . So you mean i have to first upgrade my jenkins to 2.33 using package manager instead of replacing the war and then to higher version .

If i do so is there any way can rollback if in case any issue .
let me know what should be the best approach for the upgrade .

Yes first upgrade with the package manager, it might be possible to directly use the latest version.
Take a backup of your JENKINS_HOME before upgrading which is always a good idea especially when you want to do such a big jump from a over 2 year old version.