Page 1 of 2

[Linux Station] Fatal Python error on update

Posted: Sat Jul 23, 2016 12:26 am
by SleepyPrince
I was trying to update my Linux Station Ubuntu today however I am getting
"Fatal Python error: getrandom() failed" when installing packages.

I tried searching on the internet and first thought it was due to Python3.5 and low entropy
So I installed haveged and entropy_avail now reports >3000
However the same error occurred and I am stuck
I tried resetting the Ubuntu but the problem is still there

Re: [Linux Station] Fatal Python error on update

Posted: Sun Jul 24, 2016 8:37 pm
by jeweller_by
Have the same problem. Two packets failed on update - python3.5 and python3.5-minimal.

Re: [Linux Station] Fatal Python error on update

Posted: Mon Jul 25, 2016 12:42 am
by gmo18t
Same here ...
Therefore I reverted to Python 5.2.1-10 to avoid any unpredictable behavior with setup
scripts called during package updates.

- GMo -

Re: [Linux Station] Fatal Python error on update

Posted: Fri Jul 29, 2016 4:41 am
by xjive
im having the same issue to on kylin but it wont let me open terminal or software and updates ive reinstalled kylin 3 time and after I update this happends. i can get xterm open but i get the python errors on updates so no packages get updated. If anyone has a fix it would be greatly appreciated.

Re: [Linux Station] Fatal Python error on update

Posted: Thu Aug 04, 2016 12:22 am
by Burgelaar
Having the same problem here.
I also tried resetting

Update:
Ubuntu 14.04 doesn't have this issue.
(You can choose the version in linux station)

Re: [Linux Station] Fatal Python error on update

Posted: Fri Aug 05, 2016 4:13 pm
by rsotam
I'm having the same problem. I'm using Ubuntu 16.04 LTS. Do you have a solution?

Thanks

Re: [Linux Station] Fatal Python error on update

Posted: Sat Aug 06, 2016 10:28 pm
by thehobbit30
Not sure what happened by I am having the same problem. Don't really want to move to Ubuntu 14!

Re: [Linux Station] Fatal Python error on update

Posted: Mon Aug 08, 2016 6:45 am
by Knappe371
gmo18t wrote:Same here ...
Therefore I reverted to Python 5.2.1-10 to avoid any unpredictable behavior with setup
scripts called during package updates.

- GMo -


Hi GMo,

could you explain how you did that in detail?
Thanks!

Re: [Linux Station] Fatal Python error on update

Posted: Mon Aug 08, 2016 5:39 pm
by gmo18t
Hi,

i searched INet for the following deb packages

Code: Select all

  libpython3.5_3.5.1-10_amd64.deb
  libpython3.5-minimal_3.5.1-10_amd64.deb
  libpython3.5-stdlib_3.5.1-10_amd64.deb
  python3.5_3.5.1-10_amd64.deb
  python3.5-minimal_3.5.1-10_amd64.deb


and after (manually) dowloading I installed it via command:

Code: Select all

sudo dpkg -i *.deb


- GMo -

Re: [Linux Station] Fatal Python error on update

Posted: Mon Aug 08, 2016 9:55 pm
by SleepyPrince
gmo18t, did downloading and installing from other source solve the problem?
i dont want to reset the system again
i am currenly using apt-mark to hold off the update

edit: I think I get what you mean now
download the older version and install them manually to overwrite the one with problem
which is the same version as I got now with 3.5.2-16.01 held off

Re: [Linux Station] Fatal Python error on update

Posted: Tue Aug 09, 2016 4:04 am
by gmo18t
Yes right, i did overswrite the problematic version with the older 3.5.1-10.
Afterwards i also marked these packages as “HOLD“.

- GMo -

Re: [Linux Station] Fatal Python error on update

Posted: Tue Aug 09, 2016 5:28 am
by Knappe371
That worked just fine. Thank you GMo!

Re: [Linux Station] Fatal Python error on update

Posted: Sat Aug 27, 2016 11:41 pm
by JackieBrown
Is there a different long term solution for this?

Re: [Linux Station] Fatal Python error on update

Posted: Tue Sep 06, 2016 3:01 pm
by iwings
I've created an issue on python bug tracker.
https://bugs.python.org/issue27955

In the meantime, you can replace broken python 3.5.2 binary with the patched one.
Do this at your own risk!!

Code: Select all

$ sudo -i
root@ubuntu_1604:~# apt update && apt upgrade
...
Errors were encountered while processing:
 /var/cache/apt/archives/language-selector-gnome_0.165.4_all.deb
 /var/cache/apt/archives/language-selector-common_0.165.4_all.deb
 /var/cache/apt/archives/python3-uno_1%3a5.1.4-0ubuntu1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

root@ubuntu_1604:~# mkdir deb && cd deb
root@ubuntu_1604:~/deb# wget "https://www.dropbox.com/s/rvrea63oue4brum/python3.5-minimal_3.5.2-2~16.01ubuntu1_amd64.deb"
root@ubuntu_1604:~/deb# ar vx python3.5-minimal_3.5.2-2~16.01ubuntu1_amd64.deb
root@ubuntu_1604:~/deb# tar xvfJ data.tar.xz
root@ubuntu_1604:~/deb# cp -p usr/bin/python3.5 /usr/bin
root@ubuntu_1604:~/deb# cp -p usr/bin/python3.5m /usr/bin
root@ubuntu_1604:~/deb# apt upgrade -f

If you want to build the package directly, use this patch file.
https://www.dropbox.com/s/3cexzqf2yj0ov0p/random.diff

Re: [Linux Station] Fatal Python error on update

Posted: Fri Sep 09, 2016 9:59 pm
by SleepyPrince
iwings, thanks for the patch.
It works for me, hope they will put out an update soon.