Ubuntu 23.04 install python2.7

wget https://www.python.org/ftp/python/2.7.9/Python-2.7.9.tgz
sudo tar xzf Python-2.7.9.tgz
cd Python-2.7.9
sudo ./configure --enable-optimizations
sudo make altinstall

sudo ln -sfn ‘/usr/local/bin/python2.7’ ‘/usr/bin/python2’
sudo update-alternatives --config python

更新ubuntu之后发现python2.7竟然没了,查了下需要重新安装

你可能感兴趣的:(ubuntu,postgresql,linux)