unison 安装

1,安装ocaml-4.03.0.tar.gz

wgethttp://caml.inria.fr/pub/distrib/ocaml-4.03/ocaml-4.03.0.tar.gz

./configure -prefix /usr/local/unison/

make world opt

make install

2,unison

https://www.cis.upenn.edu/~bcpierce/unison/download.html官网

http://www.seas.upenn.edu/~bcpierce/unison//download/releases/版本库

wgethttp://www.seas.upenn.edu/~bcpierce/unison//download/releases/unison-2.48.4/unison-2.48.4.tar.gz

yum 出现报错乱码。执行 yum make clean 即可     

# yum install glib2-devel  glib2 atk    atk-devel   pango-devel  gtk2+devel

# gtk2

# ./configure --prefix=/usr/local/gtk --without-libtiff --without-libjpeg 

yum install ctags-etags

make UISTYLE=text THREADS=true


wgethttp://caml.inria.fr/pub/distrib/ocaml-4.03/ocaml-4.03.0.tar.gz

./configure   && make world  && make opt&& make install

yum install ctags-etags

wgethttp://www.seas.upenn.edu/~bcpierce/unison//download/releases/unison-2.48.4/unison-2.48.4.tar.gz

make UISTYLE=text THREADS=true

scrpits

server 1

#/bin/bash

ip2="192.168.101.43:30022"

src2="/home/jiangwb/zero/"

dst2="/home/jiangwb/zero/"

/usr/local/bin/inotifywait -mrq -e create,delete,modify,move $src2 | while read line; do

/usr/bin/unison -batch $src2 ssh://$ip2/$dst2

echo -n "$line " >> /home/jiangwb/inotify.log

echo `date | cut -d " " -f1-4` >> /home/jiangwb/inotify.log

done

socket 绑定端口。

通过 socket 进行通讯     unison -socket port 

不安全。。。。。。。。。

可以使用 ssh 还是要使用 ssh  

-fastcheck

你可能感兴趣的:(unison 安装)