"Failed to start application" error after php upgrade

General questions relating to Joomla! 3.x.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting.
Forum Post Assistant - If you are serious about wanting help, you should use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10
Locked
AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

"Failed to start application" error after php upgrade

Post by AndyInSpain » Mon Apr 25, 2022 10:23 am

Hi guys,

I am running Joomla under Xampp, but now, when trying to start Joomla after upgrading php from 7.4 to 8.1.4, I am getting a "Error: Failed to start application: Failed to start the session" error. Both Apache and MySQL are running under the new version of php without problems. I can connect to the database through Heidi SQL, so logging into the database appears to be OK.

I am using the latest version 3 Joomla (sorry, as I can't get in to Joomla I cannot tell you exactly which version - I updated Joomla about a week ago, if that helps).

I am hoping that some clever person will be able to say, aha, after upgrading your php you need to do THIS to get Xampp and Joomla working together. That's my hope, anyway!! :) Or failing that, I'm hoping somebody will be able to give me some pointers as to a possible cause/solution.

I hasten to add that I have not made any changes except upgrading php.

Many thanks in advance!

Andy
Last edited by toivo on Mon Apr 25, 2022 1:10 pm, edited 1 time in total.
Reason: mod note: moved from 4.x General Questions

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 44118
Joined: Sat Apr 05, 2008 9:58 pm

Re: "Failed to start application" error after php upgrade

Post by Webdongle » Mon Apr 25, 2022 12:23 pm

Suggest you use wamp. Copy your website to that. You can change php on the fly with Wamp.
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".

AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

Re: "Failed to start application" error after php upgrade

Post by AndyInSpain » Mon Apr 25, 2022 12:42 pm

Thanks for your help, but I really don't want to get involved in any migrations until there is no other option. I am sure there must be a way of running Joomla again after the php upgrade.

gws
Joomla! Champion
Joomla! Champion
Posts: 5973
Joined: Tue Aug 23, 2005 1:56 pm
Location: South coast, UK
Contact:

Re: "Failed to start application" error after php upgrade

Post by gws » Mon Apr 25, 2022 1:04 pm

Downgrade the php,j3.x and php 8.1.4 are not a good mix.
I, like webdongle suggest that you use wampserver it is far more versatile than xamp.
You posted in the J4 forum rather than the J3 forum.

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: "Failed to start application" error after php upgrade

Post by sozzled » Mon Apr 25, 2022 4:39 pm

AndyInSpain wrote:
Mon Apr 25, 2022 10:23 am
... I'm hoping somebody will be able to give me some pointers as to a possible cause/solution.
Search for solutions to this problem here: https://www.google.com/search?q=%22Fail ... session%22 :)

AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

Can Anybody Decipher These Error Codes?

Post by AndyInSpain » Tue Apr 26, 2022 3:48 pm

Hi all,

I'm running Joomla 3 (latest) under Xampp. After upgrading my php from 7.4 to 8.1.5, Joomla will not start and throws the following errors. Can anybody tell me what they mean and how I might resolve the issue? Many thanks!!!


Deprecated: Joomla\Input\Input implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in I:\xampp7\htdocs\libraries\vendor\joomla\input\src\Input.php on line 41

Deprecated: Return type of Joomla\Input\Input::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in I:\xampp7\htdocs\libraries\vendor\joomla\input\src\Input.php on line 170

Deprecated: Joomla\CMS\Input\Input implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in I:\xampp7\htdocs\libraries\src\Input\Input.php on line 31

Warning: session_name(): Session name cannot be changed after headers have already been sent in I:\xampp7\htdocs\libraries\joomla\session\handler\native.php on line 128

Deprecated: Joomla\CMS\Input\Cookie implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in I:\xampp7\htdocs\libraries\src\Input\Cookie.php on line 21

Warning: session_cache_limiter(): Session cache limiter cannot be changed after headers have already been sent in I:\xampp7\htdocs\libraries\joomla\session\handler\native.php on line 235

Error: Failed to start application: Failed to start the session because headers have already been sent by "I:\xampp7\htdocs\libraries\vendor\joomla\input\src\Input.php" at line 41.
Last edited by toivo on Wed Apr 27, 2022 11:09 am, edited 1 time in total.
Reason: mod note: merged with the current topic

chmst
Joomla! Intern
Joomla! Intern
Posts: 51
Joined: Mon Jan 16, 2012 8:17 am

Re: Can Anybody Decipher These Error Codes?

Post by chmst » Tue Apr 26, 2022 4:11 pm

There was an issue with debug-mode and error-reporting when J3 was installed with php 8.1.
In the latest version of j3, the issue should be resolved.
You can set debug mode="false" and error-reportig="none" in your application (configuration.php), then pdate to the newest version of 3.10.
Team lead of Joomla Accessbility Team, active on mattermost and joomla.forum.de

AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

Re: Can Anybody Decipher These Error Codes?

Post by AndyInSpain » Wed Apr 27, 2022 8:51 am

Many thanks for your help! But even with $debug = 0 and $error_reporting="none", I still get "Failed to start application: Failed to start the session". Do you have any ideas how I can access Joomla to update it?

Much appreciated

Andy.

chmst
Joomla! Intern
Joomla! Intern
Posts: 51
Joined: Mon Jan 16, 2012 8:17 am

Re: Can Anybody Decipher These Error Codes?

Post by chmst » Wed Apr 27, 2022 9:33 am

Weird :) In general the message can result from error in database connection.
You wrote that you upgraded your php. Maybe there something went wrong?

I saved my htdocs folder and exported all databases, then dinstldeinstalled my old xampp completely and installed the newest Version of xampp with php 8.1. Then restored all my applications again. No problems since the issue with debug / error-reporting is resolved.
Team lead of Joomla Accessbility Team, active on mattermost and joomla.forum.de

AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

Re: Can Anybody Decipher These Error Codes?

Post by AndyInSpain » Wed Apr 27, 2022 9:51 am

I think the database is OK because I can access the db with HeidiSQL. Apache & MySQL are running fine. It's strange that Joomla cannot connect to the database, if that's what the issue is, simply after upgrading php and not changing anything else.

If I follow your route, would you be kind enough to list the exact steps you followed? I have read so many different versions of exactly how to do it that I'd rather hear from somebody who's done it successfully!

I am very grateful for your help chmst. Much appreciated!

chmst
Joomla! Intern
Joomla! Intern
Posts: 51
Joined: Mon Jan 16, 2012 8:17 am

Re: Can Anybody Decipher These Error Codes?

Post by chmst » Wed Apr 27, 2022 10:27 am

I had a folder D://xampp with php version 7.4.

Closed all open files.

Copied the htdocs folder.
Exported databases.
These steps are only necessary if you have important applications and extensions.

Finished apache and MQsql in xampp.
Close xampp

It depends on your system how you can unistall software, in win11, there is a uninstall xampp app. Run the Uninstall process. Make sure that xampp is deleted completely.

Download the newest xampp for your system and run the installer ( not in C: ).
Then start xampp as usual, apache and mysql.

Now you can install a new joomla in htacces.

And restore your old applications and import databases if you want to restore old applications.
Team lead of Joomla Accessbility Team, active on mattermost and joomla.forum.de

AndyInSpain
Joomla! Apprentice
Joomla! Apprentice
Posts: 47
Joined: Thu Oct 27, 2016 9:06 am

Re: "Failed to start application" error after php upgrade

Post by AndyInSpain » Fri Apr 29, 2022 8:43 am

Thanks so much! I shall give that a try and see what happens.

Much appreciated!


Locked

Return to “General Questions/New to Joomla! 3.x”