Gentoo下配置BitTorrent Sync
Pubdate:2013-05-11 15:54:49 Categories: linux 1346 ViewsTags: gentoo, linux
BitTorrent Sync 是一个P2P的文件同步工具。私密性应该比dropbox之类要好。
portage树中还没有。官方overlay也没有。
在layman中加入。
overlays : http://www.gentoo.org/proj/en/overlays/repositories.xml
file:///var/lib/layman/my-list.xml
# cat /var/lib/layman/my-list.xml
<?xml version="1.0" ?>
<repositories version="1.0">
<repo priority="50" quality="experimental" status="unofficial">
<name>btbn</name>
<description>btbn</description>
<homepage>http://git.btbn.de/gentoo-overlay.git</homepage>
<owner>
<email>btbn@btbn.de</email>
</owner>
<source type="git">git://git.btbn.de/gentoo-overlay.git</source>
</repo>
</repositories>
# layman -f -a btbn
# emerge btsync
# cat /etc/conf.d/btsync
# conf.d file for btsync
# User and group daemon runs as
BTSYNC_USER="lq"
BTSYNC_GROUP="lq"
# cat /etc/btsync.conf
{
"device_name": "lq's Laptop",
"listening_port" : 0, // 0 - randomize port
/* storage_path dir contains auxilliary app files
if no storage_path field: .sync dir created in the directory
where binary is located.
otherwise user-defined directory will be used
*/
"storage_path" : "/home/lq/.sync",
// Do not change this, init script relies on it.
"pid_file" : "/run/btsync/btsync.pid",
// Do not enable, updates are managed via portage.
"check_for_updates" : false,
"use_upnp" : true, // use UPnP for port mapping
/* limits in kB/s
0 - no limit
*/
"download_limit" : 0,
"upload_limit" : 0,
/* remove "listen" field to disable WebUI
remove "login" and "password" fields to disable credentials check
*/
"webui" :
{
"listen" : "0.0.0.0:8888",
"login" : "user",
"password" : "password"
}
/* !!! if you set shared folders in config file WebUI will be DISABLED !!!
shared directories specified in config file
override the folders previously added from WebUI.
*/
/*
,
"shared_folders" :
[
{
// use --generate-secret in command line to create new secret
// "secret" : "MY_SECRET_1", // * required field
// "dir" : "/home/user/bittorrent/sync_test", // * required field
// use relay server when direct connection fails
"use_relay_server" : true,
"use_tracker" : true,
"use_dht" : false,
"search_lan" : true,
// enable sync trash to store files deleted on remote devices
"use_sync_trash" : true,
// specify hosts to attempt connection without additional search
"known_hosts" :
[
"192.168.1.2:44444"
]
}
]
*/
// Advanced preferences can be added to config file.
// Info is available in BitTorrent Sync User Guide.
}
# /etc/init.d/btsync start
# rc-update add btsync default
现在可以访问:http://localhost:8888/gui/进行管理了。
目前只在家里的局域网上试了。明天到公司试试远程的速度和穿墙能力如何。
树莓派上要加个软链。
# ln -s /lib/ld-linux-armhf.so.3 /lib/ld-linux.so.3
Comments(1)
BitTorrent Sync HR-HDTV电影同步下载
同步密匙:BHK56Y75XCKI3M5CFEKVBVZ2X7F45AY7T