Score:0

Gnome-terminal not starting on Ubuntu 20.04.03

mx flag

I messed up my system and need urgent help. Please bare with me. I'll be more than happy to provide all details. This PC has really important work for me. I know it won't start again if it is somehow shut down. Please help. I tried to install kernel 5.16 on ubuntu 20.04.03.

  1. For that I downloaded the missing packages from 20.4.03 and force-installed them. Following instructions here. This changed some locale files and force-installed those packages. When I ran the sudo apt --fix-broken install, it prompted me to remove several packages and libc-bin. I had to type 'Yes, do as I say!' for this. Then it removed everything and showed dpkg error code: 2.

  2. Now I was having three issues:
    a. ldconfig not found on PATH.
    b. root's PATH should usually contain /usr/local/sbin, /usr/sbin and /sbin.
    c. dpkg error in point 1 was never gone.
    I tried everything to fix this like trying to install libc-bin again and other stuff but couldn't as no command would run due to path variable issue. I tried to fix it using the solutions mentioned here by changing $PATH variable in /.root/.bashrc/ and .bashrc but nothing worked. So I tried restarting my terminal and boom, it doesn't open now.

So to conclude this, now my gnome-terminal isn't opening, pressing ctrl+alt+F1 redirects me back to GUI and I can't do anything. I tried installing VScode but snap isn't working too. I know I messed up badly. But I can't clean install this system. Please help even if there is slight hope. I have tried to mention every issue as clearly as I remember.

For reference, these are the list of all ubuntu 22.04 packages I tried to force-install:

libc6-dev_2.34-0ubuntu3_amd64.deb
libc-bin_2.34-0ubuntu3_amd64.deb
libc-dev-bin_2.34-0ubuntu3_amd64.deb
libnsl2_1.3.0-2build1_amd64.deb
libnsl-dev_1.3.0-2build1_amd64.deb
libssl3_3.0.1-0ubuntu1_amd64.deb
locales_2.34-0ubuntu3_all.deb
rpcsvc-proto_1.4.2-0ubuntu5_amd64.deb

Error message for PATH:

perl: warning: Falling back to the standard locale ("C").
Can't exec "locale": No such file or directory at /usr/share/perl5/Debconf/Encoding.pm line 16.
Use of uninitialized value $Debconf::Encoding::charmap in scalar chomp at /usr/share/perl5/Debconf/Encoding.pm line 17.
dpkg: warning: 'ldconfig' not found in PATH or not executable
dpkg: error: 1 expected program not found in PATH or not executable
Note: root's PATH should usually contain /usr/local/sbin, /usr/sbin and /sbin
E: Sub-process /usr/bin/dpkg returned an error code (2)

kanehekili avatar
zw flag
You can't force-install packages from other (future) distros. That is simply insane. A lot of other libs and apps depend on the original version and are compiled against **them** and not those you've installed. Best bet is to replace the libs you've forced against the original ones, or install Ubuntu 22.04 beta
mx flag
I understand this now :(. I tried installing all the exact packages but the PATH issue is failing me now. I have updated the question with proper error as I had tilix installed and it gave me my access back to the terminal. Please see if you can help. Also, do you think running distro upgrade will help here? Im not sure command will work. @kanehekili
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.