Ubuntu 22.04下将Opera安装为第二浏览器的技术咨询
Hi Natasha, welcome to the Ubuntu community! Good news — you can absolutely keep Firefox as your main browser and install Opera as a secondary one without replacing anything. Here’s a straightforward, step-by-step guide using command lines to get Opera set up:
First, update your system’s package list to ensure you’re working with the latest software information:
sudo apt update && sudo apt upgrade -yNext, install the necessary tools to add third-party software sources safely:
sudo apt install -y curl software-properties-commonAdd Opera’s official GPG key to verify the authenticity of the packages you’ll download:
curl -fsSL https://deb.opera.com/archive.key | sudo gpg --dearmor -o /usr/share/keyrings/opera-archive-keyring.gpgAdd Opera’s stable release repository to your system’s source list:
echo "deb [signed-by=/usr/share/keyrings/opera-archive-keyring.gpg] https://deb.opera.com/opera-stable/ stable non-free" | sudo tee /etc/apt/sources.list.d/opera-stable.listRefresh the package list again to include the new Opera repository:
sudo apt updateFinally, install the stable version of Opera:
sudo apt install -y opera-stable
Once the installation finishes, you’ll find Opera in your application menu. Firefox will remain your default browser unless you intentionally change that setting (which you don’t need to do if you just want Opera as a secondary option).
If you ever want to remove Opera later, you can run these commands:
- Uninstall Opera and its configuration files:
sudo apt remove --purge opera-stable - Remove the Opera repository from your system:
sudo rm /etc/apt/sources.list.d/opera-stable.list - Clean up any leftover dependencies:
sudo apt autoremove -y
备注:内容来源于stack exchange,提问作者natasha




