Personal tools
You are here: Home ブログ matsuyama 帯域を制限してファイルをコピーする
« March 2010 »
Su Mo Tu We Th Fr Sa
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31      
Recent comments
Re:Emacsは死んだ Anonymous User 2010-03-10
Re:Emacsは死んだ Sony Vaio 2010-03-08
replica watches replica watches 2010-03-04
Re:pimplイディオムを語る hirose 2010-01-08
Re:pimplイディオムを語る Fumi 2010-01-02
 
Document Actions

帯域を制限してファイルをコピーする

他の作業を邪魔しないために IO の帯域を制限してファイルをコピーするには rsync--bwlimit という帯域制限のオプションを使うとよいです。

$ # 1GB のゴミデータを作る
$ dd if=/dev/zero of=dump bs=1M count=1024
$ # 帯域を 100kbps に制限してコピー
$ rsync --bwlimit=100 --progress dump dump2
dump                     
     5799936   0%   99.22kB/s    2:59:22

あるいは scp-l オプションを使うのもありです。

$ scp -l 100k dump localhost:$PWD/dump2

IO の帯域を制御して何らかのコマンドを実行するというもっと簡単な方法がありそうですが、少し調べた限りでは見つからなかったので、上記のような方法をとっています。もっといい方法があれば教えてください。

Category(s)
linux
The URL to Trackback this entry is:
http://dev.ariel-networks.com/Members/matsuyama/copy-files-with-limiting-bandwidth/tbping

Re:帯域を制限してファイルをコピーする

Posted by matsuyama at 2008-09-23 03:15
ionice で ionice -c3 cp ってやればいい感じにスケジューリングされるかも。
Add comment

You can add a comment by filling out the form below. Plain text formatting.

(Required)
(Required)
(Required)
(Required)
(Required)
This helps us prevent automated spamming.
Captcha Image


Copyright(C) 2001 - 2006 Ariel Networks, Inc. All rights reserved.