I can not use sudo and other commands in ubuntu on amazon server -
i create server on amazon , want connect ssh in putty. connect can not send comands. have errors:
sudo apt-get install openjdk-7-jdk sudo: apt-get: command not found apt-get install openjdk-7-jdk -bash: apt-get: command not found root apt-get install openjdk-7-jdk -bash: root: command not found
but if write sudo
sudo usage: sudo [-d level] -h | -k | -k | -v usage: sudo -v [-akns] [-d level] [-g groupname|#gid] [-p prompt] [-u user name|#uid] usage: sudo -l[l] [-akns] [-d level] [-g groupname|#gid] [-p prompt] [-u user name] [-u user name|#uid] [-g groupname|#gid] [command] usage: sudo [-abehknps] [-r role] [-t type] [-c fd] [-d level] [-g groupname|#gid] [-p prompt] [-u user name|#uid] [-g groupname|#gid] [var=value] [-i|-s] [<command>] usage: sudo -e [-akns] [-r role] [-t type] [-c fd] [-d level] [-g groupname|#gid] [-p prompt] [-u user name|#uid] file ...
what it?
it not sudo
causing trouble missing apt-get
.
check version of linux running on instance. default amazon linux ami uses yum package manager has not apt-get
installed.
try installing yum
instead of apt-get
:
sudo yum <package-name>
to install openjdk, should work on amazon linux ami:
sudo yum install java-1.7.0-openjdk
Comments
Post a Comment