[NTLUG:Discuss] Output to Multiple Files - Now More

David Wilson drindles at yahoo.com
Thu Apr 7 13:52:59 CDT 2005


Patrick,  you hit the nail on the head. Now where do I
find someone to write that Perl or C program?

David



--- "Patrick R. Michaud" <pmichaud at pobox.com> wrote:
> On Thu, Apr 07, 2005 at 11:34:43AM -0500, Fred James
> wrote:
> > David Wilson wrote:
> > 
> > >My goal is to capture a forensic image of a hard
> drive
> > >to a dd type of file. I need to split it into
> chunks
> > >(FAT32 limitation).  My process requires that I
> have
> > >two copies of the files when complete.  I am
> trying to
> > >save the time required to make a copy.  
> 
> > So maybe ...
> > dd if=/dev/sdb | split -b 640m
> > for i in `ls x??`
> > do
> >    cat $i | tee /path_1/$i /path_2/$i_2 2>&1
> /dev/null
> > done
> 
> I think David's purpose is to avoid the expense of
> reading
> the image "twice" -- i.e., to be able to read it
> once and
> write it to two places simultaneously.  Almost
> anything
> involving split/cat means that everything is being
> read
> twice.  Otherwise we could just do
> 
>    split -b 640m /dev/sdb
>    cp x?? /path_1
> 
> which is basically the equivalent of the above but
> requires that the contents are read twice.
> 
> I don't think split/tee (or the shell) are going to
> get David 
> where he wants to go -- this might be a case where
> it's better to do 
> things with a Perl script or a specialized C program
> designed
> for the purpose.  
> 
> Pm
> 
> _______________________________________________
> https://ntlug.org/mailman/listinfo/discuss
> 


		
__________________________________ 
Yahoo! Messenger 
Show us what our next emoticon should look like. Join the fun. 
http://www.advision.webevents.yahoo.com/emoticontest




More information about the Discuss mailing list