Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 04 Jul 2020 15:59:12 +0000
From:      bugzilla-noreply@freebsd.org
To:        testing@freebsd.org
Subject:   [Bug 247761] tests/sys/audit/file-attribute-modify leaves chflags files behind; kyua can't clean up directories
Message-ID:  <bug-247761-32464@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D247761

            Bug ID: 247761
           Summary: tests/sys/audit/file-attribute-modify leaves chflags
                    files behind; kyua can't clean up directories
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Many People
          Priority: ---
         Component: tests
          Assignee: testing@freebsd.org
          Reporter: ngie@FreeBSD.org

tests/sys/audit/file-attribute-modify.c creates multiple files and director=
ies,
adds chflags SF_IMMUTABLE and UF_OFFLINE to the files, and relies on kyua to
clean up the files/directories.

kyua does the best it can to clean up the directory, but it can't remove fi=
les
with SF_IMMUTABLE on them.

The cleanup routine needs to un-SF_IMMUTABLE the file so kyua can clean up =
the
file/directory.

Excerpt from [1]:

Hi,

I recently stumbled across undeletable files that are generated by kyua test
runs,
for example

-rwxr-xr-x  1 root  wheel  0 May  9 13:10
/tmp/kyua.aB4q62/8676/work/fileforaudit

I haven't yet identified the test that generate those files, but it is
impossible
to delete them. I have clear_tmp_enable=3D"YES" set in the /etc/rc.conf, bu=
t=20
on every boot the system argues that these file aren't deletable.=20
I tried to 'rm -rf' them by hand but, even this wasn't possible. I have loo=
ked
for
any extend attributes, but I didn't find any.

Has anyone an idea how this is possible and may how these files can be dele=
ted?

--Gordon

Excerpt from [2]:

The issue is tests/sys/audit/file-attribute-modify.c , based on the file
present that can=E2=80=99t be deleted. Can you please provide more informat=
ion about
the test run in a PR (I see how it can leave files behind, but I want to ma=
ke
sure it is what I think it is, first)?
Cheers,
-Enji

1. https://lists.freebsd.org/pipermail/freebsd-current/2020-June/076436.html
2. https://lists.freebsd.org/pipermail/freebsd-current/2020-July/076449.html

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-247761-32464>