Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Need help upgrading your Joomla! website or converting to Joomla! 3.x?

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 10:26 am

am just running the Joomla_3.4.8-Stable-Full_Package.zip package in between i got this error,

now how do i disable the plugin and where ?

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 10:31 am

I disabled the plugin and its working now

Thanks guys for helping me to upgrade 3.4.8 joomla

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 10:51 am

I have disabled the plugin and its upgraded to 3.4.8 version...but my menubar is only not working on top and the links are not working.

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Wed Nov 23, 2016 11:10 am

Sounds like a caching issue, suggest to cancel ALL caching!
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 11:31 am

Cleared cache but still not working

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Wed Nov 23, 2016 11:41 am

Log in with a different Browser ?
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".

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Wed Nov 23, 2016 11:47 am

blessythabitha wrote:Cleared cache but still not working
Too abstract! Inform us HOW you did it instead of WHAT you did!

When you experience problems you NEED to provide details, at least when you want other to help you!
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 12:03 pm

System->clear cache->select all and delete is how i did

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Wed Nov 23, 2016 12:22 pm

That is the server part, you need to clear the browser as well.

And that is not all, there can be many aspects to chaching in your infrastructure. You need to be aware of those aspects and invalidate the appropriate caches.

Aspects: code compression, cdn, proxy, Joomla configuration, browser
Last edited by sovainfo on Wed Nov 23, 2016 12:31 pm, edited 1 time in total.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Wed Nov 23, 2016 12:27 pm

I have done both still my menu bar css is changed and my banners are absconding

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Wed Nov 23, 2016 2:33 pm

blessythabitha wrote:I have done both ...
Many think they have cleared Browser cache when they haven't. Please try a different Browser.
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".

User avatar
sozzled
Joomla! Master
Joomla! Master
Posts: 12634
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sozzled » Wed Nov 23, 2016 4:28 pm

I have been following this topic for over a week. I'm amazed that it's taken this long to get to this level of understanding and, in that regard, it's been a source some entertainment for me. However, I believe the subject "Joomla upgrade 2.5.28 to 3.5.1, getting error 'Download of update package failed'" is no longer appropriate.

The original problem, the inability to migrate from J! 2.5 to J! 3.x, has been solved, I think (I'm not sure, the story changes every day). So, perhaps it would be better to create a new topic at this stage that deals with the post-migration/further upgrade issues and continue the adventure as a new episode in this entertaining saga (will it ever end?). Thanks.

@blessythabitha: clear your caches (plural).
“If you think I’m wrong then say, ‘I think you’re wrong.’ If you say ‘You’re wrong!’, how do you know?”
Walking the talk: https://j4xdemo.enduring.com.au
:)

User avatar
leolam
Joomla! Master
Joomla! Master
Posts: 20518
Joined: Mon Aug 29, 2005 10:17 am
Location: Netherlands/ Germany/ S'pore/Bogor/ North America
Contact:

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by leolam » Wed Nov 23, 2016 5:17 pm

@sozzled why you think I am just enjoying reading this entertainment?

Leo 8)
Joomla's #1 Professional Services Provider:
#Joomla Professional Support: https://gws-desk.com -
#Joomla Specialized Hosting Solutions: https://gws-host.com -

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Wed Nov 23, 2016 7:52 pm

The bug was only introduced 23 days ago, with the introduction of the official download site.
Do recall someone mentioning those additions to the url. Can't find where that was.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Thu Nov 24, 2016 1:32 am

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".

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Thu Nov 24, 2016 9:40 am

No, it was the thread mbabker pointed at on github that I read, but thanks for pointing me to the conversation.

Like the idea of using .htaccess to remove the url parameters, thinking of changing it to the correct .zip extension as well. That should serve old version updates.

Still leaves the bug in Joomla! Update to be resolved, though. Used a preg_replace to get rid of everything behind the ?. Missed the part of the extension .zip missing. Which explains the downloading suddenly working. So, correcting the extension should recognize the downloaded update again.

Any htaccess guru around?
It would need to replace "-zip?......" with ".zip"
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Thu Nov 24, 2016 10:48 am

sovainfo wrote:...
Any htaccess guru around?
It would need to replace "-zip?......" with ".zip"
Now I am confused because I thought the problem only affected Windows servers and they don't use .htaccess do they ?
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".

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Thu Nov 24, 2016 11:02 am

The issue is related to NTFS, Apache on Windows uses .htaccess. IIS doesn't.

While trying to explain realized the .htaccess can't work. It needs a change in Joomla! Update component. The url used to be a valid file name. Not any more, so it needs to be manipulated into a valid .zip to recognize the downloaded update.

