Re: Pipe to tar or other compressor

Atom Smasher <[email protected]>
Newsgroups gmane.org.user-groups.linux.new-zealand.general
Message-ID <1110162221160.2144@smasher>
On Sun, 16 Oct 2011, Peter wrote:

>  mysqldump {opts} | tar -cf --lzma - > outfile.7z
>
> doesnt work because tar expects a directory
>
> two steps works for the last method , but this is linux it must be 
> doable in one step?
=============

tar is a "tar archiver". it supports compression, but the result is no 
different that compressing a tar file.

try piping though bzip2... or create a temp-file, and compress it however 
you like....

one step or two... it often depends on how unreadable you want to make the 
command. there's nothing wrong with doing it in two steps, if it works.


-- 
         ...atom

  ________________________
  http://atom.smasher.org/
  762A 3B98 A3C3 96C9 C6B7 582A B88D 52E4 D9F5 7808
  -------------------------------------------------

 	"Our enemies are innovative and resourceful, and so
 	 are we. They never stop thinking about new ways to
 	 harm our country and our people, and neither do we"
 		-- George "dubya" Bush, 5 Aug 2004


_______________________________________________
NZLUG mailing list [email protected]
http://www.linux.net.nz/cgi-bin/mailman/listinfo/nzlug
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.