]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - FAQ.md
Allow only admin to download a video
[github/Chocobozzz/PeerTube.git] / FAQ.md
CommitLineData
3266ad7c
C
1# FAQ
2
2db6f2b0
RK
3<!-- Table of contents generated with DocToc: https://github.com/thlorenz/doctoc -->
4<!-- START doctoc generated TOC please keep comment here to allow auto update -->
5<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
6
7
f95cb03a 8- [Why did you create PeerTube?](#why-did-you-create-peertube)
073279d5 9- [I don't like the name "PeerTube"](#i-dont-like-the-name-peertube)
2db6f2b0
RK
10- [If nobody watches a video, is it seeded?](#if-nobody-watches-a-video-is-it-seeded)
11- [What is WebSeed?](#what-is-webseed)
12- [If a client requests each chunk of a video through HTTP, will the server be overloaded?](#if-a-client-requests-each-chunk-of-a-video-through-http-will-the-server-be-overloaded)
13- [Will an index of all the videos of servers you follow be too large for small servers?](#will-an-index-of-all-the-videos-of-servers-you-follow-be-too-large-for-small-servers)
049539eb 14- [Which container formats can I use for the videos I want to upload?](#which-container-formats-can-i-use-for-the-videos-i-want-to-upload)
861a188c 15- [I want to change my domain name. How can I do that?](#i-want-to-change-my-domain-name-how-can-i-do-that)
8f6e554b 16- [Why do we have to put our Twitter username in PeerTube configuration?](#why-do-we-have-to-put-our-twitter-username-in-peertube-configuration)
861a188c 17- [How are video views counted?](#how-are-video-views-counted)
2db6f2b0 18- [Should I have a big server to run PeerTube?](#should-i-have-a-big-server-to-run-peertube)
bd8ab662 19- [Can I seed videos with my classic BitTorrent client (Transmission, rTorrent...)?](#can-i-seed-videos-with-my-classic-bittorrent-client-transmission-rtorrent)
97b72ed1 20- [Why host on GitHub and Framagit?](#why-host-on-github-and-framagit)
2db6f2b0
RK
21- [Are you going to use the Steem blockchain?](#are-you-going-to-use-the-steem-blockchain)
22- [Are you going to support advertisements?](#are-you-going-to-support-advertisements)
23- [What is "creation dynamic" and why not modify it?](#what-is-creation-dynamic-and-why-not-modify-it)
e2dc00a8 24- [I have found a security vulnerability in PeerTube. Where and how should I report it?](#i-have-found-a-security-vulnerability-in-peertube-where-and-how-should-i-report-it)
861a188c 25- [Does PeerTube ensure federation compatibility with previous version?](#does-peertube-ensure-federation-compatibility-with-previous-version)
2db6f2b0
RK
26
27<!-- END doctoc generated TOC please keep comment here to allow auto update -->
28
f95cb03a
RK
29## Why did you create PeerTube?
30
31We can't build a FOSS video streaming alternative to YouTube, Dailymotion,
32Vimeo... with centralized software. One organization alone may not have
33enough money to pay for bandwidth and video storage of its servers.
34
35Our stance is that only a decentralized network of servers can provide an
36acceptable answer to technical issues (bandwidth, transcoding expenses, etc.)
37and social answers (need for a particular moderation policy, preserving
38content, etc.).
39
40While a paragraph is not enough to answer all these problems, PeerTube has
861a188c 41very early prided itself on using a contributory design, both for creating
f95cb03a 42communities as federated nodes (as [Mastodon](https://joinmastodon.org/) for
861a188c 43example), and for seeding videos (instances can seed each other's videos). But that's not
f95cb03a
RK
44enough because one video could become popular and overload the server. That is
45why we need to use a P2P protocol to limit the server load. Thanks to
46[WebTorrent](https://github.com/feross/webtorrent), we can use BitTorrent
47inside most modern web browsers, and users become seeds as the video gets
48more viewers.
49
50
073279d5
C
51## I don't like the name "PeerTube"
52
53PeerTube is just the name of the software. You can install it on your
c9e96ead 54server, and choose a name you want. For example, [this instance](https://framatube.org/)
073279d5
C
55is named "Framatube".
56
97b72ed1 57
343ad675 58## If nobody watches a video, is it seeded?
3266ad7c 59
e755a63a
BB
60Yes, the origin server always seeds videos uploaded on it thanks to
61[Webseed](http://www.bittorrent.org/beps/bep_0019.html).
7cf88d09 62It can also be helped by other servers using [redundancy](https://docs.joinpeertube.org/contribute-architecture?id=redundancy-between-instances).
3266ad7c
C
63
64
65## What is WebSeed?
66
e755a63a
BB
67It is a BitTorrent extension that allows a server to seed a file through HTTP.
68It just needs to statically serve a file, then the clients will request chunks
69with a `Content-Range` HTTP header.
3266ad7c
C
70
71
e755a63a 72## If a client requests each chunk of a video through HTTP, will the server be overloaded?
3266ad7c 73
d4301a6c 74Not really. Reverse proxies like Nginx handle static file requests very well. In my tests, it can send chunks at 10MB/s without consuming more than 5% CPU on a very small VPS.
3266ad7c
C
75
76
e755a63a 77## Will an index of all the videos of servers you follow be too large for small servers?
3266ad7c 78
d4301a6c
MVB
79In our benchmarks, 1,000,000 videos consume around 2GB of PostgreSQL storage.
80We think that is acceptable for a video platform.
3266ad7c
C
81
82
049539eb 83## Which container formats can I use for the videos I want to upload?
3266ad7c 84
7b293f28
RK
85WEBM, MP4 or OGV videos are supported by default (they are streamable formats),
86but instance administrators can additionally enable support for MKV, MOV, AVI
87and FLV formats when transcoding is enabled on their instance.
3266ad7c
C
88
89
bd8ab662 90## I want to change my domain name, how can I do that?
3266ad7c 91
7cf88d09 92It's not officially supported, but you can try the `update-host` script: https://docs.joinpeertube.org/maintain-tools?id=update-hostjs
588d837c 93
bd8ab662 94
d4301a6c 95## Why do we have to put our Twitter username in the PeerTube configuration?
8f6e554b
C
96
97You don't have to: we set a default value if you don't have a Twitter account.
98We need this information because Twitter requires an account for links share/videos embed on their platform.
99
100
d4301a6c 101## How are video views counted?
8f6e554b 102
5003a1c9 103Your web browser sends a view to the server after 30 seconds of playback. If a video is less than 30 seconds in length, a view is sent after 75% of the video. After giving a view, that IP address cannot add another view in the next hour.
8f6e554b
C
104Views are buffered, so don't panic if the view counter stays the same after you watched a video.
105
106
588d837c
C
107## Should I have a big server to run PeerTube?
108
a5c9fa10 109PeerTube should run happily on a virtual machine with 2 threads/vCPUs, at least 1 Gb of RAM and enough storage for videos. In terms of bandwidth, a lot will depend on which PeerTube instances you federate with and what your relation with them is (more about that below).
2db6f2b0 110
a5c9fa10
MVB
111As a real life example, the PeerTube demonstration server [https://peertube.cpy.re](https://peertube.cpy.re) runs on 2 vCores and 2GB of RAM. Average consumption is:
112 * **CPU**: nginx ~ 20%, peertube ~ 10%, postgres ~ 1%, redis ~ 3%
113 * **RAM**: nginx ~ 6MB, peertube ~ 120MB, postgres ~ 10MB, redis ~ 5MB
588d837c 114
a5c9fa10
MVB
115### CPU
116
6d61da4e 117Except for video transcoding, a PeerTube instance is not CPU bound. Neither Nginx, PeerTube itself, PostgreSQL nor Redis require a lot of computing power. If it were only for those, one could easily get by with just one thread/vCPU.
a5c9fa10
MVB
118
119You will hugely benefit from at least a second thread though, because of transcoding. Transcoding _is_ very cpu intensive. It serves two purposes on a PeerTube instance: it ensures all videos can be played optimally in the web interface, and it generates different resolutions for the same video. PeerTube support for offloading transcoding to other machines is being discussed, but not yet implemented. See https://github.com/Chocobozzz/PeerTube/issues/947 .
120
121### RAM
122
1231 Gb of RAM should be plenty for a basic PeerTube instance, which usually takes at most 150 Mb in RAM. The only reason you might want more would be if you colocate your Redis or PostgreSQL services on a non-SSD system.
124
125### Storage
126
127There are two important angles to storage: disk space usage and sustained read speed.
128
129To make a rough estimate of your disk space usage requirements, you want to know the answer to three questions:
130- What is the total size of the videos you wish to stream?
131- Do you want to enable transcoding? If so, do you want to provide multiple resolutions per video? Try this out with a few videos and you will get an idea of how much extra space is required per video and estimate a multiplication factor for future space allocation.
132- Which sharing mechanisms do you want to enable? Just WebTorrent, or also HLS with p2p? If you want both, this will double your storage needs.
133
134In terms of read speed, you want to make sure that you can saturate your network uplink serving PeerTube videos. This should not be a problem with SSD disks, whereas traditional HDD should be accounted for: typical sustained read rates for [a well tuned system](support/doc/production.md#tcpip-tuning) with a 7200rpm hard disk should hover around 120 MB/s or 960 Mbit/s. The latter should be enough for a typical 1 Gbit/s network uplink.
135
136### Network
137
138A rough estimate of a traditional server's video streaming network capacity is usually quite straightforward. You simply divide your server's available bandwidth by the average bandwidth per stream, and you have an upper bound.
139
140Take a server for example with a 1 Gbit/s uplink for example pushing out 1080p60 streams at 5 Mbit/s per stream. That means the absolute theoretical upper capacity bound is 200 simultaneous viewers if your server's disk i/o can keep up. Expect a bit less in practice.
141
142But what if you need to serve more users? That's where PeerTube's federation feature shines. If other PeerTube instances following yours, chances are they have decided to mirror part of your instance! The feature is called "server redundancy" and caches your most popular videos to help serve additional viewers. While viewers themselves contribute a little additional bandwidth while watching the video in their browsers (mostly during surges), mirroring servers have a much greater uplink and will help your instance with sustained higher concurrent streaming.
143
7cf88d09 144If all your preparations and friends' bandwidth is not enough, you might prefer serving files from a CDN ; see our [remote storage guide](https://docs.joinpeertube.org/admin-remote-storage).
2db6f2b0 145
bd8ab662
C
146## Can I seed videos with my classic BitTorrent client (Transmission, rTorrent...)?
147
148Yes you can, but you won't be able to send data to users that watch the video in their web browser.
7b293f28 149The reason is they connect to peers through WebRTC whereas your BitTorrent client uses classic TCP/UDP.
d4301a6c 150You can check if your BitTorrent client supports WebTorrent in this issue: https://github.com/webtorrent/webtorrent/issues/369
bd8ab662
C
151
152
97b72ed1
RK
153## Why host on GitHub and Framagit?
154
d4301a6c 155The project was initially hosted on GitHub by Chocobozzz. A full migration to [Framagit](https://framagit.org/framasoft/peertube/PeerTube) would be ideal now that Framasoft supports PeerTube, but it would take a lot of time and is an ongoing effort.
97b72ed1
RK
156
157
2db6f2b0
RK
158## Are you going to use the Steem blockchain?
159
160Short answer: no, since like most appchains/votechains, it modifies the dynamic of creation, and as such cannot be integrated into mainline PeerTube. Read more about that in [the dedicated section](#what-is-creation-dynamic-and-why-not-modify-it).
161
162Long answer is that the Steem blockchain goes astray of its promises of fairness and decentralization: the deliberate relaunching of the currency to ensure centralization, and the stake-based voting power, makes manipulation by wealthy users inevitable ([source here](https://decentralize.today/the-ugly-truth-behind-steemit-1a525f5e156)).
163Worse, money generated primarily goes to stakeholders ([source here](https://steemit.com/steemit/@orly/how-the-steem-pyramid-scheme-really-works) ).
164For more information, read the complete whitepaper analysis done by [Tone Vays](https://twitter.com/ToneVays/status/761975587451928576).
165
166## Are you going to support advertisements?
167
168Short answer: no, we don't want advertisers to dictate which content should be financed.
169That would modify the dynamic of creation; as such it cannot be integrated into mainline PeerTube.
170Read more about that in [the dedicated section](#what-is-creation-dynamic-and-why-not-modify-it).
171
172The long answer is probably more subtle. YouTube has shaped generations of video creators by making it easy to place ads;
173but making big money with the platform can be a challenge.
174A typical video ad runs between $.10 and $.30 per 1000 views (as of March 2018).
175More than 70% of video creators use ads as the main way to make money on YouTube, yet less than 3% of video creators make a living out of their YouTube activity (with partnerships and commissions, otherwise counting only ad revenue it drops to 1%).
176Read more about it in the 2018 study by Mathias Bärtl, [*YouTube channels, uploads and views: A statistical analysis of the past 10 years*](https://www.dropbox.com/s/0cq4wtxm83s95t2/10.1177%401354856517736979.pdf?dl=0).
177To the best of our knowledge, small and medium-community creators are better off getting support from their community on platforms such as Liberapay, Tipeee or Patreon.
178Moreover, don't forget that advertisers already pay considering YouTube's large user base; with PeerTube's way smaller user base and refusal of user profiling, a pay-per-view that's lower than YouTube's could only be expected.
179
180## What is "creation dynamic" and why not modify it?
181
182We define creation dynamic as the way any original content, regardless of its monetary value, is created and incentivized.
c9e96ead 183We want to stay neutral by limiting the influence of our platform on authors as much as possible. We are not curators, and want to limit the scope of PeerTube instance owners and administrators' responsibilities to moderation tasks only.
2db6f2b0
RK
184
185If you still want to use a functionality potentially altering that state of things, then you could interface with our upcoming plug-in system, which will be the place to integrate such features in the near future.
186
187With that being said, know that we are not against these features *per se*.
188We are always open to discussion about potential PRs bringing in features, even of that kind. But we certainly won't dedicate our limited resources to develop them ourselves when there is so much to be done elsewhere.
e2dc00a8
RK
189
190## I have found a security vulnerability in PeerTube. Where and how should I report it?
191
192We have a policy for contributions related to security. Please refer to [SECURITY.md](./SECURITY.md)
a8738ec5 193
861a188c 194## Does PeerTube ensure federation compatibility with previous version?
a8738ec5
C
195
196We **try** to keep compatibility with the latest minor version (2.3.1 with 2.2 for example).
197We don't have resources to keep compatibility with other versions.