Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After updating from 4.6.3 (2.0.9) to 4.6.3 (2.0.10) or 4.6.4 (2.0.10), all completed tasks disappeared. #141

Closed
ivan-yu opened this issue Apr 30, 2024 · 16 comments

Comments

@ivan-yu
Copy link

ivan-yu commented Apr 30, 2024

There are a lot of errors opening categories.json and fastresume files when using Libtorrent 2.0.10

Below nox has errors
https://github.com/userdocs/qbittorrent-nox-static/releases/download/release-4.6.3_v2.0.10/aarch64-qbittorrent-nox

Below nox has no error
https://github.com/userdocs/qbittorrent-nox-static/releases/download/release-4.6.3_v2.0.9/aarch64-qbittorrent-nox

(N) 2024-04-28T16:29:05 - qBittorrent v4.6.4 started
(N) 2024-04-28T16:29:05 - Using config directory: /usr/local/AppCentral/qbittorrent-native/home/.config/qBittorrent
(N) 2024-04-28T16:29:05 - qBittorrent termination initiated
(N) 2024-04-28T16:29:05 - qBittorrent is now ready to exit
(N) 2024-04-28T16:29:05 - qBittorrent v4.6.4 started
(N) 2024-04-28T16:29:05 - Using config directory: /usr/local/AppCentral/qbittorrent-native/home/.config/qBittorrent
(N) 2024-04-28T16:29:05 - Trying to listen on the following list of IP addresses: "0.0.0.0:49162,[::]:49162"
(I) 2024-04-28T16:29:05 - Peer ID: "-qB4640-"
(I) 2024-04-28T16:29:05 - HTTP User-Agent: "qBittorrent/4.6.4"
(I) 2024-04-28T16:29:05 - Distributed Hash Table (DHT) support: ON
(I) 2024-04-28T16:29:05 - Local Peer Discovery support: ON
(I) 2024-04-28T16:29:05 - Peer Exchange (PeX) support: ON
(I) 2024-04-28T16:29:05 - Anonymous mode: ON
(I) 2024-04-28T16:29:05 - Encryption support: FORCED
(W) 2024-04-28T16:29:05 - Failed to load Categories. File size exceeds limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.
config/qBittorrent/categories.json". File size: 548320867016. Size limit: 1048576
(I) 2024-04-28T16:29:05 - Successfully listening on IP. IP: "127.0.0.1". Port: "TCP/49162"
(I) 2024-04-28T16:29:05 - Successfully listening on IP. IP: "127.0.0.1". Port: "UTP/49162"
(I) 2024-04-28T16:29:05 - Successfully listening on IP. IP: "192.168.1.4". Port: "TCP/49162"
(I) 2024-04-28T16:29:05 - Successfully listening on IP. IP: "192.168.1.4". Port: "UTP/49162"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "14ee1e4c0bd612f786393376e94ff872b6e87cfa". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/14ee1e4c0bd612f786393376e94ff872b6e87
cfa.fastresume". File size: 548318599328. Size limit: 104857600"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "2df9db306f21320a986eb695cb9f63044b618140". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/2df9db306f21320a986eb695cb9f63044b618
140.fastresume". File size: 548318599328. Size limit: 104857600"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "89014345d130b47c1c0a870083fdd73206b09288". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/89014345d130b47c1c0a870083fdd73206b09
288.fastresume". File size: 548318599328. Size limit: 104857600"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "5c1429081a586f813b32ce5dcba9d646500b7d61". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/5c1429081a586f813b32ce5dcba9d646500b7
d61.fastresume". File size: 548318599328. Size limit: 104857600"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "0725c0afca67e94f7bca31636a95caa691391ada". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/0725c0afca67e94f7bca31636a95caa691391
ada.fastresume". File size: 548318599328. Size limit: 104857600"
(C) 2024-04-28T16:29:05 - Failed to resume torrent. Torrent: "195ff0aab50e90bde03cde6c608206e7c21e273e". Reason: "File size exceeds
limit. File: "/usr/local/AppCentral/qbittorrent-native/home/.local/share/qBittorrent/BT_backup/195ff0aab50e90bde03cde6c608206e7c21e2
73e.fastresume". File size: 548318599328. Size limit: 104857600"


@ivan-yu
Copy link
Author

ivan-yu commented Apr 30, 2024

Please refer to below linked issue
qbittorrent/qBittorrent#20772

@userdocs

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@userdocs

This comment was marked as resolved.

@userdocs

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@userdocs

This comment was marked as resolved.

@ivan-yu

This comment was marked as resolved.

@userdocs

This comment was marked as resolved.

@userdocs
Copy link
Owner

userdocs commented May 9, 2024

Edit: This is the main answer you need if you come across this issue, the other comments are noisy. The thread was trimmed down/hidden to be more directly helpful to future readers.

This stuff is all above my paygrade. As said to discuss technical aspects you need to use one of their communication channels, like mailing lists.

As far as I understand it it's not the fallback failing but rather the kernel appearing to support statx because it is using the expected syscall for something else so returning some nonsense when used, evidenced via strace.

So I have some options to consider.

1: Very kindly, I was provided a patch to disable these newer calls on older devices by the applications https://sprunge.us/Hzz1iT but I'll still have to work out how to best implement it.

/*
 * fix for broken synology-kernel NAS devices that stole a bunch of syscall
 * numbers for their own MSDOS emulation purposes. link into application
 * to block SYS_statx and all newer/later syscalls with seccomp. */

#include <stddef.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/syscall.h>
#include <errno.h>

#include <sys/prctl.h>
#include <linux/seccomp.h>
#include <linux/filter.h>

__attribute__((__constructor__))
static void fix_synology(void)
{
	struct sock_filter filter[4];
	struct sock_fprog prog = {
		.len = sizeof filter / sizeof *filter,
		.filter = filter,
	};

	filter[0] = (struct sock_filter)BPF_STMT(BPF_LD|BPF_W|BPF_ABS, offsetof(struct seccomp_data, nr));
	filter[1] = (struct sock_filter)BPF_JUMP(BPF_JMP|BPF_JGE|BPF_K, SYS_statx, 0, 1);
	filter[2] = (struct sock_filter)BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ERRNO|ENOSYS);
	filter[3] = (struct sock_filter)BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ALLOW);

	prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0);
	if (syscall(SYS_seccomp, SECCOMP_SET_MODE_FILTER, 0, &prog)) abort();
}

2: build using older musl before v1.2.5.

But as of right now, this is an upstream issue I cannot fix directly, all I can do it work around it.

@userdocs
Copy link
Owner

userdocs commented May 9, 2024

Please also remember the glibc version failed as well. This is not a musl specific issue.

@ivan-yu
Copy link
Author

ivan-yu commented May 9, 2024

I will provide this information to Asus NAS engineer as well to investigate their kernel, thank you for the explanation.

@userdocs
Copy link
Owner

I am closing this as an issue as it's not an issue here and if there will be a solution I will introduce it via a separate repo.

@userdocs userdocs pinned this issue May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
Repository owner deleted a comment from ivan-yu May 18, 2024
@userdocs userdocs unpinned this issue May 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants