Pipe lzop and 'vma extract'

Valerio Pachera

Active Member
Aug 19, 2016
131
6
38
43
Hi all, I read the documentation about vma format.
Sometime I may have to restore an image to rescue some files.
I can achieve that by

lzop -d file.vma.lzo
vma extract file.vma restore_dir

There I get a sparse raw file that I can mount like that

mount frestore_dir/file.raw /mnt/restore -o ro,offset=1M

My concern is about the required space: .vma and .raw.
Is it possible to pipe lzop and 'vma extract' so that I don't need to store the vma file?
I'm pretty sure it's possible because proxmox doesn't use temporary file for the restore.
I think the trick can be done by the '-r fifo' option but I have no idea how.

vma extract <filename> [-r <fifo>] <targetdir>

Any suggestion?

Thank you.
 
sure, just do this:
Code:
lzop -d -c BACKUPFILE | vma extract -v - OUTPUTDIR

the "-" tells vma to read from stdin instead of from a file, "-v" makes it output more progress information.