Пример #1
0
 def statvfs(self):
     ALLOCATION_UNIT_SIZE = 4 * 1024 * 1024
     space_usage = self._clientv2.users_get_space_usage()
     allocation = (space_usage.allocation.get_individual()
                   if space_usage.allocation.is_individual() else
                   space_usage.allocation.get_team()).allocated
     return quick_container(f_frsize=ALLOCATION_UNIT_SIZE,
                            f_blocks=allocation // ALLOCATION_UNIT_SIZE,
                            f_bavail=(allocation - space_usage.used) // ALLOCATION_UNIT_SIZE)
Пример #2
0
 def statvfs(self):
     return quick_container(f_frsize=2**16,
                            f_blocks=2**32 - 1,
                            f_bavail=2**32 - 1)