[pbs-devel] building proxmox-backup-qemu
Niko Fellner
n.fellner at logics.de
Wed Dec 2 20:55:46 CET 2020
> 3.) install librust-cbindgen-dev in addition to cbindgen (the latter is
> the binary, the former contains the source code to satisfy cargo that
> the crate is available)
That was the missing part for me! Maybe you can add it to the dependencies aswell?
Thanks a lot! :)
Here is everything together:
# Basic setup
echo 'deb http://download.proxmox.com/debian/devel/ buster main' >> /etc/apt/sources.list.d/proxmox-devel.list
wget http://download.proxmox.com/debian/proxmox-ve-release-6.x.gpg -O /etc/apt/trusted.gpg.d/proxmox-ve-release-6.x.gpg && \
apt-get update && \
apt-get install -y devscripts debcargo clang
# Build PBS
apt-get update && apt-get dist-upgrade -y && \
git clone git://git.proxmox.com/git/proxmox-backup.git && cd proxmox-backup/ && \
#git checkout v1.0.3 && \
mk-build-deps -ir; mk-build-deps -ir && \
make && make install
# Build proxmox-backup-qemu
cd ~ && git clone git://git.proxmox.com/git/proxmox-backup-qemu.git && \
cd proxmox-backup-qemu && \
# Optionally: add some changes to the rust sourcecode :) \
sed -i 's/speed={:.2}MB/speed={:.2}MiB/' src/restore.rs && \
# Changes to Cargo.toml according to https://lists.proxmox.com/pipermail/pbs-devel/2020-November/001635.html \
sed -i 's/proxmox = { version = "0.7.0"/proxmox = { version = "0.8.0"/' Cargo.toml && \
sed -i 's/proxmox-backup = { git = "git:\/\/git.proxmox.com\/git\/proxmox-backup.git", tag = "v1.0.4" }/#proxmox-backup = { git = "git:\/\/git.proxmox.com\/git\/proxmox-backup.git", tag = "v1.0.4" }/' Cargo.toml && \
sed -i 's/#proxmox-backup = { path = "..\/proxmox-backup" }/proxmox-backup = { path = "..\/proxmox-backup" }/' Cargo.toml && \
apt-get install -y librust-cbindgen-dev && \
export BUILD_MODE=release && \
mk-build-deps -ir && make && make deb && make install
# You can use the .deb files in the proxmox-backup-qemu directory directly now or ship them to the target Proxmox installation
dpkg -i libproxmox-backup-qemu*
# Optionally - if you want to build a new pbs-restore binary (for me that's not neccessary; I'm happy with the libs from proxmox-backup-qemu):
# Build pve-qemu. Requires either proxmox-backup-qemu libs (see above) or a PVE installation
cd ~ && git clone git://git.proxmox.com/git/pve-qemu.git && \
cd pve-qemu && apt-get install -y libaio-dev libcap-ng-dev libfdt-dev libglusterfs-dev libiscsi-dev libjemalloc-dev \
libjpeg-dev libnuma-dev libpci-dev libpixman-1-dev librbd-dev libsdl1.2-dev \
libseccomp-dev libspice-protocol-dev libspice-server-dev libusb-1.0-0-dev libusbredirparser-dev texi2html texinfo xfslibs-dev && \
mk-build-deps -ir && make && \
apt-get install -y ceph-common numactl python-cephfs python-prettytable python-rados python-rbd python-requests python3-prettytable libboost-program-options1.67.0 libgoogle-perftools4 libradosstriper1 python-certifi python-chardet python-idna python-urllib3 python-chardet libcephfs2 python-pkg-resources python-six libtcmalloc-minimal4 && \
dpkg -i pve-qemu*.deb
More information about the pbs-devel
mailing list