Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image download fails with a EOF error #240

Open
arky opened this issue Mar 25, 2012 · 8 comments
Open

Image download fails with a EOF error #240

arky opened this issue Mar 25, 2012 · 8 comments

Comments

@arky
Copy link
Contributor

arky commented Mar 25, 2012

443 KB/s (23320 bytes in 0.051s)
Pulling "ODEAnim.zip"
2901 KB/s (4305404 bytes in 1.449s)
Downloading CyanogenMod image update-cm-7.1.0-GalaxyS2-signed.zip ...
Image update-cm-7.1.0-GalaxyS2-signed.zip exists, skip downloading
[update-cm-7.1.0-GalaxyS2-signed.zip]
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
unzip: cannot find zipfile directory in one of update-cm-7.1.0-GalaxyS2-signed.zip or
update-cm-7.1.0-GalaxyS2-signed.zip.zip, and cannot find update-cm-7.1.0-GalaxyS2-signed.zip.ZIP, period.
Copying "libaudiopolicy.so"
cp: cannot stat `cm_root/system/lib/libaudiopolicy.so': No such file or directory
OK

@arky
Copy link
Contributor Author

arky commented Mar 25, 2012

Workaround: Remove the previously downloaded file from B2G directory:

find . -name update-cm-7.1.0-GalaxyS2-signed.zip -ok mv {} \tmp ;

@shianyow
Copy link
Collaborator

I tried but cannot reproduce this issue.
It looks like the previously downloaded zip file was corrupted.
Does this always happen?

@shianyow
Copy link
Collaborator

You can uncomment this line to remove the image after extracting.
https://github.com/cgjones/android_device_samsung_galaxys2/blob/gingerbread/extract-cm.sh#L95

@arky
Copy link
Contributor Author

arky commented Mar 28, 2012

@shianyow

You can reproduce the problem by interrupting the wget download process. This can help either due to network failures or lost bits.

@shianyow
Copy link
Collaborator

OK, it will be fixed by joneschrisg/android_device_samsung_galaxys2#25

@arky
Copy link
Contributor Author

arky commented Mar 29, 2012

@shianyow @cgjones

The following part of code can re-factored by simplying using 'wget -c' . This enables us to continue partial downloaded files and also check if the images was already downloaded.

echo Downloading CyanogenMod image $CM_IMAGE ...
if [ -f $CM_IMAGE ]; then
echo Image $CM_IMAGE exists, skip downloading
else
wget $CM_DOWNLOAD_SITE/$CM_IMAGE
fi

@arky
Copy link
Contributor Author

arky commented Mar 29, 2012

@shianyow
Copy link
Collaborator

It looks great with 'wget -c'. Would you send a pull request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants