Bug 10745 - SC does not offer SBC Firmware upgrade
: SC does not offer SBC Firmware upgrade
Status: CLOSED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Controller
: 7.4.0
: PC Windows Vista
: P1 major (vote)
: 7.4.0
Assigned To: James Richardson
:
Depends on:
Blocks: 10949
  Show dependency treegraph
 
Reported: 2009-01-18 07:17 UTC by James Richardson
Modified: 2009-10-05 14:35 UTC (History)
5 users (show)

See Also:
Category: ---


Attachments
server log (2.71 KB, application/octet-stream)
2009-01-18 07:17 UTC, James Richardson
Details
Server Log (214.53 KB, application/octet-stream)
2009-02-25 13:57 UTC, James Richardson
Details
7.4 r25188 log (822.25 KB, application/octet-stream)
2009-02-26 08:24 UTC, James Richardson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description James Richardson 2009-01-18 07:17:00 UTC
SC 7.4 no longer offers to upgrade Controller firmware.  

Controller has r3476
SC > Cache has r3822

DEBUG log shows NO jive activity.  I.E. no logging data (see attached)
Comment 1 James Richardson 2009-01-18 07:17:25 UTC
Created attachment 4667 [details]
server log
Comment 2 James Richardson 2009-01-18 07:20:12 UTC
Restarting SC I see the following in the log:
----------
[09-01-18 07:18:13.8055] main::init (270) Starting SqueezeCenter (v7.4, r24698, Sat Jan 17 01:15:11 PST 2009)
[09-01-18 07:18:19.9045] Slim::Player::Squeezebox::needsUpgrade (276) Reading firmware version file: C:\PROGRA~1\SQUEEZ~1\server\Firmware\squeezebox2.version
[09-01-18 07:18:19.9052] Slim::Player::Squeezebox::needsUpgrade (333) squeezebox2 firmware is up-to-date, v. 123
[09-01-18 07:18:20.6264] Slim::Utils::Firmware::init_firmware_download (180) Downloading jive.version file...
[09-01-18 07:18:20.6275] Slim::Utils::Firmware::downloadAsync (463) Downloading in the background: http://update.squeezenetwork.com/update/firmware/7.4/jive.version
[09-01-18 07:18:24.3859] Slim::Utils::Firmware::downloadAsyncSHADone (530) Successfully downloaded and verified C:\ProgramData\SqueezeCenter\Cache\jive.version.
[09-01-18 07:18:24.3867] Slim::Utils::Firmware::init_version_done (220) jive firmware is up to date: C:\ProgramData\SqueezeCenter\Cache\jive_7.4_r3822.bin
[09-01-18 07:18:24.3872] Slim::Utils::Firmware::init_version_done (231) Scheduling next jive.version check in 12 hours
-------------

Checking the SBC, I still see r3476  NOT r3822
Checking SC>Cache, I see r3822
Comment 3 Mark Miksis 2009-01-18 13:04:58 UTC
I've seen many cases where there is new firmware in SC's cachedir, but the SBC will not recognize it without a reboot.
Comment 4 Chris Owens 2009-01-19 09:36:34 UTC
Andy notes this is due to the firmware changes Michael made in order to allow different bin files for future products.

Andy notes the right behavior is to send the update notice to the device as soon as the appropriate download is complete.

Consensus is that it would be cool to work out how to begin transferring the file before the download to the PC is complete, or send it directly from SN.

What do you think, Dean?  Wait until it's cached on the local server, or get directly from SN over a possibly-slow connxn?
Comment 5 Blackketter Dean 2009-01-19 10:32:57 UTC
Let's fix the immediate issue, then open an enhancement on direct/streaming downloads.
Comment 6 Chris Owens 2009-01-20 17:17:59 UTC
Andy, since the changes were Michael's, should this bug be reassigned back to him?

I split the enhancement request to bug 10789.
Comment 7 James Richardson 2009-01-21 10:00:31 UTC
*** Bug 10722 has been marked as a duplicate of this bug. ***
Comment 8 Blackketter Dean 2009-02-02 16:57:54 UTC
This is preventing our community from testing.  

