# [FreeNAS] How to Copy disk to Dir



## area1509 (Apr 26, 2010)

Hi. When I mess with commands in putty makes me feel like a retard.

I have 2 servers,
1: //Local/ (10.90.1.6) with shares FreeNasDisk1 and FreeNasDisk2

2: //Software/ (10.90.1.41) with share 750gb

I want to use Putty to copy the contents of FreeNasDisk1 and FreeNasDisk2 to Dir's or folders on 750gb.
is this possible?

Thanks A.J.

10.90.1.41 is 0.69.1 Omnius (revision 4554)

10.90.1.6 is 0.7 Khasadar (revision 4919)


----------



## SirDice (Apr 26, 2010)

Topics about PC-BSD / FreeNAS / DesktopBSD / m0N0WALL / pfSense

Having said that, I suppose, if you have ssh access to both boxes you could do something like:
[cmd=]scp /somedir/* username@Software:/some/other/dir[/cmd]


----------



## area1509 (Apr 26, 2010)

I know this is elementary but what am I doing wrong.



```
Welcome to FreeNAS! 

> su
Password:
local:/mnt/# scp /FreeNasDisk1/* area@software: /750gb/FreeNasDisk1
scp: No match.
local:/mnt/# scp/FreeNasDisk1/* area@software: /750gb/FreeNasDisk1
scp/FreeNasDisk1/*: No match.
local:/mnt/# ls
FreeNasDisk1    FreeNasDisk2
local:/mnt/# cp/FreeNasDisk1/* area@software: /750gb/FreeNasDisk1
cp/FreeNasDisk1/*: No match.
local:/mnt/# cp /FreeNasDisk1/* area@software: /750gb/FreeNasDisk1
cp: No match.
local:/mnt/# copy /FreeNasDisk1/* area@software: /750gb/FreeNasDisk1
copy: No match.
local:/mnt/#
```


----------



## SirDice (Apr 26, 2010)

hehe.. FreeNasDisk1 and FreeNadDisk2 are mounted on /mnt/. 
That makes their path /mnt/FreeNasDisk1/, not /FreeDisk1/ (that's a directory mounted under root / ).

Hence the "No match". You're pointing it to a non existing directory.

[hint: use the shell's auto-complete if you're not sure where things are]


----------



## graudeejs (Apr 26, 2010)

also there are spaces between *area@software[red]: /[/red]750gb/FreeNasDisk1* I think that might cause problems as well
+ I suggest to add -r flat to scp


----------



## area1509 (Apr 26, 2010)

Ok a little closer, it thought for a while and spit this at me.


```
local:/mnt# scp -r /mnt/FreeNasDisk1/* area@software:/mnt/750gb/FreeNasDisk1
ssh: connect to host software.workgroup port 22: Operation timed out
lost connection
local:/mnt#
```

I am trying to do this from putty connected from a windows7 machine


----------



## area1509 (Apr 26, 2010)

Sorry this post is in the wrong place all I am trying to do is copy large amounts of data from one server to another without involving the windows machine I am using.
seems it is a lot more complicated than I thought.

see now there might be the problem (I thought)


----------



## graudeejs (Apr 26, 2010)

either your sshd isn't running, or it's listening to other port (22 by default), or firewall is blocking port 22


----------

