Почему я вижу два пути java в `update-alternatives --config java`

Вы можете изменить макет с помощью console-data. Если это не установлено, используйте sudo apt-get install console-data для его установки. Затем используйте sudo dpkg-reconfigure console-data для изменения макета.

0
задан 12 October 2017 в 23:33

3 ответа

Я верю, что когда вы запустите java --version, вы получите java 9, но это ваш по умолчанию. Теперь альтернативы обновлений представят системе несколько вариантов применимых программ и укажут, какой вариант по умолчанию выбран, если пользователь не выбрал вручную, следовательно, auto видел и two параметры для java 9.

Выдержка из man update-alternatives:

update-alternatives  creates,  removes, maintains and displays information about the symbolic links comprising
the Debian alternatives system.

It is possible for several programs fulfilling the same or similar functions to be installed on a single  sys‐
   tem  at  the  same  time.   For example, many systems have several text editors installed at once.  This gives
   choice to the users of a system, allowing each to use a different editor, if desired, but makes  it  difficult
   for a program to make a good choice for an editor to invoke if the user has not specified a particular prefer‐
   ence.

Debian's alternatives system aims to solve this problem.  A generic name in the filesystem is  shared  by  all
   files  providing interchangeable functionality.  The alternatives system and the system administrator together
   determine which actual file is referenced by this generic name.  For example, if the text  editors  ed(1)  and
   nvi(1)  are  both installed on the system, the alternatives system will cause the generic name /usr/bin/editor
   to refer to /usr/bin/nvi by default. The system administrator can override this  and  cause  it  to  refer  to
   /usr/bin/ed  instead, and the alternatives system will not alter this setting until explicitly requested to do
   so.

Другими словами, в нем говорится, что у вас есть три варианта для java и что один из этих вариантов всегда будет использоваться при нормальных обстоятельствах.

1
ответ дан 22 May 2018 в 17:37

Я верю, что когда вы запустите java --version, вы получите java 9, но это ваш по умолчанию. Теперь альтернативы обновлений представят системе несколько вариантов применимых программ и укажут, какой вариант по умолчанию выбран, если пользователь не выбрал вручную, следовательно, auto видел и two параметры для java 9.

Выдержка из man update-alternatives:

update-alternatives creates, removes, maintains and displays information about the symbolic links comprising the Debian alternatives system. It is possible for several programs fulfilling the same or similar functions to be installed on a single sys‐ tem at the same time. For example, many systems have several text editors installed at once. This gives choice to the users of a system, allowing each to use a different editor, if desired, but makes it difficult for a program to make a good choice for an editor to invoke if the user has not specified a particular prefer‐ ence. Debian's alternatives system aims to solve this problem. A generic name in the filesystem is shared by all files providing interchangeable functionality. The alternatives system and the system administrator together determine which actual file is referenced by this generic name. For example, if the text editors ed(1) and nvi(1) are both installed on the system, the alternatives system will cause the generic name /usr/bin/editor to refer to /usr/bin/nvi by default. The system administrator can override this and cause it to refer to /usr/bin/ed instead, and the alternatives system will not alter this setting until explicitly requested to do so.

Другими словами, в нем говорится, что у вас есть три варианта для java и что один из этих вариантов всегда будет использоваться при нормальных обстоятельствах.

1
ответ дан 18 July 2018 в 05:23

Я верю, что когда вы запустите java --version, вы получите java 9, но это ваш по умолчанию. Теперь альтернативы обновлений представят системе несколько вариантов применимых программ и укажут, какой вариант по умолчанию выбран, если пользователь не выбрал вручную, следовательно, auto видел и two параметры для java 9.

Выдержка из man update-alternatives:

update-alternatives creates, removes, maintains and displays information about the symbolic links comprising the Debian alternatives system. It is possible for several programs fulfilling the same or similar functions to be installed on a single sys‐ tem at the same time. For example, many systems have several text editors installed at once. This gives choice to the users of a system, allowing each to use a different editor, if desired, but makes it difficult for a program to make a good choice for an editor to invoke if the user has not specified a particular prefer‐ ence. Debian's alternatives system aims to solve this problem. A generic name in the filesystem is shared by all files providing interchangeable functionality. The alternatives system and the system administrator together determine which actual file is referenced by this generic name. For example, if the text editors ed(1) and nvi(1) are both installed on the system, the alternatives system will cause the generic name /usr/bin/editor to refer to /usr/bin/nvi by default. The system administrator can override this and cause it to refer to /usr/bin/ed instead, and the alternatives system will not alter this setting until explicitly requested to do so.

Другими словами, в нем говорится, что у вас есть три варианта для java и что один из этих вариантов всегда будет использоваться при нормальных обстоятельствах.

1
ответ дан 24 July 2018 в 18:19

Другие вопросы по тегам:

Похожие вопросы: