Cache UID/GID for nice speed improvement

Bug #723545 reported by Jan Schmidt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Back In Time
Fix Released
High
Unassigned

Bug Description

Every time pwd.getpwnam/pwd.getpwuid/grp.getgrnam/grp.getgrgid are called, they open /etc/passwd or /etc/group and parse it to get the answer. Since this is done for every file in the backup, it consumes a lot of time. The attached patch caches each UID/GID/username/groupname the first time they are encountered, saving a lot of lookups.

On a full system backup here, it took about 1 hour off a 5 hour backup.

Revision history for this message
Jan Schmidt (thaytan) wrote :
Dan (danleweb)
Changed in backintime:
status: New → Confirmed
importance: Undecided → High
Dan (danleweb)
Changed in backintime:
status: Confirmed → Fix Committed
Germar (germar)
Changed in backintime:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.