---
title: "shell find scp 命令"
author: "wushexin"
date: "2011-04-27T18:11:19Z"
tags: []
categories: ["操作系统"]
slug: "shell-find-scp"
draft: false
lastmod: "2011-04-27T18:11:19Z"
id: 1020298
url: "https://wushexin.iteye.com/blog/1020298"
---

查询某个文件下  文件大小大于 10k 的文件 ：

```
find /home/user/dir -size +10k 
```

 查找大于4的文件，全部复制到另一目录：

```
find /home/user/dir/ -size +4k -exec cp {} /home/user/newdir/ \;
```

 

 

scp 从本机拷贝到远程服务器：

```
 scp valid/* wusx@192.168.2.245:/home/wusx/gather/valid/  
```

 从远处服务器拷贝到本地：

```
scp user@192.168.2.245:/home/user/dir/ ./
```