On 9/3/19 10:03 PM, ToddAndMargo via users wrote:
Hi All,
I have a flash drive with about four partitions on is. Lets call it /dev/sdc.
Can I tar sdc or am I stuck with tarring the partitions?
Any drawback to this?
Many thanks, -T
Followup.
This is what I finally wound up doing to back up this stick. Dead Stick is a play on words off of Live USB:
Backup:
1) shutdown: zero out unused space
Figure out which partitions / and /boot are loated on. Gparted works well for this..l Usually they are /dev/sdb3 and /dev/sdb4:
partitions must not be mounted
# zerofree -v /dev/sd.. # zerofree -v /dev/sd..
2) shutdown: make a dd and gzip
Find the device name (/dev/sdx)
Note: if the "dd" crashes on a USB3 port, try a USB2 port
# dd bs=4096 if=/dev/sdx of=DeadStick.[date] # gzip DeadStick.[date] # creates DeadStick.[date].gz # rm DeadStick.[date]
A one liner to peak at the progress: $ ls -al | p6 'my @x=$*IN.lines; say (@x[3].words[4].Int) / 1000000000 ~ " GB";' 64.1604009 GB
I had to use a USB 2 port as my (usb3) stick would crash dd when used with all my USB3 ports.
-T