0x676e67 / thunder

Synology NAS thunder run on Linux

Home Page:https://nas.xunlei.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

运行不起来 怎么解决?

jigu168 opened this issue · comments

root@OpenWrt:/tmp/upload# xunlei launcher
ERROR 2023-08-19 15:02:27: [XunleiBackendServer] error: [XunleiBackendServer] Mount /opt/xunlei/downloads to /xunlei failed
INFO 2023-08-19 15:02:27: [XunleiLauncher] All services have been complete
root@OpenWrt:/tmp/upload# sudo
-bash: sudo: command not found
root@OpenWrt:/tmp/upload# su
-bash: su: command not found
root@OpenWrt:/tmp/upload# xunlei launcher
INFO 2023-08-19 15:09:53: [XunleiLauncher] Start Xunlei Pannel UI, listening on 0.0.0.0:5055
ERROR 2023-08-19 15:09:53: [XunleiBackendServer] error: [XunleiBackendServer] Mount /opt/xunlei/downloads to /xunlei failed
INFO 2023-08-19 15:09:53: [XunleiLauncher] All services have been complete

把/etc/init.d/xunlei配置文件内容替换为下面:

#!/bin/sh /etc/rc.common

START=99
USE_PROCD=1
PROG=/usr/bin/xunlei

get_config() {
	config_get_bool enabled $1 enabled 0
	config_get_bool debug $1 debug 0
	config_get host $1 host "0.0.0.0"
	config_get port $1 port 5051
	config_get auth_user $1 auth_user ''
	config_get auth_password $1 auth_password ''
	config_get config_path $1 config_path "/opt/xunlei"
	config_get download_path $1 download_path "/opt/xunlei/downloads"
	config_get mount_bind_download_path $1 mount_bind_download_path "/xunlei"
}

start_service() {
	config_load xunlei
	config_foreach get_config xunlei
	[ $enabled -ne 1 ] && return 1

	if [ ! -d "/usr/share/xunlei/target/var" ]; then
		path="/usr/share/xunlei/target/host/etc"
		mkdir -p $path
		id=$(cat /proc/sys/kernel/random/uuid | cut -c1-7)
		echo "unique=\"synology_${id}_720+\"" >$path/synoinfo.conf
		chmod 755 $path/synoinfo.conf

		path="/usr/share/xunlei/target/host/usr/syno/synoman/webman/modules"
		mkdir -p $path
		mkdir -p /usr/syno/synoman/webman/modules
		echo -e '#!/usr/bin/env sh\necho OK' >$path/authenticate.cgi
		chmod 755 $path/authenticate.cgi
	fi

	if [ -f /etc/synoinfo.conf ]; then
		rm /etc/synoinfo.conf
	fi

	if [ -f /usr/syno/synoman/webman/modules/authenticate.cgi ]; then
		rm /usr/syno/synoman/webman/modules/authenticate.cgi
	fi

	rm -rf /var/packages/pan-xunlei-com
	mkdir -p /var/packages/pan-xunlei-com
	ln -s /usr/share/xunlei/target /var/packages/pan-xunlei-com
	ln -s /usr/share/xunlei/target/host/etc/synoinfo.conf /etc/synoinfo.conf
	ln -s /usr/share/xunlei/target/host/usr/syno/synoman/webman/modules/authenticate.cgi /usr/syno/synoman/webman/modules/authenticate.cgi

	if [ ! -d "$config_path" ]; then
		mkdir -p $config_path
	fi

	if [ ! -d "$download_path" ]; then
		mkdir -p $download_path
	fi

	if [ ! -d "$mount_bind_download_path" ]; then
		mkdir -p $mount_bind_download_path
	fi
	
	args="--host $host --port $port --config-path $config_path --download-path $download_path --mount-bind-download-path $mount_bind_download_path"

	if [ -n "$auth_user" ] && [ -n "$auth_password" ]; then
		args="$args -U $auth_user -W $auth_password"
	fi

	if [ $debug -ne 0 ]; then 
		args="$args --debug"
	fi
	
	procd_open_instance
	procd_set_param command /bin/sh -c "$PROG launcher $args >>/var/log/xunlei.log 2>&1"
	procd_set_param stdout 0
	procd_set_param stderr 0
	procd_set_param pidfile /var/run/xunlei.pid
	procd_close_instance
}

