Skip to main content

Questions tagged [pv]

Pipe Viewer, or pv, is a Unix tool for monitoring pipelines and the progress of data through them.

4 votes
2 answers
332 views

Permission denied using pv for copying image to USB drive

I am attempting to copy an Arch Linux ISO image directly to a USB drive. Previously, I have simply used either cp or dd to do this, such as: sudo cp image.iso /dev/sdb where /dev/sdb is the USB ...
esotechnica's user avatar
0 votes
2 answers
160 views

how do i use pv in a script that has a seq for loop

I have a script that has a for loop in it that runs a specific amount of times, and I was wondering if it is possible to implement the pv command in my script to add a progress bar. Here is my code: ...
harry mckay's user avatar
0 votes
1 answer
68 views

Pipe viewer not working with mysql

I have a new web hosting server (Ubuntu 20) that I need to manage over ssh (shell is bash). It has this strange issue that pv does not print anything when piping to mysql. I.e. gunzip < mydump.sql....
Anton Duzenko's user avatar
0 votes
0 answers
31 views

Replicating SD card: hangs at 99%

The goal is to replicate an SD card. Despite successfully replicating the SD card a few years ago, a recent attempt hangs at 99%, despite attempts from 2 different PCs. user@JUPITER Desktop$ date; ...
gatorback's user avatar
  • 1,532
2 votes
1 answer
471 views

pv gives 100% progress with small buffer

I have to do a long task (convert image format) for every file of a folder. I achieved to use pv to write the estimation of duration with (used sleep here to simulated processing time): pv -B 1 =(find ...
rafoo's user avatar
  • 121
1 vote
1 answer
195 views

How to avoid hardware damage with dd

I wanted to create an encrypted USB-stick. In the tutorial I used it said something like 'to avoid pattern based attacks dump random input to the drive'. So I did by dding /dev/urandom to the drive. ...
bananabook's user avatar
1 vote
1 answer
597 views

Cut off pipe after N bytes

I am piping information to a file using myTool > file.txt 2>&1, but the tool might generate GigaBytes worth of data - I need to cut off after the first N bytes, let say 2MB. It seems pv can ...
ThE_-_BliZZarD's user avatar
0 votes
0 answers
136 views

did `dd` buffer entire ~700MB iso image?

I read that to transfer an iso image to a pendrive and print progress I should execute pipeline below. $ dd if=$IMG bs=4M | pv -s 668M | sudo dd of=/dev/sdc bs=4M pv should print and update a ...
lord.didger's user avatar
4 votes
2 answers
3k views

How to format hexdump as xxd, possible for xxd -revert?

I wish to dump the raw content of a SD card into a file for inspection. Most parts of it are zeroes. Learnt from this SuperUser answer I could use pv to show the progress of od and hexdump. Both ETA ...
midnite's user avatar
  • 613
0 votes
1 answer
1k views

Get hash from file while you copy or move it

Say I copy a file with pv, is there any way to also get any hash, like md5, sha1, etc without having to read origin twice? It has to work with big files or block devices. Example command which does ...
Smeterlink's user avatar
14 votes
5 answers
71k views

pvcreate: Can't use /dev/sda: device is partitioned

I'm currently installing arch linux and when I try to create a physical volume it gives me this error. Can not use /dev/sda: device is partitioned What is this error and how can I get rid of it? PS: ...
dead101's user avatar
  • 141
1 vote
2 answers
464 views

Execute single command with write caching disabled

Whenever I write a large file to a USB drive, write caching makes it very difficult to track process. I can disable it in various ways like echo 1000000 > /proc/sys/vm/dirty_bytes which solves the ...
Bagalaw's user avatar
  • 1,085
1 vote
1 answer
789 views

1TB drive compressed shows only 3.8GB, what did I do wrong?

On Linux Mint 20.2 Cinnamon I would like to create a disk image of my secondary disk drive (SATA) containing Windows 10, not that it matters now, directly gzip'ed using the Parallel gzip = pigz onto ...
Vlastimil Burián's user avatar
4 votes
1 answer
1k views

pv not printing to a pipe

Executing this command displays the output on console. But when output is piped to another command it does not work. See below. (pv -F $'%t %r %e\n' /dev/nvme0n1p1 | gzip -c >/run/test.img ) 0:00:...
user2107349's user avatar
0 votes
1 answer
2k views

PV command to show progress in Dialog with transfer rate in Mbits

I am using PV -n command to read partitions and using gzip with pipe to compress the read data and storing the file. While data is read and written I am using a while loop to show progress using linux ...
user2107349's user avatar

15 30 50 per page
1
2 3 4 5