.htaccess manipulates incoming requests to the webserver. There is no issue with incoming requests, the issue is with using an url as filename!

EDIT:
Just replace line 201 of administrator/components/com_joomlaupdate/models/default.php (j2528) with:

Code: Select all

$basename = basename(preg_replace('/-zip\?format=zip&jcompat=my/', '', $packageURL));
Unless the url changes again, it produces the correct filename!
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Thu Nov 24, 2016 5:14 pm

Line #254 in J3.6.4. Just tested and has downloaded and extracted. Will you create a PR please ?
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".

deleted user

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by deleted user » Thu Nov 24, 2016 5:22 pm

@Webdongle - It has nothing to do with what engine the site downloading the update is running, the changes I'm saying are needed are on downloads.joomla.org itself.

@sovainfo - While that might work, I wouldn't ever code right into Joomla a specific URL expectation, it just causes issues if we do ever change it again (this is the third domain we've used since serving updates in this manner; joomlacode.org, github.com, and now downloads.joomla.org).

Also for this part - "the issue is with using an url as filename" - Until we started using the downloads site, the last URL segment was the file name, so it was a valid assumption to work from.

- http://joomlacode.org/gf/download/frsre ... ackage.zip
- https://github.com/joomla/joomla-cms/re ... ackage.zip
- https://downloads.joomla.org/cms/joomla ... ackage-zip (purposefully excluded the query string as it's not a requirement to get the package)

Akeeba Release System doesn't use the file name in its URL routing though, it uses a URL friendly alias of the filename, and altering that behavior would be rather "interesting" to say the least. If we used URL suffixes on the site, we would have no issues, but we don't so now it requires a server level workaround on our architecture.

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Thu Nov 24, 2016 10:15 pm

Already was aware of the fact that the url was used as filename. So, don't understand why you are pointing that out to me. The fact that the changed url causes Joomla! Update to wrongly determine the filename and start downloading it, thereby not recognizing it is already available, which happens on any platform, not only on Windows, seems something you refuse to accept! Obviously, on Windows it fails to store it due to invalid filename. Expect it to update without further issue on different platforms, unless you received reports otherwise.

Hereby confirm that the already applied solution you pointed out, https://github.com/joomla/joomla-cms/pull/12817, also works on J2.5.28. Yes, it skips downloading and applies the update. Unfortunately, the updates of Joomla are not so robust and I forgot to restore to the clean J2.5.28 environment. That is why I currently are running into a failed update due to multiple rows in update sites for Joomla Update component. Trust that others don't run into that sitution, expecting them to do the appropriate thing and restore from backup when updating fails! So, that makes 3 workarounds.

So, the issue for not recognizing the available patch in the Joomla designated temp folder is not only for Windows, it applies to all platforms. AFAIK, only on Windows the update fails, the workaround for that is fixing the code manually (whichever of the 3 options) or wait for your solution on the server side.

Maybe there are others around prepared to provide a patch for Joomla! Update, considering the PLT is not prepared to do it. Even if you don't find a server side solution, consider the available workarounds good enough. Do consider a patch release for joomla! Update desirable to allow people on Windows to update. Despite that replacing one line allows them to do it now!
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

deleted user

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by deleted user » Fri Nov 25, 2016 12:01 am

sovainfo wrote:The fact that the changed url causes Joomla! Update to wrongly determine the filename and start downloading it, thereby not recognizing it is already available, which happens on any platform, not only on Windows, seems something you refuse to accept!
I never commented on the upload to tmp directory portion of the process, only the download issues. Obviously Joomla_3.6.4-Stable-Update_Package.zip !== joomla_3-6-4-stable-update_package-zip?format=zip&jcompat=my.zip so that name matching isn't going to work; without hacking Akeeba Release System to change its router from using the item alias it generates from the filename to the actual filename, that process is going to be busted. If I can fix it server side so the last URL segment can be joomla_3-6-4-stable-update_package.zip and make use of Apache rewrites/redirects to map it directly, as long as the checks aren't case sensitive, we should be OK.
sovainfo wrote:So, the issue for not recognizing the available patch in the Joomla designated temp folder is not only for Windows, it applies to all platforms. AFAIK, only on Windows the update fails, the workaround for that is fixing the code manually (whichever of the 3 options) or wait for your solution on the server side.
The ONLY option is to fix it server side. It's the only way we're going to fix updates on Windows platforms in general for older versions, not even taking into consideration the upload to tmp to bypass having to download the package process yet.
sovainfo wrote:Maybe there are others around prepared to provide a patch for Joomla! Update, considering the PLT is not prepared to do it. Even if you don't find a server side solution, consider the available workarounds good enough. Do consider a patch release for joomla! Update desirable to allow people on Windows to update. Despite that replacing one line allows them to do it now!
I tried. I really did. If I were still Release Lead I would've pushed it already; fact is I'm not involved in the release process anymore outside of my duties on the security team so if those who are on that process don't want to do the required work all I can do is try to find alternative solutions.