Comment 9 Michael Herger 2009-02-03 01:59:04 UTC
Ben - is this a Jive side issue? IMHO the code on the server side is still there, but not called. Is Jive polling for the update status (using the firmwareupgrade query defined in S::C::Jive), or is listening for such an event (thrown in S::U::Firmware: Slim::Control::Request->new(undef, ['fwdownloaded', $model])->notify('firmwareupgrade');)?
Comment 10 Michael Herger 2009-02-03 02:07:17 UTC
Adrian - I just realised you changed that part of the code to signal the availability of the new firmware. Do you have an idea why it isn't working any more?
Comment 11 Adrian Smith 2009-02-03 09:55:53 UTC
Michael - I believed this was working - it was straight after I made the changem which was to send a status update if the firmware when the download completes to avoid jive needing to reconnect to ask for status.

If the firmware is downloaded and jive reconnects is it getting the right info, or is it never getting to the player?
Comment 12 Mark Miksis 2009-02-14 08:01:24 UTC
I can't reproduce this.  A new 7.4 jive was pushed to the update directory last night.  My 7.4 SC properly detected it and downloaded it to the cachedir.  My SBC then prompted me about the available update as expected and the update proceeded without incident.

Triode, I still have player.firmware logs if you want to see them, but there's nothing interesting in there other than what you'd see when it works as expected.
Comment 13 Michael Herger 2009-02-14 08:56:04 UTC
Updated my server to Version: 7.4 - 24985 @ Fri Feb 13 01:00:48 PST 2009 last night. This morning my Controller asked me to install firmware jive_7.4_r4154. 

IMHO this is working as advertised. Back to QA to reproduce?
Comment 14 Blackketter Dean 2009-02-14 09:06:58 UTC
I noticed the same thing yesterday.  I'd like to see another offer before we close this.  And yes, let's let QA prove that it's fixed.
Comment 15 James Richardson 2009-02-18 09:53:55 UTC
QA to verify latest 7.3.3 & 7.4 function properly.
Comment 16 James Richardson 2009-02-24 15:36:47 UTC
QA Verified 7.3.3 r25138 & 7.4.0 r25140 properly upgrade JIVE firmware
Comment 17 James Richardson 2009-02-24 15:50:13 UTC
I spoke too soon...while SC downloads the firmware, it never serves it to the JIVE.

I still see the same errors in the log file
Comment 18 James Richardson 2009-02-24 15:53:05 UTC
My Controller has 7.3 r3993 and my Cache Dir has 7.4 r4154.  YET, the server never attempt to update the controller.

I am able to manually update, via settings > advanced > software update
Comment 19 Adrian Smith 2009-02-25 11:05:25 UTC
The server will only send one notify to controller that it has a new update, this occurs as soon as the download completes.  Could it be that the controller was off at this time?  If so can we check that waking it up will cause it to reconnect and recheck status - it may not be doing this at present?
Comment 20 James Richardson 2009-02-25 11:07:13 UTC
Controller was on and in the cradle

Rebooting the controller does not prompt for update (it does on 7.3.3)

Rebooting the Server does not prompt for update (it does on 7.3.3)
Comment 21 Blackketter Dean 2009-02-25 11:43:33 UTC
Wow, is that right?  We only notify the controller if it happens to be connected when the download completes?
Comment 22 Adrian Smith 2009-02-25 12:38:37 UTC
we only 'notify' the client when there is a new version (which is when the download completes).  In all other cases the jive client should be reconnecting and hence should ask whether there is a new update.

It would be good to get some clear steps here of what state the server is in (debug player.firmware) but I suspect the issue is on the jive end.

Assuming you can reproduce at will James, what is the debug saying?
Comment 23 James Richardson 2009-02-25 13:14:33 UTC
See Comment #2, the only thing that has changed is the 'jive version' it now reads 7.4 r4154
Comment 24 Adrian Smith 2009-02-25 13:33:12 UTC
could you turn on comet debugging too - assuming this is reproducable, is there a message from SC to jive which occurs straight after Slim::Utils::Firmware::init_version_done
Comment 25 James Richardson 2009-02-25 13:55:46 UTC
100% repoducable

See attached log with the following set to DEBUG:
 Player.Firmware
 Player.Jive
 network.cometd

