Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a samba server exporting homes. Usermanagement/authentication is done via ldap (openldap to be specific). Now I want those users to have a filesystem quota. As far as i understand the best way would be to implement them in the underlying filesystem, with the standard linux quota tools ("quota"). Now since all other user management is done in ldap, also the quota information should be in ldap.

The only way of automatic connection of quota info in ldap with the filesystem (that I have found) is via pam_setquota. But since the users won't log in as linux users, I guess this will be useless. So I could write a little script that generates the quota files from information it finds in ldap. This script would run regularly via cron. But this seems a little hackish to me (allthough I have seen this work well in practise). I was wondering if anyone has a better (or different :)) idea for this task.

share|improve this question
One Question!!! If you don't let user log in. How to make user's home directory? Since you use ldap for authentication I guess you may use pam_mkhomedir for automatically making home directory. Anyway this is good question. –  user146788 Nov 23 '12 at 18:48
Hm, I have not thought about that. I guess this calls for another script ... which makes me think that the whole thing is maybe a bit hackish and user management scripts can't be avoided. Still I wonder why there are no readymade scripts for this packaged. Maybe just too easy? –  Isaac Nov 25 '12 at 18:10
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.