Up vote 1 down vote favorite |
I typed: sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/ jdk1.8.0/bin/java" 1
It ' s says alternatives--install needs link name path priority Command-Line Edubuntu
ShareImprove this question |
Edited Jul 5 ' + at 17:48 Guntbert 4,344 |
Asked Jul 5 ' + at 16:22 Swapnil 18 |
|
|
|
what is typing exactly ? Careful with any punctuation (e.g. dashes) and spaces – steeldriver jul 5 ' + at 16:42 |
|
@steeldriver could explain link name path priority. If There were no link like "/user/bin/java/" then would erroneous result? – swapnil jul 5 ' + at 16:53 |
|
it should create the link (and the name if there is no current Java Group in /etc/ Alternatives ). AFAIK the only thing, must pre-exist is the path component i.e. /usr/lib/jvm/jdk1.8.0/bin/java - But note this (as posted in your question) has a space in yours-hence my 1st comment. – steeldriver jul 5 ' + at 16:58 |
|
@steeldriver yeah/usr/lib/jvm/bin/java/is available. I ' ve try sudo update-alternatives--Install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.8.0.05/bin/java" 1– Swapnil Jul 5 ' 17:22 |
|
is you leaving a space between -- install the and the word "if so", don ' t-it needs to be --install . Also the quotes should not be necessary, just sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.8.0.05/bin/java 1 –steeldriver Jul 5 ' in 17:35 |
Show1More Comment |
2 Answers Active oldest votes
Up vote 3 down vote accepted |
Is you leaving a space between the--and the word install? If so, don ' t-it needs --install sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.8.0.05/bin/java 1
The quotes should not being necessary since none of the elements has embedded spaces-although they shouldn ' t do any harm.
ShareImprove this answer |
answered Jul 5 ' + at 17:45 steeldriver 13.6k3 |
|
|
Add a Comment |
Up vote 1 down vote |
This is beacause the This command maintains symbolic links. I recommend to execute to get more information about the man update-alternatives command.
|
Update-alternatives--install