Sign up ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

When I install this:

sudo apt-get install -y sun-java6-bin sun-java6-jdk sun-java6-jre sun-java6-plugin

I am still forced to select OK and YES during the install.

The -y switch doesn't work for this.

Is there a way to do this automatically?

share|improve this question
One direction to pursue, if you're up for an adventure. –  ændrük Oct 31 '11 at 2:51

1 Answer 1

up vote 3 down vote accepted
  • Create a file containing this line (columns separated by a tab):

    sun-java6-bin   shared/accepted-sun-dlj-v1-1    boolean     true
  • Import this into debconf with sudo debconf-set-selections < file.

  • Install the packages

share|improve this answer

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.