Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

It is quite easy to install java sun jdk 1.6.x using xxx.rpm.bin installer from, but it forces you to press "Enter" for the license agreement during installation. This is a problem for me as I need to create script to install java jdk automatically. Anyone know how to avoid this issue? Thanks.

share|improve this question

The linux command "yes" can repeatedly press a key (default is y)

yes | ./jdk-6u24-linux-x64.bin

Pretty simple, If you want it to just hit <Enter> do:

yes '' | ./jdk-6u24-linux-x64.bin

See more at

share|improve this answer

I presume you already add executable attribute to the bin file:

echo | ./jdk-6u24-linux-x64.bin

Or if is expecting Y,y or yes:

echo y | ./jdk-6u24-linux-x64.bin

Now, just be patient and wait until the end.

share|improve this answer
While this will work if it is expecting one <Enter> or y, if it is expecting more than one you will need to use a command like yes. – Jade Robbins Mar 25 '11 at 18:43

Your Answer


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.