Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I move a Java installation to a new volume on my server?

Right now we have Java and the OS (CentOS) running off of a HDD. We're trying to speed things up so would like to have the OS use the SSD drive for Java since the read/write speed is 100x faster.

Does anyone know how we can copy or reinstall java to a new volume?

share|improve this question
    
What OS are you using? –  malakrsnaslava Sep 15 '13 at 22:59
    
How did you installed Java? –  Braiam Sep 15 '13 at 23:02
    
Hi @Braiam, we used Yum –  d-_-b Sep 15 '13 at 23:02

1 Answer 1

If you used Yum, the thing is not easy, since Java don't install all its files in one place, but different directories like /var, /lib and /usr. I would recommend building Java from sources and configure a prefix for the installation.

When you download the sources, you can set the prefix using ./configure --prefix=/path/to/volume.

BUT, I think the most easy solution is clone the operative system and use the entire SSD as the main disk, then configure the fstab to mount no critical directories there, like /tmp or /var/cache, etc. in the old disk.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.