Alternatives command and Centos7
The alternatives
command (man page) is a tool to create, remove, maintain and display information about the symbolic links comprising the alternatives system. So, you make system-wide changes with it and, thus, you need a user with elevated privileges. You either have to sudo update-alternatives
(if sudo is installed and the user is a sudoer) or login as root with su -
and then run said command. This answer to a question about how one runs commands that need root permissions may be helpful to you.
Related videos on Youtube
yxs8495
Updated on September 18, 2022Comments
-
yxs8495 almost 2 years
I am trying to use the alternatives system on CentOS Linux release 7.3.1611 (Core). I am trying to choose between multiple editors. I am following the tutorial here.
http://www.linuxquestions.org/linux/answers/Applications_GUI_Multimedia/LINUX_ALTERNATIVES_HOWTO
Everything seems to be set up correctly. However, the default editor does not change.Please see the attached png file.
-
GMaster about 7 yearsHave you tried
sudo alternatives --config myeditor
? -
Admin about 7 yearsyou need root permissions to change alternatives...
-