service_triggers() {
	procd_add_reload_trigger "xunlei"
}

reload_service() {
	stop
	for i in $(seq 1 60); do
		if [ -z "$(ps -ef | grep xunlei | grep -v grep | grep -v $$ | grep -v '/etc/rc.common' | grep -v '/sbin/service' | grep -v '/sbin/luci-reload')" ]; then
			break
		fi
		sleep 1
	done
	start
}

然后执行 service xunlei disable && service xunlei enable

把/etc/init.d/xunlei配置文件内容替换为下面:

#!/bin/sh /etc/rc.common

START=99
USE_PROCD=1
PROG=/usr/bin/xunlei

get_config() {
	config_get_bool enabled $1 enabled 0
	config_get_bool debug $1 debug 0
	config_get host $1 host "0.0.0.0"
	config_get port $1 port 5051
	config_get auth_user $1 auth_user ''
	config_get auth_password $1 auth_password ''
	config_get config_path $1 config_path "/opt/xunlei"
	config_get download_path $1 download_path "/opt/xunlei/downloads"
	config_get mount_bind_download_path $1 mount_bind_download_path "/xunlei"
}

start_service() {
	config_load xunlei
	config_foreach get_config xunlei
	[ $enabled -ne 1 ] && return 1

	if [ ! -d "/usr/share/xunlei/target/var" ]; then
		path="/usr/share/xunlei/target/host/etc"
		mkdir -p $path
		id=$(cat /proc/sys/kernel/random/uuid | cut -c1-7)
		echo "unique=\"synology_${id}_720+\"" >$path/synoinfo.conf
		chmod 755 $path/synoinfo.conf

		path="/usr/share/xunlei/target/host/usr/syno/synoman/webman/modules"
		mkdir -p $path
		mkdir -p /usr/syno/synoman/webman/modules
		echo -e '#!/usr/bin/env sh\necho OK' >$path/authenticate.cgi
		chmod 755 $path/authenticate.cgi
	fi

	if [ -f /etc/synoinfo.conf ]; then
		rm /etc/synoinfo.conf
	fi

	if [ -f /usr/syno/synoman/webman/modules/authenticate.cgi ]; then
		rm /usr/syno/synoman/webman/modules/authenticate.cgi
	fi

	rm -rf /var/packages/pan-xunlei-com
	mkdir -p /var/packages/pan-xunlei-com
	ln -s /usr/share/xunlei/target /var/packages/pan-xunlei-com
	ln -s /usr/share/xunlei/target/host/etc/synoinfo.conf /etc/synoinfo.conf
	ln -s /usr/share/xunlei/target/host/usr/syno/synoman/webman/modules/authenticate.cgi /usr/syno/synoman/webman/modules/authenticate.cgi

	if [ ! -d "$config_path" ]; then
		mkdir -p $config_path
	fi

	if [ ! -d "$download_path" ]; then
		mkdir -p $download_path
	fi

	if [ ! -d "$mount_bind_download_path" ]; then
		mkdir -p $mount_bind_download_path
	fi
	
	args="--host $host --port $port --config-path $config_path --download-path $download_path --mount-bind-download-path $mount_bind_download_path"

	if [ -n "$auth_user" ] && [ -n "$auth_password" ]; then
		args="$args -U $auth_user -W $auth_password"
	fi

	if [ $debug -ne 0 ]; then 
		args="$args --debug"
	fi
	
	procd_open_instance
	procd_set_param command /bin/sh -c "$PROG launcher $args >>/var/log/xunlei.log 2>&1"
	procd_set_param stdout 0
	procd_set_param stderr 0
	procd_set_param pidfile /var/run/xunlei.pid
	procd_close_instance
}

service_triggers() {
	procd_add_reload_trigger "xunlei"
}

reload_service() {
	stop
	for i in $(seq 1 60); do
		if [ -z "$(ps -ef | grep xunlei | grep -v grep | grep -v $$ | grep -v '/etc/rc.common' | grep -v '/sbin/service' | grep -v '/sbin/luci-reload')" ]; then
			break
		fi
		sleep 1
	done
	start
}

然后执行 service xunlei disable && service xunlei enable

老大 我有个问题咨询你 我N1增加了一个wan进行拨号,docker的网心云就走wan口了 不是原来的lan 这个怎么解决 就是原来获得的是lan口的局域网地址,现在docker的网卡变成了wan 的拨号地址 然后没办法走unup了

r
INFO 2023-08-19 16:22:59: [XunleiLauncher] All services have been complete
root@OpenWrt:~# service xunlei disable
-bash: /etc/init.d/xunlei: Permission denied

改完变成这样了

我手动建立目录之后变成这样了
root@OpenWrt:~# xunlei launcher
INFO 2023-08-19 16:35:54: [XunleiBackendServer] Mount /opt/xunlei/downloads to /xunlei succeeded
INFO 2023-08-19 16:35:54: [XunleiBackendServer] Start Xunlei Backend Server
INFO 2023-08-19 16:35:54: [XunleiLauncher] Start Xunlei Pannel UI, listening on 0.0.0.0:5055
ERROR 2023-08-19 16:35:54: [XunleiBackendServer] error: No such file or directory (os error 2)
INFO 2023-08-19 16:35:54: [XunleiLauncher] All services have been complete

感觉你配置有问题,卸载重装看看

是那个网络接口的问题 我删除了多余的wan口 现在运行正常了 可问题是web页面打不开啊
http://192.168.31.100:5055/webman/3rdparty/pan-xunlei-com/index.cgi/ 打开这就是白页

大哥你这玩意和docker冲突么 docker服务无法启动了

空白就是内核过低,用不了

docker其实是没关系的

没有错误了但是进不去web页面http://[192.168.31.100:5055/webman/3rdparty/pan-xunlei-com/index.cgi/] 打开空白
能找到原因么?

INFO 2023-08-19 21:48:53: [Asset] Real path of the symlink /lib/ld-linux-aarch64.so.1: /lib/aarch64-linux-gnu/ld-linux-aarch64.so.1
INFO 2023-08-19 21:48:53: [Asset] LD_LIBRARY_PATH=/lib/aarch64-linux-gnu
INFO 2023-08-19 21:48:53: [XunleiLauncher] Start Xunlei Pannel UI, listening on 0.0.0.0:5055
INFO 2023-08-19 21:48:53: [Asset] Real path of the symlink /lib/ld-linux-aarch64.so.1: /lib/aarch64-linux-gnu/ld-linux-aarch64.so.1
INFO 2023-08-19 21:48:53: [Asset] LD_LIBRARY_PATH=/lib/aarch64-linux-gnu
INFO 2023-08-19 21:48:53: [XunleiBackendServer] Mount /opt/xunlei/downloads to /xunlei succeeded
INFO 2023-08-19 21:48:53: [XunleiBackendServer] Start Xunlei Backend Server
INFO 2023-08-19 21:48:53: [XunleiBackendServer] Xunlei Backend Server PID: 10182
2023-08-19 13:49:07.714827 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 214.8ms - 200
2023-08-19 13:49:08.026404 UTC - GET /favicon.ico - 88.6us - 307
2023-08-19 13:49:08.042352 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 218.0ms - 200
2023-08-19 13:49:15.666267 UTC - GET / - 192.5us - 307
2023-08-19 13:49:15.681759 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 208.4ms - 200
2023-08-19 13:49:15.989039 UTC - GET /favicon.ico - 204.0us - 307
2023-08-19 13:49:16.110281 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 210.4ms - 200
2023-08-19 13:49:26.301643 UTC - GET / - 183.9us - 307
2023-08-19 13:49:26.313826 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 211.6ms - 200
2023-08-19 13:49:26.782610 UTC - GET /favicon.ico - 199.7us - 307
2023-08-19 13:49:26.799813 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 223.0ms - 200
2023-08-19 13:49:36.855517 UTC - GET /favicon.ico - 154.1us - 307
2023-08-19 13:49:36.869388 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 209.5ms - 200
2023-08-19 13:49:37.358130 UTC - GET /favicon.ico - 263.5us - 307
2023-08-19 13:49:37.369494 UTC - GET /webman/3rdparty/pan-xunlei-com/index.cgi/ - 208.2ms - 200

空白就是内核过低,用不了
6.1.32-flippy-83+ 这个内核也不行么 我看恩山帖子下面有人说N1运行了

确实看不出来什么,清浏览器缓存,要么换docker跑

空白就是内核过低,用不了

内核要求什么版本?

没有问题,纯lede编译:https://github.com/gngpp/Actions-OpenWrt
image
image
image