Duet attached to SC 7.3.2 with r3993 & r58
Boot server to verify Jive/Ray are functioning
Place SBC in the Cradle
Download and Install 7.4 nightly
Watch Ray, notice it will do the Firmware Update
Watch Jive, notice it will display 'Updating player firmware'
After the firmware update on Ray is done, Jive will return to the home menu (or what ever menu it was on when the Server was updated
Verify Jive firmware version is still 7.3 r3993

Reboot the Jive and notice it does NOT get prompted for firmware update
Verify Jive firmware version is still 7.3 r3993

Reboot the Server and notice that Jive does not get prompted for firmware update
Verify Jive firmware version is still 7.3 r3993

Repeat the same experiment going from SC 7.2.1 r2448 OR 7.3.2 r3476 => 7.3.3 r3993 and you will see that after the Ray is updated, the Jive is prompting for update

** Doing a 'manual' software update on the Jive will update it to 7.4 r4xxx as expected
Comment 26 James Richardson 2009-02-25 13:57:00 UTC
Created attachment 4863 [details]
Server Log
Comment 27 Adrian Smith 2009-02-25 14:26:42 UTC
This bit looks wrong:

[09-02-25 13:44:17.4682] Slim::Utils::Firmware::downloadAsyncSHADone (538) Successfully downloaded and verified /Users/James/Library/Caches/SqueezeCenter/jive_7.4_r4154.bin.
[09-02-25 13:44:17.4687] Slim::Utils::Firmware::init_fw_done (265) Removing old jive firmware file: jive_7.3_r3993.bin
[09-02-25 13:44:17.4717] Slim::Web::Cometd::requestCallback (837) requestCallback got results for /910060c5/slim/firmwarestatus/00:04:20:16:01:fb / 37
[09-02-25 13:44:17.4720] Slim::Web::Cometd::Manager::deliver_events (215) Sending event on channel /910060c5/slim/firmwarestatus/00:04:20:16:01:fb to 910060c5
[09-02-25 13:44:17.4727] Slim::Web::Cometd::Manager::deliver_events (229) Delivering events to 910060c5:
[
  {
    channel => "/910060c5/slim/firmwarestatus/00:04:20:16:01:fb",
    data => {
          firmwareUpgrade     => 0,
          relativeFirmwareUrl => "/firmware/jive_7.4_r4154.bin",
        },
    ext => { priority => "" },
    id => 37,
  },
]

Straight after the download we should be sending back firmwareUpgrade => 1

I've added some more debug in 7.4 svn r 25174 - could you try again and see what it says around that point.  [takes a long time to download to here..]
Comment 28 James Richardson 2009-02-26 08:24:24 UTC
Created attachment 4864 [details]
7.4 r25188 log

Ran the test again;
 removed all traces of SC
 installed 7.3.2
 verified Jive/Ray at the proper firmware
 verified logging
 downloaded 7.4 r25188
 installed 7.4
 Ray updated
 Jive failed to update

Log attached
Comment 29 Adrian Smith 2009-02-26 12:59:01 UTC
James can you try svn r25193.  

This looks specific to your test case which is upgrading from an old jive firmware?  The additional debug shows this does not send the machine type:

[09-02-26 08:20:44.5143] Slim::Web::Cometd::handler (143) Cometd request: [
  {
    channel => "/slim/subscribe",
    data => {
          request  => [
                        "00:04:20:16:01:fb",
                        ["firmwareupgrade", "firmwareVersion:7.3 r3993", "subscribe:0"],
                      ],
          response => "/66697aac/slim/firmwarestatus/00:04:20:16:01:fb",
        },
    id => 61,
  },
]
[09-02-26 08:20:44.5148] Slim::Utils::Firmware::need_upgrade (359) no firmware for  - can't upgrade

Which means it can't be tested to see if an upgrade is required.  The server should now default to 'jive' for these cases.  Can you try as you have a test case which I have not been able to recreate.
Comment 30 James Richardson 2009-02-27 08:44:59 UTC
Tested 7.4 r25193 today, and the Jive is prompting for a firmware upgrade from7.3 r3993 to 7.4r4154. log to follow
Comment 31 Adrian Smith 2009-02-27 12:24:44 UTC
Great - so this case is fixed?  Can you find any other cases when jive does not prompt for an upgrade?
Comment 32 James Richardson 2009-02-27 12:37:54 UTC
I will continue to test and let you know.
Comment 33 James Richardson 2009-03-27 09:45:39 UTC
Has been working for several 7.4 releases now, so marking as fixed.
Comment 34 James Richardson 2009-10-05 14:35:20 UTC
This bug has been marked as fixed in the 7.4.0 release version of SqueezeBox Server!
    * SqueezeCenter: 28672
    * Squeezebox 2 and 3: 130
    * Transporter: 80
    * Receiver: 65
    * Boom: 50
    * Controller: 7790
    * Radio: 7790  

Please see the Release Notes for all the details: http://wiki.slimdevices.com/index.php/Release_Notes

If you haven't already, please download and install the new version from http://www.logitechsqueezebox.com/support/download-squeezebox-server.html

If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.