pg_regress cleans up tablespace twice.
Kyotaro Horiguchi <horikyota.ntt@gmail.com>
From: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
To: pgsql-hackers@lists.postgresql.org
Date: 2020-02-19T05:25:19Z
Lists: pgsql-hackers
Attachments
- vcregress_cleanup_testtablespace.patch (text/x-patch) patch
Hello. I saw a failure of vcregress check with the following message several times, on a machine under a heavy load and maybe with realtime virus scanning. > pg_regress: could not create directory ".../testtablespace": Permission denied. I found that pg_regress repeats the sequence rmtree(tablespace)->make_directory(tablespace) twice under initialize_environment. So it should be THE DELETE_PENDING. It is because the code is in convert_sourcefiles_in, which is called succssively twice in convert_sourcefiles. But in the first place it comes from [1] and the comment says: > * XXX it would be better if pg_regress.c had nothing at all to do with > * testtablespace, and this were handled by a .BAT file or similar on > * Windows. See pgsql-hackers discussion of 2008-01-18. Is there any reason not to do that in vcregress.pl? I think the commands other than 'check' don't needs this. [1] https://www.postgresql.org/message-id/11718.1200684807%40sss.pgh.pa.us regards. -- Kyotaro Horiguchi NTT Open Source Software Center
Commits
-
Revert "Remove reset of testtablespace from pg_regress on Windows"
- 61be85afabba 14.0 landed
-
Remove reset of testtablespace from pg_regress on Windows
- 2b2a070d98b2 14.0 landed
-
Lower privilege level of programs calling regression_main
- ce5d3424d641 12.0 cited