There are 5 huge files ( file1, file2, .. file5) about 10G each and extremely low free space left on the disk and I need to concatenate all this files into one. There is no need to keep original files, only the final one.
Usual concatenation is going with cat
in sequence for files file2
.. file5
:
cat file2 >> file1 ; rm file2
Unfortunately this way requires a at least 10G free space I don't have. Is there a way to concatenate files without actual copying it but tell filesystem somehow that file1 doesn't end at original file1 end and continues at file2 start?
ps. filesystem is ext4 if that matters.
dd
. – rush Jun 23 '13 at 20:28nbd-server
. – Stéphane Chazelas Jun 23 '13 at 20:33