Note that there are some explanatory texts on larger screens.

plurals
  1. POrpmbuild creates tmp files and fails due to 'Permission denied' when trying to remove them
    primarykey
    data
    text
    <h3>Background</h3> <p>I'm trying to build a simple rpm which just copies some web app source files to an install directory. The web app is written in Java, and is provided by a vendor (i.e it's not written by me).</p> <p>The rpm fails to build due to the error described below. However, I have successfully built a nearly identical rpm for another Java-based web app from the same vendor. The spec files are the same except for the names of things like the install path and the source file name.</p> <h3>Problem</h3> <p><code>rpmbuild -v -bb --clean SPECS/web-app.spec</code> fails with <code>Permission denied</code> when it tries to remove some files in <code>{BUILDROOT}/web-app-1.0/tmp</code>.</p> <p>I checked the permissions on the files that <code>rpmbuild</code> couldn't remove. Some examples below:</p> <pre><code>-r--r--r--. 1 signer signer 1203 Jan 13 2006 Adler32.class -r--r--r--. 1 signer signer 19498 Jan 13 2006 Deflate.class -r--r--r--. 1 signer signer 628 Jan 13 2006 Deflate$Config.class -r--r--r--. 1 signer signer 8673 Jan 13 2006 InfBlocks.class </code></pre> <p>They have the correct ownership and group for my build user (<code>signer</code>), but no write permission.</p> <p>These files are not part of any process I explicitly defined in my rpm spec. All my spec file does is run <code>%setup</code>, make a directory, and copy files into it. The source tarball extracted during <code>%setup</code> has the correct permissions for all of its files; I can extract and delete the tree it creates. These files are NOT part of the source tarball. I think the <code>tmp</code> files are related to some Java file processing; <code>rpmbuild</code> took a long time "repacking" jar files near the end of the build. I'm not sure what purpose that has, and I doubt it's needed for the app I'm deploying.</p> <h3>Questions</h3> <p>Can I disable the jar file repacking to fix this? Any other ideas?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload