ajuda: Limitar tamanho de diretório sem uso de quotas
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
ajuda: Limitar tamanho de diretório sem uso de quotas
Pessoal, gostaria que alguém me desse uma luz, por favor, para resolver o seguinte problema: preciso de uma forma de limitar o tamanho de um diretório, mas sem utilizar cotas de grupos e usuário... será que existe uma forma eficaz e prática?
Por exemplo, quero impedir que o diretório X fique com mais de 100MiB, independente de quem tem acesso a ele...
Será que em último caso seria possível criar um usuário somente para controlar o tamanho da pasta X? Será que colocando esse usuário como owner da pasta, e liberando todas as permissões de escrita, quando alguém escrevesse na pasta consumiria a cota desse usuário e assim seria possível impor um limite máximo para uma pasta em particular?
Pessoal, gostaria que alguém me desse uma luz, por favor, para resolver o seguinte problema: preciso de uma forma de limitar o tamanho de um diretório, mas sem utilizar cotas de grupos e usuário... será que existe uma forma eficaz e prática?
Por exemplo, quero impedir que o diretório X fique com mais de 100MiB, independente de quem tem acesso a ele...
Será que em último caso seria possível criar um usuário somente para controlar o tamanho da pasta X? Será que colocando esse usuário como owner da pasta, e liberando todas as permissões de escrita, quando alguém escrevesse na pasta consumiria a cota desse usuário e assim seria possível impor um limite máximo para uma pasta em particular?
According to Google translate, it goes something like this:
Quote:
aid: Limit size of directory without use of quotas
Folks, that someone like me that a light, please, to solve the following problem: need a way to limit the size of a directory, but without using quotas of user groups and ... is there an effective and practical?
For example, I want to prevent the directory X is over 100MiB, regardless of who has access to it ...
Does a last resort would be possible to create a user only to control the size of your X? Does putting the user as owner of the folder, and releasing all the rights of writing, when someone write in the folder consume the quota this user and thus could impose a ceiling for a folder in particular?
It's a lousy translation, but it looks as though gustavolinux would like to use quotas.
help: to limit a folder`s size without using quotas
Friends, could anybody there give me a light, please, to solve the following problem: I need a way to limit the size of a folder, but without using group or user quotas... is there a good solution?
For example, I want to avoid that folder X grows up more than 100MiB, no matters who writes to the folder...
If there is no such way, maybe do you think that it is possible to create a new user account just to control the size of the folder X? I mean to put this new user as the owner of the folder X and allow any access to the folder... Do you think that, if someone writes to the folder, the quota of the new user would be consumed and reach an unbreakable limit?
Folks, I need to limit the size of a folder shared in the network, no matters who have access and write to it... in other words, think about a folder that every user have to
access and possibly write, but the size of this folder has to be under a size limit...
In my concern, there is no configuration mecanism especially made to this task, right? I think that the proper feature should come from the filesystem...
But, anyway, I thought about a solution using group quotas. I guess that when you enable the folder's setgid bit, everything that is copied to that folder becames owned by the folder's group owner. If I create a group of users, let's say named "Control", and put every network user in this group (but as a secondary group - "Control" won't be the main group of no user), do you think that the "Control"s group disk quota (properly configured) will limit the size of the folder (without limiting no user's quota)...
Is there a chance that this idea work? Is there a better choice?
just to give a feedback: a loop device was a really good idea... to every folder that I want to limit its size I create an image of a file system with the right size... []'s
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.