factory_transition sd.img
$ cd factory_transition
$ ls
firmware hwid.py requirements.txt restore2factory.py ssh.py system upgrade2bos.py
Already using interpreter /usr/bin/python3
Using base prefix '/usr'
New python executable in /home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/bin/python3
Also creating executable in /home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/bin/python
Installing setuptools, pip, wheel...done.
$ source .env/bin/activate
$ pip install -r ./requirements.txt
Collecting progress==1.2 (from -r ./requirements.txt (line 1))
Downloading https://files.pythonhosted.org/packages/74/54/bb538ae57f32fca8bf65c837d3f1715f7c17ae7734d87f4a9a56dab6e982/progress-1.2.tar.gz
Collecting Paramiko==2.0 (from -r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/72/38/8bb071506c91db110b579c797b65a399fd08e3fbc80af89cc144ecbcbac7/paramiko-2.0.0-py2.py3-none-any.whl (170kB)
100% |████████████████████████████████| 174kB 2.2MB/s
Collecting pyasn1>=0.1.7 (from Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/d1/a1/7790cc85db38daa874f6a2e6308131b9953feb1367f2ae2d1123bb93a9f5/pyasn1-0.4.4-py2.py3-none-any.whl (72kB)
100% |████████████████████████████████| 81kB 15.2MB/s
Collecting cryptography>=1.1 (from Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/59/32/92cade62c645756a83598edf56289e9b19aae5370642a7ce690cd06bc72f/cryptography-2.3.1-cp34-abi3-manylinux1_x86_64.whl (2.1MB)
100% |████████████████████████████████| 2.1MB 7.4MB/s
Collecting asn1crypto>=0.21.0 (from cryptography>=1.1->Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/ea/cd/35485615f45f30a510576f1a56d1e0a7ad7bd8ab5ed7cdc600ef7cd06222/asn1crypto-0.24.0-py2.py3-none-any.whl (101kB)
100% |████████████████████████████████| 102kB 11.8MB/s
Collecting cffi!=1.11.3,>=1.7 (from cryptography>=1.1->Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/59/cc/0e1635b4951021ef35f5c92b32c865ae605fac2a19d724fb6ff99d745c81/cffi-1.11.5-cp35-cp35m-manylinux1_x86_64.whl (420kB)
100% |████████████████████████████████| 430kB 2.8MB/s
Collecting six>=1.4.1 (from cryptography>=1.1->Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Collecting idna>=2.1 (from cryptography>=1.1->Paramiko==2.0->-r ./requirements.txt (line 2))
Using cached https://files.pythonhosted.org/packages/4b/2a/0276479a4b3caeb8a8c1af2f8e4355746a97fab05a372e4a2c6a6b876165/idna-2.7-py2.py3-none-any.whl
Collecting pycparser (from cffi!=1.11.3,>=1.7->cryptography>=1.1->Paramiko==2.0->-r ./requirements.txt (line 2))
Downloading https://files.pythonhosted.org/packages/68/9e/49196946aee219aead1290e00d1e7fdeab8567783e83e1b9ab5585e6206a/pycparser-2.19.tar.gz (158kB)
100% |████████████████████████████████| 163kB 12.3MB/s
Building wheels for collected packages: progress, pycparser
Running setup.py bdist_wheel for progress ... done
Stored in directory: /home/user/.cache/pip/wheels/69/dd/ac/3959c9b8978e9f4e4ae73d33f42981438e43987314e845de51
Running setup.py bdist_wheel for pycparser ... done
Stored in directory: /home/user/.cache/pip/wheels/f2/9a/90/de94f8556265ddc9d9c8b271b0f63e57b26fb1d67a45564511
Successfully built progress pycparser
Installing collected packages: progress, pyasn1, asn1crypto, pycparser, cffi, six, idna, cryptography, Paramiko
Successfully installed Paramiko-2.0.0 asn1crypto-0.24.0 cffi-1.11.5 cryptography-2.3.1 idna-2.7 progress-1.2 pyasn1-0.4.4 pycparser-2.19 six-1.11.0
error is here!!!
Connecting to remote host...
/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/rsakey.py:119: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
algorithm=hashes.SHA1(),
Password:
Preparing remote system...
Copy ld-musl-armhf.so.1 to /lib/ld-musl-armhf.so.1
Traceback (most recent call last):
File "upgrade2bos.py", line 182, in
main(args)
File "upgrade2bos.py", line 138, in main
prepare_system(ssh)
File "upgrade2bos.py", line 86, in prepare_system
ssh.put(os.path.join(SYSTEM_DIR, file_name), remote_file_name)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/ssh.py", line 218, in put
shutil.copyfileobj(local, remote)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/shutil.py", line 76, in copyfileobj
fdst.write(buf)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/file.py", line 381, in write
self._write_all(data)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/file.py", line 498, in _write_all
count = self._write(data)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/channel.py", line 1237, in _write
self.channel.sendall(data)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/channel.py", line 761, in sendall
sent = self.send(s)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/channel.py", line 715, in send
return self._send(s, m)
File "/home/user/braiins/braiins-os-firmware_zynq-am1-s9_2018-09-22-1-8d9b127d/factory_transition/.env/lib/python3.5/site-packages/paramiko/channel.py", line 1075, in _send
raise socket.error('Socket is closed')
OSError: Socket is closed
OSError: Socket is closed