python 3.7 uninstall from amazon-linux2

0

I wanted to remove the python 3.7 version from my amazon-Linux completely and reinstall the python 3.9 version with yum commands

preguntada hace un año2975 visualizaciones
2 Respuestas
0
# Remove Python 3.7
sudo yum remove python3 -y

# Enable Amazon Linux Extras repository for Python 3.9
sudo amazon-linux-extras enable python3.9

# Clean the yum metadata cache
sudo yum clean metadata

# Install Python 3.9
sudo yum install python3.9 -y

# Check the installed Python version
python3 --version

profile picture
EXPERTO
respondido hace un año
profile pictureAWS
EXPERTO
revisado hace un año
  • Hi Sedat, I am experiencing "The operation would result in removing the following protected packages: dnf" with remove command. Adding --skip-broken option does not help either. Any workaround for that?

0

I am experiencing an execution error on Amazon EC2 using Linux 2 AMI

sudo amazon-linux-extras enable python3.9

Error

AWS
Krishna
respondido hace un año

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas