cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Voyager
Voyager
335 Views
Registered: ‎05-11-2015

git or gnutls related issue and petalinux

I have used petalinux on virtual machines many times. Now I observed on a fresh install of Vitis + petalinux 2020.2 on Ubuntu 18.04.4 that petalinux fails to build:

WARNING: fsbl-2020.2+gitAUTOINC+08b9f4304d-r0 do_fetch: Failed to fetch URL git://github.com/Xilinx/embeddedsw.git;protocol=https;branch=master-rel-2020.2, attempting MIRRORS if available
ERROR: fsbl-2020.2+gitAUTOINC+08b9f4304d-r0 do_fetch: Fetcher failure: Fetch command export PSEUDO_DISABLED=1; unset _PYTHON_SYSCONFIGDATA_NAME; export DBUS_SESSION_BUS_ADDRESS="unix:path=/run/user/1000/bus"; export SSH_AGENT_PID="1216"; export SSH_AUTH_SOCK="/run/user/1000/keyring/ssh"; export GIT_SSL_CAINFO="/tools/Xilinx/petalinux/2020.2/components/yocto/buildtools/sysroots/x86_64-petalinux-linux/etc/ssl/certs/ca-certificates.crt"; export PATH="/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/sysroots-uninative/x86_64-linux/usr/bin:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/usr/bin/python3-native:/home/joan/ProjectsPetalinux/dh_slt_1/components/yocto/layers/core/scripts:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/usr/bin/aarch64-xilinx-linux:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot/usr/bin/crossscripts:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/usr/sbin:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/usr/bin:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/sbin:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/work/zynqmp_generic-xilinx-linux/fsbl/2020.2+gitAUTOINC+08b9f4304d-r0/recipe-sysroot-native/bin:/tools/Xilinx/petalinux/2020.2/tools/xsct//bin:/tools/Xilinx/petalinux/2020.2/tools/xsct//gnu/microblaze/lin/bin:/tools/Xilinx/petalinux/2020.2/tools/xsct//gnu/aarch32/lin/gcc-arm-none-eabi/bin:/tools/Xilinx/petalinux/2020.2/tools/xsct//gnu/armr5/lin/gcc-arm-none-eabi/bin:/tools/Xilinx/petalinux/2020.2/tools/xsct//gnu/aarch64/lin/aarch64-none/bin:/home/joan/ProjectsPetalinux/dh_slt_1/components/yocto/layers/core/bitbake/bin:/home/joan/ProjectsPetalinux/dh_slt_1/build/tmp/hosttools"; export HOME="/home/joan"; LANG=C git -c core.fsyncobjectfiles=0 fetch -f --prune --progress https://github.com/Xilinx/embeddedsw.git refs/*:refs/* failed with exit code 128, output:
remote: Enumerating objects: 12762, done.        
remote: Counting objects: 100% (12762/12762), done.        
remote: Compressing objects: 100% (38/38), done.        
error: RPC failed; curl 18 transfer closed with outstanding read data remaining
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

ERROR: fsbl-2020.2+gitAUTOINC+08b9f4304d-r0 do_fetch: Fetcher failure for URL: 'git://github.com/Xilinx/embeddedsw.git;protocol=https;branch=master-rel-2020.2'. Unable to fetch URL from any source.

The reason is it cannot fetch sources with git. I cannot do it myself on the terminal:

joan@joan:~$ git clone git://github.com/Xilinx/embeddedsw.git rubbish
Cloning into 'rubbish'...
remote: Enumerating objects: 27, done.
remote: Counting objects: 100% (27/27), done.
remote: Compressing objects: 100% (23/23), done.
error: RPC failed; curl 56 GnuTLS recv error (-9): A TLS packet with unexpected length was received.
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

Looking for that error there is a variety of recipes to fix that. Apparently some work for some people. I just tried some 20 of them in series and it must be my unlucky day as no one worked for me.

what puzzles me is that with some installs (VM, OS, packages, Xilinx sw) there is no problem and with others is that hell.

I think it's an issue that deserves an AR as there could be a number of users wasting their time with that.

0 Kudos
Reply
11 Replies
Scholar
Scholar
315 Views
Registered: ‎10-21-2015

Hi 

Your problem is related to git which is installed on ubuntu 

Petalinux just uses git command of the system to fetch sources

0 Kudos
Reply
Teacher
Teacher
303 Views
Registered: ‎06-16-2013

Hi @joancab 

 

It seems memory resource issue or network performance issue.

What is your memory size on VM ?

Also would you upgrade network driver on host ?

 

Best regards,

0 Kudos
Reply
Voyager
Voyager
287 Views
Registered: ‎05-11-2015

@watari  There are 200 GB, with just Vitis + Vivado + HLS + petalinux installed, so not even 50% used. Network driver on host? Not sure, I haven't changed anything related to network o the host machine and for the VM it is using what it came with VirtualBox 6.1. And inside of it all that comes with Ubuntu 18.04.4

0 Kudos
Reply
Scholar
Scholar
221 Views
Registered: ‎10-21-2015

You are better to debug git

Refer to https://stackoverflow.com/questions/6842687/the-remote-end-hung-up-unexpectedly-while-git-cloning

Alternatively, to avoid fetching from remote git repository, do setting download mirror

Refer to https://www.xilinx.com/bin/public/openDownload?filename=sstate_rel_2020.2-README.tar.gz

0 Kudos
Reply
Voyager
Voyager
212 Views
Registered: ‎05-11-2015

Is petalinux what uses git and does it the way it is, so workarounds, mirrors, etc. don't apply.

I tried a number of the recipes in that post and in similar ones.

Interestingly, for the same error, there are a variety of 'solutions', and none works.

0 Kudos
Reply
Scholar
Scholar
200 Views
Registered: ‎10-21-2015

Most people couldn't reproduce your problem.

I think your problem comes from something wrong in your system.

I have an experience I suffered from other git problem while using petalinux and I eventually fixed it by modifying git configuration in ~/.gitconfig

0 Kudos
Reply
Voyager
Voyager
197 Views
Registered: ‎05-11-2015

One of the last things I noticed yesterday before wiping the VM and starting again with all the install is that Ubuntu upgraded itself to 18.04.5 which is apparently not supported.

If that is the reason or not I don´t know.

I normally disable updates and upgrades for the principle of having a known reproducible system to work on. I'll be more careful with that this time and will let you know.

0 Kudos
Reply
Voyager
Voyager
180 Views
Registered: ‎05-11-2015

I can confirm that a fresh install of Ubuntu 18.04.4 on a VirtualBox 6.1 and installing petalinux 2020.2 following the procedure in the user guide and installing the necessary packages without error, produces again the above error.

"something wrong in your system" does not seem to apply to a fresh install, sorry.

"Most people couldn't reproduce your problem" I bet I did what anyone would do: set up a VM, install things.

As I have been working without problems in an 18.04 release, I guess the problem is in the .4 update.

0 Kudos
Reply
Teacher
Teacher
114 Views
Registered: ‎06-16-2013

Hi @joancab 

 

As you know, since petalinux (yocto) is resource-hungry, ex. cpu, network, storage, for parallel compile, it tends to take place.

Also, as you know, behavior of network on Ubuntu 18.04, especially DNS setting (systemd set dns as localhost. and it easily occurs.) is a little different before.

So, as I mentioned before, I told my suggestion to you.

 

> As I have been working without problems in an 18.04 release, I guess the problem is in the .4 update.

 

Would you reduce resource setting, ex. parallel cpu setting for build on petalinux, if you didn't have enough time to investigate the route cause ?

Perhaps, you might have to change environment from VM to native machine...

 

I hope this helps.

 

Best regards,

Voyager
Voyager
93 Views
Registered: ‎05-11-2015

@watari  I was about giving up with all 18.04 and install a 16.04. I'm surprised that I tried a number of times, all plain 18.04 to 18,04,5 with the same result: git doesn't work what makes petalinux-build fail. Even without installing any xilinx tool, git fails. I can't believe this is general as in that case many people would suffer that and it would be fixed, so it makes sense there is something in the VM configuration. I don't know how virtual hw can affect how git works. I will decide to either spend more precious time or just go for 16.04. At the end of the day, the OS is just the carpet on the floor, is not making anything.

 

0 Kudos
Reply
Voyager
Voyager
67 Views
Registered: ‎05-11-2015

Incredible. I have been installing and wiping all 18 releases and updates, tweaking the virtual machine settings, looking for that error on the internet to only find a range of diverse "solutions" that, apparently, some work for some (?) but no one works for me. 


So, my conclusion after half a week of dispair: petalinux 2020.2 doesn't work on Ubuntu 18 on, at least, a VirtualBox VM.

Actually, I would say any petalinux, because the problem is git doesn't work and it doesn't because of some problem with GnuTLS.

How do I dare to generalize from my personal case? Because I'm taking a fresh install, no updates, and doing just the minimum setup in the petalinux install guide.

Surprised that this isn't a general problem affecting many people. Anyways, I will stick to 16.04 and here is my experience.

If anyone comes with detailed, precise instructions on how to set up Ubuntu 18 and have petalinux working, happy to hear.

0 Kudos
Reply