upgrading AWS Cli in RHEL servers

0

aws-cli/1.16.280 Python/2.7.5 Linux/3.10.0-1160.92.1.el7.x86_64 botocore/1.13.16 /usr/local/bin/aws -> /usr/local/aws/bin/aws above is the version before upgrading.

after upgrading it shows as aws-cli/2.9.16 Python/3.9.11 Linux/3.10.0-1160.92.1.el7.x86_64 exe/x86_64.rhel.7 prompt/off /usr/local/bin/aws -> /usr/local/aws-cli/v2/current/bin/aws

what is prompt/off at the end means ?? and while upgrading , i changed the install directory . will that be a problem ? or should i keep the install directory same as old version ? and does aws cli upgrade needs a restart ??

profx
posta 10 mesi fa330 visualizzazioni
1 Risposta
1

Hi,

Here are the answers to your questions:

What is prompt/off at the end means ??

Refer this documentation Have the AWS CLI prompt you for commands

And while upgrading , i changed the install directory . will that be a problem ? or should i keep the install directory same as old version ?

It doesn't matter, but do make sure that when you run aws cli, you are using the latest version. You can check this by running following command:

aws --version

Also, run one of the following commands:

which aws

Or

whereis aws

This would give you the location, which awscli version is being picked. If you see old version being pointed, you can create symlink of newly installed binaries at this location, by following command:

 cd /usr/local/bin

 ln -s /usr/local/aws-cli/v2/current/bin/aws ./

In your case, it already seems reflected but just in case, you see it pointing to older version.

And does aws cli upgrade needs a restart ??

No, it doesn't require restart

Hope you find this information helpful.

Comment here if you have additional questions, happy to help.

Abhishek

profile pictureAWS
ESPERTO
con risposta 10 mesi fa
  • thanks for your reply.. how do i find whether i got both versions installed - cli 1 & cli 2 ??

  • you can find this way:

    cd ~

    find . -type d -name awscli

    or

    find . -type d -name aws-cli

    This would give you the location of AWS CLI directory and you go to each location and run the command:

    aws --version

    Completely optional, if this helps, you can accept the answer.

  • Do you have additional questions happy to help.

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande