LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 04-08-2013, 02:07 PM   #1
Izzmit
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Rep: Reputation: Disabled
PUTTY (plink) File transfer


Hello. I am dealing with a floppy disk w/ a tar archive on it (created with the command "tar -cf /dev/sdb filename".
I have a linux box that is accepting the diskette, and a windows box that needs the data.
I need to ssh into the linux box, extract the files from /dev/sdb, and transfer them back into the local windows box. or convert to a zip file, and transfer that instead of individual files.

Cygwin is not really an option. It is too extensive of an application, and security is more comfertable w/ simple single-use applications. Instead, i am trying to use PUTTY.

Right now, i have the command:
"plink.exe -l username -pw password hostname cat /dev/sdb > newtar.tar"
This goes to the remote linux box and copies the floppy drive to the local windows box.
A) I would like to avoid dd and cat directly from the device -- it is very slow compared to tar -xf on the same disk. (5 seconds vs 30)

Does someone know a way to (using putty preferrably)
a)ssh into the linux box
b)extract the contents of a tar file
c)direct the output of that extract into a file (or files) on the local windows box

Thank you!


Edit: While im asking this...
I also need to do the exact reverse. (take file(s) on the windows box, tar -cf it to /dev/sdb on the linux box)

Last edited by Izzmit; 04-08-2013 at 02:09 PM.
 
Old 04-08-2013, 02:47 PM   #2
netnix99
Member
 
Registered: Jun 2011
Distribution: redhat, CentOS, OpenBSD
Posts: 216

Rep: Reputation: 62
Just my opinion.... use WinSCP on your Windows machine to transfer the files back and forth and create all of your tar files on your Linux machine.

HTH
 
Old 04-08-2013, 02:55 PM   #3
Izzmit
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Original Poster
Rep: Reputation: Disabled
My problem is, i need to make all of this a 1-click solution for very non-technical people to use many times a day.

I cannot have them placing files into a directory, creating tar files, scp-ing them back, and then opening the folder.
 
Old 04-09-2013, 06:59 AM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,807

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
Create a script on the linux box to copy the files and untar to a specified directory.
A batch file on the windows box can call this script via plink and use pscp to copy the files to the windows box.

The reverse is the same i.e a windows batch file will copy the files via pscp to the linux box and via plink call a script on the linux box to tar and copy the files back to the floppy.
 
Old 04-09-2013, 11:12 AM   #5
Izzmit
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Original Poster
Rep: Reputation: Disabled
That may be my best bet -- I was hoping to avoid a rube goldberg of scripts, but they gave me floppy disks to work with. Sigh.
 
Old 04-09-2013, 05:23 PM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,807

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
What about purchasing a USB floppy drive and installing 7-Zip. I would think you could train your windows people to untar or tar / zip files and copy to / from without much difficulty.
 
Old 04-10-2013, 08:11 AM   #7
Izzmit
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Original Poster
Rep: Reputation: Disabled
I am on a thin-client environment. Mounting/sharing a tar floppy image wont work.

I have decided to switch to dos-formatted disks. Annoying, as tar commands are far easier to use over a ssh connection, but I think that will be the least complex solution.

Thank you for your inputs.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how can i use putty to transfer files from linux ubuntu to another pc priyush Linux - Newbie 5 05-20-2012 08:35 PM
I am using plink as below. dhirendrs Programming 3 09-07-2011 10:25 AM
start gqview from windows over ssh with putty/plink Peterken Linux - Newbie 4 01-11-2010 07:51 PM
Sony PSP file transfer inaccurate transfer progress stratotak Linux - Newbie 3 01-02-2010 03:49 AM
How to use Putty(plink command line) to using application keypad settings to VT400? hocheetiong Linux - Newbie 1 08-14-2008 08:47 AM


All times are GMT -5. The time now is 08:42 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration