[jbosstools-issues] [JBoss JIRA] (TOOLSDOC-287) Alternatives command needs a priority number to work
Michelle Murray (JIRA)
jira-events at lists.jboss.org
Tue Jan 8 22:16:08 EST 2013
[ https://issues.jboss.org/browse/TOOLSDOC-287?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michelle Murray resolved TOOLSDOC-287.
--------------------------------------
Resolution: Done
Changes live on customer portal on 9th Jan 2013.
> Alternatives command needs a priority number to work
> ----------------------------------------------------
>
> Key: TOOLSDOC-287
> URL: https://issues.jboss.org/browse/TOOLSDOC-287
> Project: Documentation for JBoss Tools and Developer Studio
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: Getting Started Guide
> Affects Versions: 4.0.0.Beta1
> Environment: Fedora 17 x86_64
> Reporter: Michelle Murray
> Assignee: Isaac Rooskov
> Fix For: 4.0.0.Final
>
>
> About: JBDS Getting Started Guide 5.0.1. The second Note in 3.1.1 gives information about using the alternatives command to add JDK.
> Issue: These instructions did not work for me using alternatives version 1.3.59. I made the assumption that each sudo command should be input separately so perhaps this is where I went wrong. The use of the given commands, with jdk1.6.0_24 changed for update 37, resulted in the instructions for using the alternatives commands being output on the command line as below:
> {noformat}[mmurray at dhcp-0-244 ~]$ sudo /usr/sbin/alternatives --install "/usr/bin/java" "java" "/usr/java/jdk1.6.0_37/bin/java"
> alternatives version 1.3.59 - Copyright (C) 2001 Red Hat, Inc.
> This may be freely redistributed under the terms of the GNU Public License.
> usage: alternatives --install <link> <name> <path> <priority>
> [--initscript <service>]
> [--slave <link> <name> <path>]*
> alternatives --remove <name> <path>
> alternatives --auto <name>
> alternatives --config <name>
> alternatives --display <name>
> alternatives --set <name> <path>
> common options: --verbose --test --help --usage --version
> --altdir <directory> --admindir <directory>{noformat}
> Workaround: To get the instructions to work, I added a priority number to the end of each 'alternatives install' command as per the alternatives man page. For example,
> {noformat}sudo alternatives --install "/usr/bin/java" "java" "/usr/java/jdk1.6.0_37/bin/java" 2000{noformat}
> {noformat}sudo alternatives --install "/usr/bin/javac" "javac" "/usr/java/jdk1.6.0_37/bin/javac" 2000{noformat}
> {noformat}sudo alternatives --install "/usr/lib/jvm/java-1.6.0" "java_sdk_1.6.0" "/usr/java/jdk1.6.0_37" 2000{noformat}
> I was unsure what number to pick for the priority and randomly put 2000. I ran each sudo command separately.
> Also, it appears that the quotation marks are not necessary in the command.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list