borgbackup/borg

ACLs on FreeBSD: use ACL_TEXT_NUMERIC_IDS for better speed

開放

#9,144 建立於 2025年11月4日

 (2 則留言) (0 個反應) (0 位負責人)Python (732 個分叉)batch import
cmd: createfilesystemhelp wantedos: bsd

倉庫指標

星標
 (10,086 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

https://man.freebsd.org/cgi/man.cgi?query=acl_to_text&sektion=3&apropos=0&manpath=FreeBSD+14.3-RELEASE+and+Ports

We can:

  • get the uid / gid instead of the names: always use ACL_TEXT_NUMERIC_IDS
  • avoid a gazillion more or less expensive, uncached lookups inside "libacl" for the user/group names (especially for samba / winbind this can be slow)
  • replace these by cached lookups inside borg, using a LRU caches to map uids to user names and to map gids to group names (uid2user and gid2group already have caching).
  • replace the uid / gid in the ACL by some custom code (see linux.pyx)

Adding this feature needs a FreeBSD developer, who can develop and test it.

The Linux code in master branch already uses a similar method. #9143

貢獻者指南