Export data from remote kernel onto a local machine

I can not access the directory on my remote kernel these days. Therefore, I want to export the output of the computations to my local machine.

Some details:

• My remote kernel is on a Tyan TX46 with 4 Opteron 2.2Ghz cpus and 32GB of ram and my local machine has a Intel(R)Core(TM)2CPU 6600 @2.40 GHz processor and 4gb ram.

• I don't use parallel remote kernels.

• I installed my remote kernel by some settings on Evaluation>Kernel Configuration Options.

Is there a way to do that?

-
I think the question has potential but you should add more details. Are you using parallel remote kernels? What are your OS? How do you open a remote connection? Etc.. Everything which could be important to a potential answerer. – halirutan Feb 11 '13 at 2:50
@halirutan Thank you. I have added some details. Please see my edit. – cesm Feb 11 '13 at 15:18
What do you mean "you can't access the directory"? How can you launch a remote kernel, e.g. through ssh, without being able to scp the file? Is this something you need to do once, or every time you run your Mathematica program? How much data are we talking about? – Joel Klein Feb 11 '13 at 15:34
I think you probably have to share a directory either on your or on the remote computer. Then you can export directly to the shared directory. Is this windows or linux? – Ajasja Feb 11 '13 at 17:49
@cesm Could you explain why you can't access the files on the remote machine then? Is there any chance you could figure out how to access them? I think this would be more convenient than trying to find a solution within Mathematica. Even if we did implement a MathLink based solution, it would be very very slow and unreliable for transferring gigabytes over the network. – Szabolcs Feb 11 '13 at 20:34

In an effort to reduce unanswered questions:

I would create a folder on your computer (example C:\tmp) and give everyone read/write permissions

Then you can access the folder from the remote kernel by doing

d=RandomReal[{-1, 1}, {3, 2000}];
Export[Export["\\\\YOUR-COMPUTER-NAME_OR-IP\\tmp\\d.dat", d]


There are also other options:

1. Set up a sftp server on your computer and connect to it using Rolf Mertig package.
2. See if you can connect using scp.
Hello, I've tried your proposal under Linux environment but I couldn't make it work. Is there two nested Export functions : Export[Export[...]] ? I tried as well something with ssh but with no success : Export["!ssh user@machineip cat d.dat", d] – Pierre L. Jun 16 '15 at 9:45