My YunoHost server
Hardware: VPS bought online
YunoHost version: YunoHost 11.2.4 (stable)
I have access to my server : All of these: Through SSH | through the webadmin | direct access via keyboard / screen | …
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : No.
Description of my issue
Hi, I encounter this error, when I played the following video ( size >1G, stored in S3 object storage )
warn[2023/10/3 23:52:59] Warning in tracker.
{
"err": {
"stack": "Error: Unknown infoHash db66ee343cd6608c4aabc1ee35a8991df96367c9 requested by ip 172.69.214.XXX\n at Server.<anonymous> (/var/www/peertube/dist/server/controllers/tracker.js:56:20)\n at Generator.next (<anonymous>)\n at fulfilled (/var/www/peertube/node_modules/tslib/tslib.js:164:62)\n at runMicrotasks (<anonymous>)\n at processTicksAndRejections (node:internal/process/task_queues:96:5)",
"message": "Unknown infoHash db66ee343cd6608c4aabc1ee35a8991df96367c9 requested by ip 172.69.214.XXX"
}
}
I have set the upload video size to 50MB. This video size more than 1G, but it still successfully uploaded(I see that file with 1G size in the S3), but it cannot be loaded. Other video can load and play without any problem.
I was told that: my s3 proxy doesn’t seem to support the byte range request from your web browser. Ensure it correctly forwards Range
HTTP header to your S3 provider
But I don’t know how to forwards Range
HTTP header to your S3 provider.
For byte range request, I think you mean to use “fetch byte-range from an object”
Does anyone know how to “correctly forwards Range
HTTP header to my Wasabi object storage”?
I did the following:
I have found the settings mentioned here and come up with the follow config to added to peertube ngixn config.
location @s3 {
# limit_except GET OPTIONS HEAD {
# deny all;
# }
resolver 8.8.8.8;
# proxy_set_header Host https://qien.tv;
# proxy_set_header Connection '';
# proxy_set_header Authorization '';
proxy_force_ranges on;
proxy_http_version 1.1;
proxy_set_header Range $slice_range;
# proxy_hide_header Set-Cookie;
# proxy_hide_header 'Access-Control-Allow-Origin';
# proxy_hide_header 'Access-Control-Allow-Methods';
# proxy_hide_header 'Access-Control-Allow-Headers';
proxy_hide_header x-amz-id-2;
proxy_hide_header x-amz-request-id;
proxy_hide_header x-amz-meta-server-side-encryption;
proxy_hide_header x-amz-server-side-encryption;
proxy_hide_header x-amz-bucket-region;
proxy_hide_header x-amzn-requestid;
# proxy_ignore_headers Set-Cookie;
proxy_pass_request_headers on;
proxy_pass $s3_backend$uri;
proxy_intercept_errors off;
proxy_cache tubecache;
proxy_cache_valid 48h;
proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504;
proxy_cache_lock on;
expires 1y;
add_header Cache-Control public;
add_header 'Access-Control-Allow-Origin' '*'; # switching these to
# proxy_set_header doesn't help
add_header Access-Control-Allow-Methods 'GET, OPTIONS, HEAD';
add_header Access-Control-Allow-Headers 'Range,DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type';
add_header X-Cache-Status $upstream_cache_status;
}
I tried curl 'https://media.tube.tchncs.de/videos/eb0a8a13-cc07-43c4-97e9-01aa177790dc-720.mp4' -X OPTIONS -H 'Access-Control-Request-Method: GET' -H 'Access-Control-Request-Headers: range,user-agent' -H 'Origin: https://tube.tchncs.de'
this with my url:
curl ‘https://cdn.qien.tv/qienhls/9237b7be-67cd-406a-9c48-410553a0ff68/738ec598-7baf-426e-b107-258d7a4787d2-576-fragmented.mp4’ -X OPTIONS -H ‘Access-Control-Request-Method: GET’ -H ‘Access-Control-Request-Headers: range,user-agent’ -H ‘Origin: https://cdn.qien.tv’
But it returns with nothing.
Does anyone know how to “correctly forwards Range
HTTP header to my Wasabi object storage”?