RichiG
Posts: 2
Joined: Tue Apr 23, 2013 9:04 pm
Location: Germany

Re: RPI-Update issue

Thu Mar 20, 2014 10:07 pm

"sudo UPDATE_SELF=0 rpi-update" solved the problem for me. The last rpi-update was 5 months ago.

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Thu Mar 20, 2014 10:48 pm

It is possible I have found where the issue lies. I've no idea how to fix it though.

I loaded an SD card with the later rasbian image, 2014-01-07-wheezy-raspbian, and after running through the initialisation with raspi-config rebooted and then ran rpi-update.

This update raspbian from 3.10.25+ #622 to 3.10.33+ #658 , the very latest version of raspbian, without problems. I then rebooted and then ran rpi-update again. No sign of any problem and rpi-update reported it was already up to date.

I then deleted file /boot/.firmware_revision to allow rpi-update to run even though the image was already up to date. Ran rpi-update and it ran OK and loaded the new firmware OK again.

I then ran apt-get update and apt-get upgrade. When apt-get update reported the list of packages it was going to update I terminated the upgrade so no packages were actually loaded. rpi-upgrade reported it was going to install 20 packages which were

Code: Select all

[email protected] ~ $ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages have been kept back:
  wolfram-engine
The following packages will be upgraded:
  curl dpkg dpkg-dev file idle-python2.7 libcurl3 libcurl3-gnutls libdpkg-perl libgnutls26 libmagic1 libpython2.7 libxfont1 libyaml-0-2 lsb-base python2.7 python2.7-minimal python3-pifacedigital-scratch-handler tzdata udisks wget
20 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
Need to get 14.0 MB of archives.
After this operation, 571 kB of additional disk space will be used.
Do you want to continue [Y/n]? n
Abort.
[email protected] ~ $
I then started to install the list of packages individually or in small groups to try and determine if one of them could be causing the problem. After each install I ran rpi-update and there was no problem until I installed the last package. The complete list of packages to install were as listed above. I loaded all the packages in the following order using individual apt-get install commands, 12 in all, until all the packages were installed.

Code: Select all

sudo apt-get install idle-python2.7 libpython2.7 python2.7 python2.7-minimal python3-pifacedigital-scratch-handler
sudo rpi-update
sudo apt-get install tzdata
sudo rpi-update
sudo apt-get install udisks
sudo rpi-update
sudo apt-get install lsb-base
sudo rpi-update
sudo apt-get install libyaml-0-2
sudo rpi-update
sudo apt-get install libxfont1
sudo rpi-update
sudo apt-get install file libmagic1
sudo rpi-update
sudo apt-get install dpkg
sudo rpi-update
sudo apt-get install dpkg-dev libdpkg-perl
sudo rpi-update
sudo apt-get install curl libcurl3 libcurl3-gnutls
sudo rpi-update
sudo apt-get install libgnutls26
sudo rpi-update
sudo apt-get install wget
sudo rpi-update
rpi-update ran OK until I install the new wget package. Then it failed with the following error

Code: Select all

Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 185.31.19.133
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.31.19.133|:443... connected.
GnuTLS: A TLS warning alert has been received.
Unable to establish SSL connection.
 !!! Failed to download update for rpi-update!
 !!! Make sure you have ca-certificates installed and that the time is set correctly
And as others have noted ca-certificates and the time were OK.

So for some reason it looks as though there may be a problem with the latest version of wget. I've no idea how to sort it out if it can be but maybe someone else may be able to help.

Just tried one final test. Loaded a SD card with a new raspbian image and ran rpi-update to bring it up to the latest version 3.10.33+ #658. Ran rpi-update again and there was no problem. I then installed ONLY wget from the list of files that apt-get upgrade showed. Tried rpi-update again and it FAILED. So it does seem the problem has something to do with the new version of wget.

So anyone any idea what the problem could be and how to fix it?


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Thu Mar 20, 2014 10:53 pm

RichiG wrote:"sudo UPDATE_SELF=0 rpi-update" solved the problem for me. The last rpi-update was 5 months ago.
Well done, yes, does help and allows rpi-update to run. Just stops rpi-update itself being downloaded and updated which may be at the centre of the problem.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

User avatar
rpdom
Posts: 15929
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: RPI-Update issue

Fri Mar 21, 2014 6:55 am

This appears to be very similar to a known bug in wget https://bugs.debian.org/cgi-bin/bugrepo ... bug=738625 https://bugs.debian.org/cgi-bin/bugrepo ... bug=686837

I can recreate the error on my Debian laptop.

m.wagner
Posts: 1
Joined: Fri Jul 12, 2013 6:49 am

Re: RPI-Update issue

Fri Mar 21, 2014 9:51 am

As workaround I downloaded the rpi-update script manually and run with UPDATE_SELF=0:

Code: Select all

curl -o https://raw.githubusercontent.com/Hexxeh/rpi-update/master/rpi-update
chmod +x rpi-update
sudo UPDATE_SELF=0 ./rpi-update 

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5380
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: RPI-Update issue