deleted user

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by deleted user » Fri Nov 25, 2016 12:26 am

Same thing I posted to the mailing list:

I'm not fond of it, but I've hacked the Akeeba Release System router to allow it to route by the real filename as well as the item alias. So https://downloads.joomla.org/cms/joomla ... ackage.zip should now work the same as https://downloads.joomla.org/cms/joomla ... pat=my.zip (what we have plugged into the update server now) or https://downloads.joomla.org/cms/joomla ... format=zip (what the router generates from within the site natively). So the filename route option will never actually be advertised either through the generated links, but it'll work.

https://github.com/joomla/update.joomla.org/pull/30 is the pull request to fix up the update server's XML files to use this option. It should fix everything up correctly.

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Fri Nov 25, 2016 9:38 am

how do i create a new topic in forum ?

can you help ?

sorry to interupt

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Fri Nov 25, 2016 11:38 am

@blessythabitha Each board has a button "New Topic" to create a new topic. Assuming you are allowed to post there, which means you need to log in.

@webdongle Sorry, missed your request for a PR. Agree with mbabker the workarounds I provided are not the correct solution for this issue. They are provided so people can update NOW. Both the workarounds and the current implementation are inferior solutions. As mbabker mentioned in the CMS group https://github.com/joomla/joomla-cms/pull/12817/files already provides a solution that removes the depency of the filename of the patch on the url.
Unfortunately, only available in about 6 months (J3.7). For some reason it is not considered a bug fix!
No idea, when the server side part will be implemented. Till then people can use the workarounds.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

blessythabitha
Joomla! Apprentice
Joomla! Apprentice
Posts: 41
Joined: Thu Nov 17, 2016 10:05 am

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by blessythabitha » Fri Nov 25, 2016 12:24 pm

@sovainfo i have logged in but i dont find any button for "New Topic". Iam searching for long time.

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by sovainfo » Fri Nov 25, 2016 5:20 pm

At the top of the board, where you now see an orange button with Post Reply, you should see that button. You should not be reading a topic, it shows on the index page of that board.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

User avatar
toivo
Joomla! Master
Joomla! Master
Posts: 14945
Joined: Thu Feb 15, 2007 5:48 am
Location: Sydney, Australia

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by toivo » Sun Nov 27, 2016 12:47 pm

sovainfo wrote:Unfortunately, only available in about 6 months (J3.7). For some reason it is not considered a bug fix!
I recommend that the fix is expedited, thinking of those who are late in upgrading to 3.6.4 from much earlier versions.

Here is sovainfo's mod (thanks!), applied to 3.5.1, line 249 of administrator/components/com_joomlaupdate/models/default.php:

Code: Select all

		// 20161124 mod by sovainfo to fix issue https://forum.joomla.org/viewtopic.php?f=710&t=940061&start=30#p3445512
		// $basename = basename($packageURL);
		$basename = basename(preg_replace('/-zip\?format=zip&jcompat=my/', '', $packageURL));
		// 20161124 end
The code works perfectly when updating 3.5.1 to 3.6.4 but gets overwritten by the 3.6.4 version of the file. This means that after selecting 'Reinstall Joomla core files' we get the error:

Code: Select all

The archive file is corrupt, truncated or archive parts are missing
Joomla! Update has now the option 'Upload & Update' which allows us at least to update to the next version, but seeing the error will confuse users.

I strongly believe that the bug fix is justified for 3.6, so that we do not have to tell users for months that they have to resort to manual updates or patch com_joomlaupdate - and then patch it again.
Toivo Talikka, Global Moderator

deleted user

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by deleted user » Sun Nov 27, 2016 9:58 pm

Feel free to petition it to PLT. I tried. They said they didn't feel it was urgent to at least release a standalone update for the update component which is in part why I had to resort to a server side fix (which the release team has yet to deploy either).

Long and short, the issue is fixed in two ways. None of them are going anywhere right now and I'm done doing everything myself.

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

Re: Joomla upgrade 2.5.28 to 3.5.1, getting error Download of update package failed

Post by Webdongle » Mon Nov 28, 2016 12:05 am

@mbabker
Your efforts are tremendous and your ability to explain things in 'Laymans' terms has helped keep me sane. Your script (yes I know you are keen to point out it's not official or guaranteed) has proven to be useful to many. Let's hope the pen pushers make a proper decision soon.
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".


Locked

Return to “Migrating and Upgrading to Joomla! 3.x”