The rpm package which i created takes long time to install. It contains only database file of Berkely db format and size 2.2GB.
Below is my RPM spec
#AutoReq: no
AutoReqProv: no
%define PYTHON /usr/bin/python
%define RPM_BUILD_DIR %{_topdir}/BUILD
%define RPM_BUILD_ROOT %{_topdir}/tmp
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
%define _source_payload w0.gzdio
%define _binary_payload w0.gzdio
#
Summary: Prefixcat db package
Name: prefixcat
Version: %{VERSION}
Release: %{RELEASE}
Source: %{_sourcedir}
BuildRoot: %{_tmppath}/%{name}
License: internal-only
Distribution: WR Linux
Vendor: XXX xxx
Packager: XXX xx<[email protected]>
Group: Test/Applications
#BuildArch: x86_64
%description
Prefixcat db
#%prep
#%build
%install
mkdir -p %{buildroot}/data/db/wbrs/factory/db
cp -r %{_sourcedir}/data/db/wbrs/factory/db/prefixcat_db %{buildroot}/data/db/wbrs/factory/db
%clean
%{__rm} -rf %{buildroot}
%pre
%post
echo "Prefixcat DB installed successfully in /data folder"
%files
%defattr(-,admin,root,-)
/data
%changelog
* Tue Aug 01 2017 Sudharsan C <[email protected]>
- Create prefixcat db as a seperate rpm
rpm ivh prefixcat-1.1.100.x86_64.rpm, takes almost 15mins to install.
Also the above command causes this error
error: unpacking of archive failed on file /data/db/wbrs/factory/db/prefixcat_db;59818e12: cpio: read failed - Bad file descriptor
Any help on how to compress the size and install faster?
Fyi:- i am building this rpm on CentOS7 and installing on windriver 8. RPM version is same across both OS.
If the target architecture is 32-bit you might be running into a 2GB file size limit. What is the target architecture and root filesystem type?
EDIT: Since you are using a 64-bit kernel a 2GB limit is far less likely.
Have you verified (with sha256sum or similar) that the .rpm file on the remote system matches the file on your development system?