免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3178 | 回复: 0
打印 上一主题 下一主题

[samba] 如何使用samba的default_quota? [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-11-16 15:41 |只看该作者 |倒序浏览
smb.conf里面对于vfs可使用一个default_quota的object,请问有朋友用过吗?

若用过,请说明一下,谢谢!

我是没有理解Howto里面的说明。

Howto的说明:

default_quota
This module allows the default quota values, in the windows explorer GUI, to be stored on a Samba-3 server. The challenge is that linux filesystems only store quotas for users and groups, but no default quotas.

Samba returns NO_LIMIT as the default quotas by default and refuses to update them. With this module you can store the default quotas that are reported to a windows client, in the quota record of a user. By default the root user is taken because quota limits for root are typically not enforced.

This module takes 2 parametric entries in the smb.conf file. The default prefix for each is the “default_quota”. This can be overwrittem when you load the module in the vfs modules parameter like this:

vfs objects = default_quota:myprefix


The parametric entries that may be specified for the default_quotas module are:

myprefix:uid
This parameter takes a integer argument that specifies the uid of the quota record that will be used for storing the default user quotas.

The default value is 0 (for root user). An example of use is:

vfs objects = default_quota
default_quota:        uid = 65534

The above demonstrates the case where the myprefix was omitted, thus the default prefix is the name of the module. When a myprefix parameter is specified the above can be re-written like this:

vfs objects = default_quota:myprefix
myprefix:        uid = 65534


myprefix:uid nolimit
This parameter takes a boolean argument that specifies if the stored default quota values also be reported for the user record, or if the value NO_LIMIT should be reported to the windows client for the user specified by the prefix:uid parameter.

The default value is yes (which means to report NO_LIMIT). An example of use is shown here:

vfs objects = default_quota:myprefix
myprefix:        uid nolimit = no


myprefix:gid
This parameter takes an integer argument, it's just like the prefix>:uid but for group quotas. NOTE: group quotas are not supported from the windows explorer.

The default value is 0 (for root group). An example of use is shown here:

vfs objects = default_quota
default_quota:        gid = 65534


myprefix:gid nolimit
This parameter takes a boolean argument, just like the prefix>:uid nolimit but for group quotas. NOTE: group quotas are not supported from the windows explorer.

The default value is yes (which means to report NO_LIMIT). An example of use is shown here:

vfs objects = default_quota
default_quota:        uid nolimit = no


An example of use of multiple parametric specifications is shown here:

...
vfs objects = default_quota:quotasettings
quotasettings:        uid nolimit = no
quotasettings:        gid = 65534
quotasettings:        gid nolimit = no
...
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP