[ILUG] Linux question:

ChipEast at aol.com ChipEast at aol.com
Tue Jan 16 18:21:15 GMT 2007


Robert:

I found your very helpful posting:

http://sweetnam.eu/mediawiki/index.php/Using_Netcat_for_Backup

and had a couple of questions..... if you don't mind the intrusion

As a bit of background, I am not a Linux pro, I am a photojournalist with 
LOTS of files.... about 1.5tb.   These are well organized on FireWire hard drives 
attached to a Mac with OS-X.   In a former life I was a computer tech doing 
repairs and network installs, so I am not a total newb... just out of date with 
Linux, which I have not needed in about five years.

I built a nice server over the holidays with a RAID(5) of five 750gb drives 
to hold all my pix.   Needing to copy them from the external drives, I used 
Samba sharing and drag-and-dropped them over, a folder at a time, making sure I 
didn't have illegal file names, and fixing when I found a few.   Initial 
testing showed success, so I dumped about 700gb over to the server by hand, over 
several days.   Yes this seems slow, but I also wanted to make sure there wasn't 
duplication and make sure everything was organized well on the server.

It turns out, MANY of the files are corrupt.   They are almost all jpeg's....

So, looking around, I found your helpful netcat article and have gotten it to 
initially work, but can't seem to find any reference on changing the script 
around a bit.   Hopefully you can suggest a few things.

As a test, I ran the first line on the Linux box (Ubuntu 6.10, working great 
other than these file issues), then modified the 2nd line, the one for the Mac 
sending the files, to look like this:

tar jlcvPpf - /Users/chipeast/Desktop/EAST_NJNG13jan07/   > 
/dev/tcp/192.168.1.16/6666

It transferred the files... really fast!

But, here are the changes I am not knowledgeable enough to do:

1) how do I specify the target directory (which is actually 
/archive/pix_archive/) so the folder of pix goes in the correct place?   The tar went straight 
to my home directory on the server.

2) how do I eliminate the directory structure being duplicated?   On the 
receiving machine, it recreated the /Users/chipeast/Desktop/EAST_NJNG13jan07/ 
inside the tar, instead of just giving me the one folder with the photos (in this 
case, /EAST_NJNG13jan07/).

3) how do I have the tar auto-uncompress on the receiving end, leaving me 
with just the single folder full of pix?

4) lastly, how do I avoid the hidden files in the tar for the copy?   OS-X 
litters the receiving machine with all kinds of "._" files which do no good on 
the Linux machine.

MANY THANKS for your help!

Warm regards.......... Chip



More information about the ILUG mailing list