Limit size of room storage (files and history) in Matrix server
This issue has been migrated from #2315.
Is there any ways to limit size of disk storage (total files and history size on megabytes, stored in server database) per chat room or per user in Matrix server?
guys, put this one on priority. This is just stupid that there is no basic feature to limit disk storage usage, this is literally motivating sysadmins to abandon matrix as a solution for public chats
basic storage control is vital when you want to have a matrix server alongside other services
why is that the case @nihilist001 ?
I assume that this issue is about reducing the amount of storage-space necessary for hosting Matrix-servers, to reduce the cost of maintaining those. So here is what i think about that:
I often share many files with some of my contacts, which basically increase the storage-requirements, of the server that i use, by about 1-10 MB per day. I was also considering to use Matrix to share some game-videos in 4K, but noticed, that that would mean, that the server that i use, would need to have 1 GB of storage or more for each video, even though it would likely become unnecessary to have those videos available in the chat, after those were watched once or a few times (or downloaded). If many people would do this, it could quickly become financially unfeasible to host a Matrix-server with enough storage-space, since those large files would remain even after years.
Simple size-limits per room or account, would cause other issues, and could easily be circumvented. A size-limit for rooms could be circumvented by opening another room, uploading the files there, and linking to it in the original chat-room. Size-limits per account could also interfere with communication (for example: imagine a person saying: "Here is a short video!", after which they try to send the video and then their app responds with: "Error: size-limit reached, please delete old files.") and make usability too complicated for normal people, because it would require that they learn how to manage storage and decide on what to delete. Size-limits per upload could prevent people from uploading large files, which would likely reduce the storage-requirements of the server, but also give people a good reason to simply use a different chat-app instead.
If it would be handled by deleting older files (or the largest files) then people could (unintentionally or intentionally) delete other files by sending many/large files, which would make the availability of files in the chat-history unreliable.
So, here is another suggestion for reducing the amount of storage-space necessary:
A time-limit for messages and files per room, which could be preset to something reasonable, like 15 months or 2 years (enough time for people to check what they did in the previous year). That would make it understandable for people, that messages will only remain available for some time, and how long that time is. Chat-apps are normally used to talk about things "for the moment", not to permanently store or publish information (other systems are much better and easier to use for that), so a time-limit would be a practical solution that reduces (often unused) chat-histories, and thus the necessary storage-space. To (reasonably) ensure that the most-recent messages remain available, even if someone opens a chat only after several months while a short time-limit is set, there could be a minimum number of messages to keep.
An example of such a setting:
Keep messages for*: [forever/10 years/2 years/15 months/3 months]
*: 100 newest messages will always be kept.
There could then be settings for servers, which limit the maximum and minimum time-limit, for keeping messages, that can be set.
yeah dont bother i moved to simplex and they already have that feature there. not like matrix will ever have it anyway, read up on that and do the same : https://forum.hackliberty.org/t/why-we-abandoned-matrix-the-dark-truth-about-user-security-and-safety/224
I assume that this issue is about reducing the amount of storage-space necessary for hosting Matrix-servers, to reduce the cost of maintaining those. So here is what i think about that:
I often share many files with some of my contacts, which basically increase the storage-requirements, of the server that i use, by about 1-10 MB per day. I was also considering to use Matrix to share some game-videos in 4K, but noticed, that that would mean, that the server that i use, would need to have 1 GB of storage or more for each video, even though it would likely become unnecessary to have those videos available in the chat, after those were watched once or a few times (or downloaded). If many people would do this, it could quickly become financially unfeasible to host a Matrix-server with enough storage-space, since those large files would remain even after years.
Simple size-limits per room or account, would cause other issues, and could easily be circumvented. A size-limit for rooms could be circumvented by opening another room, uploading the files there, and linking to it in the original chat-room. Size-limits per account could also interfere with communication (for example: imagine a person saying: "Here is a short video!", after which they try to send the video and then their app responds with: "Error: size-limit reached, please delete old files.") and make usability too complicated for normal people, because it would require that they learn how to manage storage and decide on what to delete. Size-limits per upload could prevent people from uploading large files, which would likely reduce the storage-requirements of the server, but also give people a good reason to simply use a different chat-app instead.
If it would be handled by deleting older files (or the largest files) then people could (unintentionally or intentionally) delete other files by sending many/large files, which would make the availability of files in the chat-history unreliable.
So, here is another suggestion for reducing the amount of storage-space necessary:
A time-limit for messages and files per room, which could be preset to something reasonable, like 15 months or 2 years (enough time for people to check what they did in the previous year). That would make it understandable for people, that messages will only remain available for some time, and how long that time is. Chat-apps are normally used to talk about things "for the moment", not to permanently store or publish information (other systems are much better and easier to use for that), so a time-limit would be a practical solution that reduces (often unused) chat-histories, and thus the necessary storage-space. To (reasonably) ensure that the most-recent messages remain available, even if someone opens a chat only after several months while a short time-limit is set, there could be a minimum number of messages to keep.
An example of such a setting:
Keep messages for*: [forever/10 years/2 years/15 months/3 months]
*: 100 newest messages will always be kept.
There could then be settings for servers, which limit the maximum and minimum time-limit, for keeping messages, that can be set.
do matrix servers use redundancy techniques so they can store files indefinitely?
maybe we need larger corporations to open larger matrix servers so users can add storage there? because matrix itself doesn't have a large amount of corporate support