Fri Mar 21, 2014 1:01 pm

I've changed rpi-update to use curl rather than wget.
You need to manually get this version of rpi-update:

Code: Select all

sudo curl -L --output `which rpi-update` https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
Now rpi-update should work again.

Some info here: https://github.com/Hexxeh/rpi-update/issues/65

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Fri Mar 21, 2014 2:24 pm

dom wrote:I've changed rpi-update to use curl rather than wget.
You need to manually get this version of rpi-update:

Code: Select all

sudo curl -L --output `which rpi-update` https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
Now rpi-update should work again.

Some info here: https://github.com/Hexxeh/rpi-update/issues/65
Thanks dom,

Certainly seems to have fixed the problem for me.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

Aigle4
Posts: 1
Joined: Fri Mar 21, 2014 3:34 pm

Re: RPI-Update issue

Fri Mar 21, 2014 3:41 pm

Hi,

Rather than editing a system file, you can use setting and exporting UPDATE_SELF to value zero before executing rpi-udate.

It worked for me.

Enjoy with your Raspberry Pi

Aigle4

lasselu
Posts: 2
Joined: Thu Mar 20, 2014 6:22 pm

Re: RPI-Update issue

Fri Mar 21, 2014 5:39 pm

RichiG wrote:"sudo UPDATE_SELF=0 rpi-update" solved the problem for me. The last rpi-update was 5 months ago.
Thank you! Worked like a charm.

User avatar
mad-hatter
Posts: 419
Joined: Sun Feb 26, 2012 2:58 pm
Location: By the UK seaside

Re: RPI-Update issue

Fri Mar 21, 2014 6:40 pm

Hello,
MrEngman wrote:
dom wrote:I've changed rpi-update to use curl rather than wget.
You need to manually get this version of rpi-update:

Code: Select all

sudo curl -L --output `which rpi-update` https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
Now rpi-update should work again.

Some info here: https://github.com/Hexxeh/rpi-update/issues/65
Thanks dom,

Certainly seems to have fixed the problem for me.


MrEngman
I think it should be :-

Code: Select all

sudo curl -L --output $(which rpi-update) https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
see https://github.com/Hexxeh/rpi-update/issues/65 shrx commented 2 hours ago - for an explanation.

Regards

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Fri Mar 21, 2014 9:26 pm

mad-hatter wrote:Hello,
MrEngman wrote:
dom wrote:I've changed rpi-update to use curl rather than wget.
You need to manually get this version of rpi-update:

Code: Select all

sudo curl -L --output `which rpi-update` https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
Now rpi-update should work again.

Some info here: https://github.com/Hexxeh/rpi-update/issues/65
Thanks dom,

Certainly seems to have fixed the problem for me.


MrEngman
I think it should be :-

Code: Select all

sudo curl -L --output $(which rpi-update) https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
see https://github.com/Hexxeh/rpi-update/issues/65 shrx commented 2 hours ago - for an explanation.

Regards
Hi,

What ever it should be dom's command worked for me and rpi-update runs OK again without problems. Each to his own though ;)

Code: Select all

[email protected] ~ $ sudo curl -L --output `which rpi-update` https://github.com/Hexxeh/rpi-update/raw/master/rpi-update
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   135  100   135    0     0    164      0 --:--:-- --:--:-- --:--:--   240
100  7177  100  7177    0     0   6441      0  0:00:01  0:00:01 --:--:-- 39872
[email protected] ~ $ sudo rpi-update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS
 *** Performing self-update
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   135  100   135    0     0    198      0 --:--:-- --:--:-- --:--:--   273
100  7177  100  7177    0     0   7668      0 --:--:-- --:--:-- --:--:--  7668
 *** Relaunching after update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS
 *** ARM/GPU split is now defined in /boot/config.txt using the gpu_mem option!
 *** Your firmware is already up to date
MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

User avatar
DougieLawson
Posts: 36904
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: RPI-Update issue

Fri Mar 21, 2014 10:18 pm

On my RPis (running Jessie with the very latest gnutls library) I got a warning message, but the wget download of the new (curl) version of rpi-update worked without any struggle.

It won't fail again (now that I have the curl version).
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

User avatar
Un4Seen
Posts: 330
Joined: Wed Oct 31, 2012 8:43 am
Location: Cluj-Napoca, Romania
Contact: Website

Re: RPI-Update issue

Fri Mar 21, 2014 11:48 pm

Well done, MrEngman! Your methodical way of cornering the problem is a great help to us all!

It seems to me that the "proper" fix to the problem (now that we know what causes it) would be to revert wget back to its previously installed version, until it is officially fixed. Is there any way to revert packages installed by apt-get to their previous versions?

Thanks!
Andras
http://iqjar.com

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Sat Mar 22, 2014 12:02 am

Un4Seen wrote:Well done, MrEngman! Your methodical way of cornering the problem is a great help to us all!

It seems to me that the "proper" fix to the problem (now that we know what causes it) would be to revert wget back to its previously installed version, until it is officially fixed. Is there any way to revert packages installed by apt-get to their previous versions?

Thanks!
Well I think I pointed to the problem being with wget but had nothing to do with finding a fix. The change to rpi-update provided by dom is the important point.

As far as wget is concerned I guess it should be fixed but the update to rpi-update provides a working solution which is what counts.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

User avatar
Un4Seen
Posts: 330
Joined: Wed Oct 31, 2012 8:43 am
Location: Cluj-Napoca, Romania
Contact: Website

Re: RPI-Update issue

Sat Mar 22, 2014 12:10 am

MrEngman wrote:Well I think I pointed to the problem being with wget but had nothing to do with finding a fix. The change to rpi-update provided by dom is the important point.
Yes, that's true, and we really are grateful to dom for the solution! Still, I admire the way you found the problem!
Andras
http://iqjar.com

sanrab
Posts: 1
Joined: Sat Mar 22, 2014 7:26 am
Location: Venice, Italy

Re: RPI-Update issue

Sat Mar 22, 2014 7:33 am

Same problem here.
I solved it in this way:

- made a copy of /usr/bin/rpi-update
- commented out the lines
#if [[ ${UPDATE_SELF} -ne 0 ]]; then
# update_self
#fi

Thicko_1970
Posts: 24
Joined: Thu Jan 03, 2013 12:32 am
Location: Hawick

Re: RPI-Update issue

Sat Mar 22, 2014 11:26 am

RichiG wrote:"sudo UPDATE_SELF=0 rpi-update" solved the problem for me. The last rpi-update was 5 months ago.
That does solve workaround the issue. There is a new update, that adds better functionality to the camera module.

mikukkon
Posts: 1
Joined: Sat Mar 22, 2014 12:47 pm

Re: RPI-Update issue

Sat Mar 22, 2014 12:49 pm

Googling showed that simple workaround is to do

Code: Select all

UPDATE_SELF=0 rpi-update
which skips the self update.

--MiKu

MrEngman
Posts: 3921
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: RPI-Update issue

Sat Mar 22, 2014 1:18 pm

rpi-update has been updated to fix the problem. look here http://www.raspberrypi.org/forum/viewto ... 19#p523519

This will allow you to run rpi-update as normal, so no need for "UPDATE_SELF=0"


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

beta-tester
Posts: 1305
Joined: Fri Jan 04, 2013 1:57 pm
Location: de_DE

Re: RPI-Update issue

Sat Mar 22, 2014 3:59 pm

i have thee exact same behavior as MrEngman.
on a clean recent wheezy image, as soon as i make a apt-get update && apt-get upgrade (wget), the rpi-update script and also the PiMAME install & update will fail.
when i do it in the opposite order (fresh image && rpi-update && PiMAME install / update && apt-get update && apt-get upgrade), it works, but i think something with the wget repository is broken.

who is responsible for the wget repository? one month before everything was ok with the old wget package
{ I only give negative feedback }
RPi B (256MB), B (512MB), B+, ZeroW; 2B; 3B, 3B+; 4B (4GB)

broodplank
Posts: 1
Joined: Sat Mar 22, 2014 10:59 pm

Re: RPI-Update issue

Sat Mar 22, 2014 11:30 pm

I was experiencing this problem as well, I tried to fetch the link manually but it also didn't work, so i checked apt-get upgrade and it had ssl updates, so I thought it would be fixed, but no.. still not, so last resort, i uploaded it to my own site and fetched it, kinda lame. then after launching

Code: Select all

wget http://broodplank.net/rpi-update
(this version has a slight addition which is enabling ssh!)

Code: Select all

[email protected]:/usr/bin# rpi-update 
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS
 *** Performing self-update
/usr/bin/rpi-update: line 36: curl: command not found
 !!! Failed to download update for rpi-update!
 !!! Make sure you have ca-certificates installed and that the time is set correctly
it has NOTHING to do with the ca-certificates nor the time, it's the curl command that seem to be missing

Code: Select all

apt-get install curl
no errors since ;)

mdukes
Posts: 1
Joined: Sun Mar 23, 2014 12:28 am

Re: RPI-Update issue

Sun Mar 23, 2014 12:35 am

I was having the same issue, but used this to disable to self-update:

sudo UPDATE_SELF=0 rpi-update

and was able to update the firmware successfully


dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5380
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: RPI-Update issue

Sun Mar 23, 2014 11:43 am

beta-tester wrote:who is responsible for the wget repository? one month before everything was ok with the old wget package
It is not wget that has changed. It is github that has changed.

This is affecting all sorts of things. E.g. xbmc is failing on all linux platforms after this change:
http://forum.xbmc.org/showthread.php?tid=189722

blobule
Posts: 1
Joined: Sun Mar 23, 2014 6:21 pm

Re: RPI-Update issue

Sun Mar 23, 2014 6:26 pm

As mentionned in the previous posts, the self update of rpi-update seems broken.
Just run (as root):
UPDATE_SELF=0 rpi-update

until the self-updating is fixed.

Return to “Troubleshooting”