WARNING:root:could not open file '/etc/apt

13,334

The directory /etc/apt/sources.list.d is missing the execute permission (x). It is needed to open a directory. Restore it using:

sudo chmod +x /etc/apt/sources.list.d

See also

Share:
13,334

Related videos on Youtube

mark
Author by

mark

Updated on September 18, 2022

Comments

  • mark
    mark over 1 year
    vegan@vegan:~$ yo -v
    WARNING:root:could not open file '/etc/apt/sources.list.d/midori-ubuntu-ppa-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/git.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/yandex-browser-beta.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/webupd8team-ubuntu-java-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/yandex-browser.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/nodesource.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/google-chrome.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/notepadqq-team-ubuntu-notepadqq-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/apandada1-ubuntu-brightness-controller-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/opera-stable.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/justinludwig-ubuntu-tzdata-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/maarten-baert-ubuntu-simplescreenrecorder-xenial.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/docker.list'
    WARNING:root:could not open file '/etc/apt/sources.list.d/slack.list'
    yo: command not found
    

    Those are from update.

    enter image description here

    enter image description here

    enter image description here

    vegan@vegan:~$ sudo apt-get update
    Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease
    Ign:2 http://archive.ubuntu.com/ubuntu precise InRelease
    Get:3 http://security.ubuntu.com/ubuntu precise-security InRelease [55,7 kB]
    Hit:4 http://dl.google.com/linux/chrome/deb stable Release                     
    Get:5 http://archive.ubuntu.com/ubuntu precise-updates InRelease [55,7 kB]       
    Hit:6 https://deb.nodesource.com/node_5.x xenial InRelease                       
    Hit:8 http://archive.ubuntu.com/ubuntu precise-backports InRelease               
    Hit:9 http://archive.ubuntu.com/ubuntu precise Release
    Fetched 111 kB in 0s (115 kB/s)
    Reading package lists... Done
    W: http://security.ubuntu.com/ubuntu/dists/precise-security/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1)
    W: http://archive.ubuntu.com/ubuntu/dists/precise-updates/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1)
    W: http://archive.ubuntu.com/ubuntu/dists/precise-backports/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1)
    W: http://archive.ubuntu.com/ubuntu/dists/precise/Release.gpg: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1)
    vegan@vegan:~$ sudo apt-get upgrade
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Calculating upgrade... Done
    The following packages have been kept back:
      tzdata-java
    0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
    

    And this is /etc/apt/sources.list:

    deb http://archive.ubuntu.com/ubuntu precise main universe restricted multiverse
    deb-src http://archive.ubuntu.com/ubuntu precise universe main multiverse restricted
    
    deb http://security.ubuntu.com/ubuntu/ precise-security universe main multiverse restricted
    deb http://archive.ubuntu.com/ubuntu precise-updates universe main multiverse restricted
    deb http://archive.ubuntu.com/ubuntu precise-backports universe main multiverse restricted
    
    # deb http://archive.canonical.com/ubuntu precise partner
    # deb-src http://archive.canonical.com/ubuntu precise partner
    
    # deb http://extras.ubuntu.com/ubuntu precise main
    # deb-src http://extras.ubuntu.com/ubuntu precise main
    

    this is also

        vegan@vegan:~$ ls -l /etc/apt/sources.list.d
    ls: cannot access '/etc/apt/sources.list.d/nodesource.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/git.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/google-chrome.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/midori-ubuntu-ppa-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/opera-stable.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/git.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/webupd8team-ubuntu-java-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/yandex-browser.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/yandex-browser-beta.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/yandex-browser-beta.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/webupd8team-ubuntu-java-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/yandex-browser.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/nodesource.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/google-chrome.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/notepadqq-team-ubuntu-notepadqq-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/midori-ubuntu-ppa-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/maarten-baert-ubuntu-simplescreenrecorder-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/apandada1-ubuntu-brightness-controller-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/docker.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/opera-stable.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/justinludwig-ubuntu-tzdata-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/apandada1-ubuntu-brightness-controller-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/slack.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/notepadqq-team-ubuntu-notepadqq-xenial.list.save': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/justinludwig-ubuntu-tzdata-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/maarten-baert-ubuntu-simplescreenrecorder-xenial.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/docker.list': Permission denied
    ls: cannot access '/etc/apt/sources.list.d/slack.list': Permission denied
    total 0
    -????????? ? ? ? ?            ? apandada1-ubuntu-brightness-controller-xenial.list
    -????????? ? ? ? ?            ? apandada1-ubuntu-brightness-controller-xenial.list.save
    -????????? ? ? ? ?            ? docker.list
    -????????? ? ? ? ?            ? docker.list.save
    -????????? ? ? ? ?            ? git.list
    -????????? ? ? ? ?            ? git.list.save
    -????????? ? ? ? ?            ? google-chrome.list
    -????????? ? ? ? ?            ? google-chrome.list.save
    -????????? ? ? ? ?            ? justinludwig-ubuntu-tzdata-xenial.list
    -????????? ? ? ? ?            ? justinludwig-ubuntu-tzdata-xenial.list.save
    -????????? ? ? ? ?            ? maarten-baert-ubuntu-simplescreenrecorder-xenial.list
    -????????? ? ? ? ?            ? maarten-baert-ubuntu-simplescreenrecorder-xenial.list.save
    -????????? ? ? ? ?            ? midori-ubuntu-ppa-xenial.list
    -????????? ? ? ? ?            ? midori-ubuntu-ppa-xenial.list.save
    -????????? ? ? ? ?            ? nodesource.list
    -????????? ? ? ? ?            ? nodesource.list.save
    -????????? ? ? ? ?            ? notepadqq-team-ubuntu-notepadqq-xenial.list
    -????????? ? ? ? ?            ? notepadqq-team-ubuntu-notepadqq-xenial.list.save
    -????????? ? ? ? ?            ? opera-stable.list
    -????????? ? ? ? ?            ? opera-stable.list.save
    -????????? ? ? ? ?            ? slack.list
    -????????? ? ? ? ?            ? slack.list.save
    -????????? ? ? ? ?            ? webupd8team-ubuntu-java-xenial.list
    -????????? ? ? ? ?            ? webupd8team-ubuntu-java-xenial.list.save
    -????????? ? ? ? ?            ? yandex-browser-beta.list
    -????????? ? ? ? ?            ? yandex-browser-beta.list.save
    -????????? ? ? ? ?            ? yandex-browser.list
    -????????? ? ? ? ?            ? yandex-browser.list.save
    

    also

    vegan@vegan:~$ ls -l /etc/apt
    total 92
    drwxr-xr-x 2 root root  4096 Oca 18 10:14 apt.conf.d
    -rw-r--r-- 1 root root  2144 Şub 18  2016 apt-file.conf
    drwxr-xr-x 2 root root  4096 Nis 14  2016 preferences.d
    -rw-r--r-- 1 root root   668 Oca 29 17:52 sources.list
    drw-r--r-- 2 root root  4096 Oca 25 15:22 sources.list.d
    -rw-rw-r-- 1 root root  2979 Oca  2 09:37 sources.list.save
    -rw-r--r-- 1 root root 31967 Oca 18 09:59 trusted.gpg
    -rw-r--r-- 1 root root 31594 Kas 30 10:23 trusted.gpg~
    drwxr-xr-x 2 root root  4096 Oca  2 09:37 trusted.gpg.d
    
    • Phillip -Zyan K Lee- Stockmann
      Phillip -Zyan K Lee- Stockmann over 7 years
      could you add the output of which yo into your question?
    • mark
      mark over 7 years
      @Melebius added. it is not about you bu output is vegan@vegan:~$ which yo /usr/bin/yo
    • mark
      mark over 7 years
      @Melebius i added to answer.