After I found and installed OpenJDK in Fedora 20 using Apper I noticed there is a series of directories starting with jar prefix under /etc/alternatives, specifically:/etc/alternatives/jre (93,4MB)/etc/alternatives/jre_1.8.0 (93,4MB)/etc/alternatives/jre_1.8.0_exports (1,3GB)/etc/alternatives/jre_exports (1,3GB)/etc/alternatives/jre_openjdk (93,4MB)/etc/alternatives/jre_openjdk_exports (1,3GB)with total size of 4,3GBCan I direct Apper/yum/whatever to put these files in some other location as I keep my whole /etc directory in Dropbox and I do not want to have these gigantic jar files there.Also, I do not think this type of files belong to /etc at all which makes me wonder why they were put there in the first place?
How to prevent .jar files from going into /etc when installing OpenJDK from rpm?
fedora;package management;yum;java
These .jar files are not really being installed into the /etc directory. There's a software package called alternatives which maintains a set of Unix links which allows a system to have multiple versions of tools with the same name. In this case those names would be the executables that are included with Java. The multiple versions would be typically Oracle's JDK and the OpenJDK project's.You can use the command line tool readlink to see where these exectuables are actually residing on disk.$ readlink -f /etc/alternatives/jre/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.60-2.4.4.1.fc19.x86_64/jrealternatives also can maintain executables that live in /usr/bin too.$ type jarjar is /usr/bin/jar$ readlink -f /usr/bin/jar/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.60-2.4.4.1.fc19.x86_64/bin/jar$ type javajava is /usr/bin/java$ readlink -f /usr/bin/java/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.60-2.4.4.1.fc19.x86_64/jre/bin/javaYou can read more about the alternatives command via its man page. This tutorial titled: Install Oracle Java JDK/JRE 7u51 on Fedora 20/19, CentOS/RHEL 6.5/5.10 shows the alternatives command in action too.