rsyncã§ã®ãã©ã«ãåææã®æååãã解決ãã
iconvãªãã·ã§ã³ã使ãã°ããã£ã
ã前回のエントリã®æå¾ã®ã»ãã§æ¸ããããã«ãrsyncã§ãã©ã«ããåæãããã¨ããããåæèªä½ã¯æ£å¸¸ã«ã§ãããã®ã®ããã°ã®é¨åã«è¡¨ç¤ºãããæ¥æ¬èªãã¡ã¤ã«åãå ¨é¨æååããã¦ããã¾ããã
ãã§ãããã解決ããæ¹æ³ã¨ãã¦ãrsyncã«--iconvã¨ãããªãã·ã§ã³ããããã¨ãç¥ãã¾ããã
Macの濁点ファイルをなんとかする - Qiita
http://www.izurunet.jp/2013/04/13/rsync%E3%81%A7%E6%96%87%E5%AD%97%E5%8C%96%E3%81%91%E3%81%99%E3%82%8B%E6%99%82%E3%81%AFiconv%E3%82%AA%E3%83%97%E3%82%B7%E3%83%A7%E3%83%B3%E3%82%92
ãã¯ã¦ãªäººåæ¤ç´¢ã§質問ãã¦æãã¦ããã£ããã®ã§ãã
rsyncã®ææ°ãã¼ã¸ã§ã³ãã¤ã³ã¹ãã¼ã«ãã
ããã ãä¸è¨ã®ãµã¤ãã«æ¸ããã¦ããããã«ãªãã·ã§ã³ãä»ããã ãã§ã¯ä¸æããããªãã£ããã§ãããã
ããã£ã¦ã¿ãã¨ã
rsync: --iconv=UTF8-MAC,UTF-8: unknown option rsync error: syntax or usage error (code 1) at /SourceCache/rsync/rsync-45/rsync/main.c(1333) [client=2.6.9]
ãã¨ããã¨ã©ã¼ãã§ãã
ãããã¯ãªããã¨ããã¨ãMac OS Xã«æ¨æºã§ã¤ã³ã¹ãã¼ã«ããã¦ããrsyncã®ãã¼ã¸ã§ã³ãå¤ãã¦ã--iconvã¨ãããªãã·ã§ã³ã«å¯¾å¿ãã¦ããªãããã®ããã§ãã
ãããã§ãå
ã»ã©ã®
ãMacの濁点ファイルをなんとかする - Qiita
ãã«ãæ¸ãã¦ããããã«ãHomebrewã§ææ°ã®rsyncãã¤ã³ã¹ãã¼ã«ãããã¨ã«ãã¾ããã
ãHomebrewèªä½å
¥ãã¦ããªãã£ãã®ã§ãä»ååãã¦å°å
¥ãã¾ããã
ãMacにHomebrewをインストールする - Qiita
ããã®ãã¼ã¸ã®ã³ã¡ã³ãæ¬ã«ããããã«ãææ°ã®URLãæå®ãã¦ãã¿ã¼ããã«ããã
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
ãã¨æã£ã¦ãæ示éãã«returnãã¼ãæ¼ãã¦ãã¹ã¯ã¼ããå
¥ããã ãã§ãã
ãHomebrewã®ã¤ã³ã¹ãã¼ã«å¾ãさっきのサイトã«ãããã£ã¦ã
brew tap homebrew/dupes brew install libiconv brew install rsync
ãã¨æã£ã¦ææ°çã®rsyncãã¤ã³ã¹ãã¼ã«ãã¾ããã
ããããããã¯ããèãããiconvã®ã©ã¤ãã©ãªãã¤ã³ã¹ãã¼ã«ãã¦ãããããªã®ã§ãã²ãã£ã¨ãã¦ãrsyncã®ãã¼ã¸ã§ã³ã¯é¢ä¿ãªãããã®ã©ã¤ãã©ãªã®æç¡ã ããåé¡ãªãã§ãããï¼
ã·ã³ããªãã¯ãªã³ã¯ãè²¼ã
ããã ãææ°çãã¤ã³ã¹ãã¼ã«ãããããã§ããã¾ããã¨ããã¨ãããã§ããªãã¦ã
ãbackup - rsync --iconv option on Mac not working (sync from remote Linux server to local Mac) - Server Fault
ããã®ãã¼ã¸ã®è§£èª¬ã«ãããã£ã¦ã
sudo -s cd /usr/bin mv rsync rsync-2.6.9 ln -s /usr/local/bin/rsync . exit
ãã¨ããå¦çããã¾ããã
ãããã¯ããããã«ããã¨ãã¨Mac OSã®æ¨æºã®ã³ãã³ãã¨ãã¦ã¤ã³ã¹ãã¼ã«ããã¦ãã
ã/usr/bin/rsync
ãã®ååãã¾ããrsync-2.6.9ãã«å¤æ´ï¼ã ãããã®ååã§å¼ã³åºãã°ã¾ã使ããï¼ãã¦ããã¦ãåããã£ã¬ã¯ããªå
ã«rsyncã¨ããåã®ã·ã³ããªãã¯ãªã³ã¯ãä½æããå¾æ¥éãã¿ã¼ããã«ããrsyncã¨æã£ãå ´åã«ã¯ãã®ã·ã³ããªãã¯ãªã³ã¯ãçµç±ãã¦
ã/usr/local/bin/rsync
ããèµ·åãããã¨ã«ããã¨ãããã¨ã ã¨æãã¾ãã
ãã¡ãªã¿ã«ããã®ãªã³ã¯å
ã®
ã/usr/local/bin/rsync
ããã¿ã¦ã¿ãã¨ãããããããã¤ã¯ã·ã³ããªãã¯ãªã³ã¯ã«ãªã£ã¦ãã¦ãåç
§å
ã¯
ã/usr/local/Cellar/rsync/3.1.1/bin/rsync
ãã¨ãªã£ã¦ãã¾ãããããã«ãHomebrewã§ã¤ã³ã¹ãã¼ã«ãããææ°ã®rsyncãç½®ããã¦ãããã§ããã
ãã¤ã¾ãããã¯ãæ°ããã§ããã·ã³ããªãã¯ãªã³ã¯ã§ãã
ã/usr/bin/rsync
ããããã£ãã
ã/usr/local/bin/rsync
ãã¨ããå¥ã®ã·ã³ããªãã¯ãªã³ã¯ãçµç±ãã¦
ã/usr/local/Cellar/rsync/3.1.1/bin/rsync
ããèµ·åãã«ããã¨ãããäºæ®µã¸ã£ã³ãã¿ãããªæãã ã¨æãã¾ãã
ãã¹ã¤ã«äºæ®µã¸ã£ã³ãã«ããã«ç´æ¥åç
§ãããã¨ã«ãã¦ãããã¨æãããããããã¿ã¼ããã«ãã
ã/usr/local/Cellar/rsync/3.1.1/bin/rsync
ãã
ã/usr/local/bin/rsync
ããæå®ãã¦å®è¡ãããã¨ã«ããã°ã
ã/usr/bin/rsync
ããæ¸ãæããå¿
è¦ããªãã¨æãã¾ããã
ãã¾ããä½ã¯ã¨ããããããã§ãã¾ã--iconvãªãã·ã§ã³ã使ããããã«ãªãã¾ããã
rsync -auv --delete --iconv=UTF8-MAC,UTF-8 /Volumes/4TB_Main/ /Volumes/4TB_Backup/
ãã¨ãããµãã«ããã¨ãæ¥æ¬èªæååãããªãç¶æ
ã§rsyncãå®è¡ãããã¨ãã§ãã¾ãããã¡ã¤ã«åã®æåã³ã¼ããUTF8-MACããUTF-8ã«å¤ãã¦ããã¨ããæå³ã§ããã
ãããªãè½ã¨ãç©´
ããããï¼
ãæ¥æ¬èªãã¡ã¤ã«åãæååããããã«åæã§ããããã«ãªã£ãã®ã¯ãããã§ããããã³ãªãã¨ã«æ°ã¥ãã¾ããã
ãä¸è¨ã®ããã«--iconvãªãã·ã§ã³ãã¤ããã¨ãåæå
ã§æ´æ°ããã¦ããªããã¡ã¤ã«ã¾ã§å
¨ã¦æ°ãã«åæå
ã¸ä¸æ¸ãããã¦ãã¾ããå·®åã ãã®åæã«ãªããªãã§ãã
ã解決æ¹æ³ããã®ããããã¾ããããç¾æ®µéã§ã¯ãããã¾ããã調ã¹ã¦ããªããã©ã
ãããã¯ããªãå°ãï¼åæã«ãã®ãããæéããããï¼ã®ã§ãåºæ¬çã«ã¯--iconvãªãã·ã§ã³ãªãã§æ¥ã
ã®åæãå®æ½ããä½ãã¨ã©ã¼ãèµ·ããã¨ãã«ã¿ã¼ããã«ãããã°ãã¿ãªããæä½ããã¨ããå ´é¢ã§ä½¿ããããã«ãã¨ããããªâ¦â¦ã
ãå°ã£ãã®ã§ã人åæ¤ç´¢ã§æ°ãã«è³ªåãç«ã¦ã¦ããã
ãMacでのrsyncコマンドの使い方についての質問です。 http://q.ha… - 人力検索はてな
ãçµè«ã¨ãã¦ã¯ããããããªãã