From the "Ubuntu Softwares" folder, I attempted to install Wine.
After clicking on the installation button for Wine, I received this message:
Unable to install Wine.
E: dpkg was interrupted upi must manually run dpkg -- configure a" to correct the problem.
Also I gave a try placing the first command on the terminal as indicated by numerous website:
yd@yd:~$ dpkg --add-architecture i386
dpkg: error: unable to create new file '/var/lib/dpkg/arch-new': Permission denied
I am new to Linux and Ubuntu. What would be the most appropriate course of action to fix this?
thx
>Solution :
You have enabled broken old repository.
To remove it use commands below:
sudo add-apt-repository -r ppa:teejee2008/ppa
Then to install wine you really do not need third-party repositories, so you have to disable all such previously added WineHQ repositories by:
sudo apt-add-repository -r "deb http://dl.winehq.org/wine-builds/ubuntu/ bionic main"
sudo apt-add-repository -r "deb http://dl.winehq.org/wine-builds/ubuntu/ focal main"
sudo apt-add-repository -r "deb http://dl.winehq.org/wine-builds/ubuntu/ groovy main"
sudo apt-add-repository -r "deb http://dl.winehq.org/wine-builds/ubuntu/ hirsute main"
sudo apt-add-repository -r "deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main"
sudo apt-add-repository -r "deb https://dl.winehq.org/wine-builds/ubuntu/ focal main"
sudo apt-add-repository -r "deb https://dl.winehq.org/wine-builds/ubuntu/ groovy main"
sudo apt-add-repository -r "deb https://dl.winehq.org/wine-builds/ubuntu/ hirsute main"
and then update package lists, install updates, resume interrupted installations by
sudo dpkg --configure -a
sudo apt-get install -f
sudo apt-get update
sudo apt-get upgrade
sudo dpkg --configure -a
sudo apt-get install -f
And finally install Wine from official repositories by
sudo apt-get install wine
or better install PlayOnLinux (sudo apt-get install playonlinux) to install Windows applications using wizards.
Note: if you have problems with official default repositories, then re-add them by
sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -cs) main restricted universe multiverse"
sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -cs)-updates main restricted universe multiverse"
sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -cs)-security main restricted universe multiverse"
sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -cs)-backports main restricted universe multiverse"
and retry above commands.