3

Ubuntu 18.04, using this guide to install qgis on the machine. https://linuxhint.com/install-qgis3-geospatial-ubuntu/

sudo apt-get update
sudo apt-get install qgis python-qgis qgis-plugin-grass

I can open QGIS and view layers but I cannot run any processes at all or save any layers. It just randomly shuts down with no error at all. when I click the about page it pops up for 1 second then QGIS closes completely.

enter image description here

I have also removed QGIS and reinstalled it multiple times with

sudo apt-get remove  qgis
sudo apt-get remove --auto-remove qgis
sudo apt-get purge qgis
sudo apt-get purge --auto-remove qgis

How should I go about troubleshooting this problem?

When I run sudo apt-get update

Hit:1 http://us.archive.ubuntu.com/ubuntu bionic InRelease
Ign:3 http://dl.google.com/linux/chrome/deb stable InRelease                   
Hit:4 https://qgis.org/debian bionic InRelease                                 
Get:2 http://us.archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]   
Hit:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu bionic InRelease
Ign:8 http://qgis.org/debian codename InRelease                                
Hit:9 http://dl.google.com/linux/chrome/deb stable Release                     
Get:6 http://security.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]    
Get:5 http://us.archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB] 
Hit:10 http://qgis.org/ubuntugis xenial InRelease                              
Hit:11 http://ppa.launchpad.net/webupd8team/atom/ubuntu bionic InRelease       
Err:12 http://qgis.org/debian codename Release                                 
  404  Not Found [IP: 104.27.138.220 80]
Reading package lists... Done                                                  
E: The repository 'http://qgis.org/debian codename Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Release file for http://us.archive.ubuntu.com/ubuntu/dists/bionic-updates/InRelease is not valid yet (invalid for another 1h 11min 13s). Updates for this repository will not be applied.
E: Release file for http://us.archive.ubuntu.com/ubuntu/dists/bionic-backports/InRelease is not valid yet (invalid for another 31min 53s). Updates for this repository will not be applied.
E: Release file for http://security.ubuntu.com/ubuntu/dists/bionic-security/InRelease is not valid yet (invalid for another 31min 12s). Updates for this repository will not be applied.
W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list:53 and /etc/apt/sources.list:59
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target DEP-11 (main/dep11/Components-amd64.yml) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target DEP-11 (main/dep11/Components-all.yml) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target DEP-11-icons-small (main/dep11/icons-48x48.tar) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target DEP-11-icons (main/dep11/icons-64x64.tar) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target CNF (main/cnf/Commands-amd64) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target CNF (main/cnf/Commands-all) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:56
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target DEP-11 (main/dep11/Components-amd64.yml) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target DEP-11 (main/dep11/Components-all.yml) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target DEP-11-icons-small (main/dep11/icons-48x48.tar) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target DEP-11-icons (main/dep11/icons-64x64.tar) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target CNF (main/cnf/Commands-amd64) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58
W: Target CNF (main/cnf/Commands-all) is configured multiple times in /etc/apt/sources.list:52 and /etc/apt/sources.list:58

then

apt-cache policy qgis
qgis:
  Installed: (none)
  Candidate: 1:3.2.3+28bionic
  Version table:
     1:3.2.3+28bionic 500
        500 https://qgis.org/debian bionic/main amd64 Packages
     1:3.2.3+24xenial-ubuntugis 500
        500 http://qgis.org/ubuntugis xenial/main amd64 Packages
     2.18.20+dfsg-1~bionic1 500
        500 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu bionic/main amd64 Packages
     2.18.17+dfsg-1 500
        500 http://us.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages

UPDATE

sudo apt-get update

Hit:1 http://us.archive.ubuntu.com/ubuntu bionic InRelease
Get:2 http://security.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]                                                             
Get:3 http://us.archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]                                                               
Ign:4 http://dl.google.com/linux/chrome/deb stable InRelease                                                                               
Hit:5 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu bionic InRelease                                                        
Get:6 http://us.archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]                                       
Get:7 http://security.ubuntu.com/ubuntu bionic-security/main i386 Packages [140 kB]                                                        
Hit:8 http://ppa.launchpad.net/webupd8team/atom/ubuntu bionic InRelease                                                       
Hit:9 http://dl.google.com/linux/chrome/deb stable Release                                                                    
Get:10 http://us.archive.ubuntu.com/ubuntu bionic-updates/main i386 Packages [355 kB]           
Get:11 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages [177 kB]                                           
Hit:12 https://qgis.org/ubuntu bionic InRelease                                                                    
Get:13 http://security.ubuntu.com/ubuntu bionic-security/main Translation-en [68.7 kB]                             
Get:14 http://security.ubuntu.com/ubuntu bionic-security/main amd64 DEP-11 Metadata [204 B]                               
Get:15 http://security.ubuntu.com/ubuntu bionic-security/universe i386 Packages [84.5 kB]
Get:17 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 Packages [84.5 kB]                                      
Get:18 http://us.archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [394 kB]
Get:19 http://security.ubuntu.com/ubuntu bionic-security/universe Translation-en [46.4 kB]
Get:20 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 DEP-11 Metadata [6,848 B]
Get:21 http://security.ubuntu.com/ubuntu bionic-security/universe DEP-11 48x48 Icons [9,088 B]            
Get:22 http://security.ubuntu.com/ubuntu bionic-security/universe DEP-11 64x64 Icons [11.3 kB]           
Get:23 http://us.archive.ubuntu.com/ubuntu bionic-updates/main Translation-en [146 kB]
Get:24 http://us.archive.ubuntu.com/ubuntu bionic-updates/main amd64 DEP-11 Metadata [170 kB]
Get:25 http://us.archive.ubuntu.com/ubuntu bionic-updates/main DEP-11 48x48 Icons [40.8 kB]
Get:26 http://us.archive.ubuntu.com/ubuntu bionic-updates/main DEP-11 64x64 Icons [76.7 kB]
Get:27 http://us.archive.ubuntu.com/ubuntu bionic-updates/restricted i386 Packages [3,600 B]
Get:28 http://us.archive.ubuntu.com/ubuntu bionic-updates/restricted amd64 Packages [3,648 B]
Get:29 http://us.archive.ubuntu.com/ubuntu bionic-updates/restricted Translation-en [1,376 B]
Get:30 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [556 kB]
Get:31 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe i386 Packages [551 kB]
Get:32 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe Translation-en [143 kB]
Get:33 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe amd64 DEP-11 Metadata [182 kB]
Get:34 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe DEP-11 48x48 Icons [170 kB]
Get:35 http://us.archive.ubuntu.com/ubuntu bionic-updates/universe DEP-11 64x64 Icons [291 kB]
Get:36 http://us.archive.ubuntu.com/ubuntu bionic-updates/multiverse amd64 Packages [5,392 B]
Get:37 http://us.archive.ubuntu.com/ubuntu bionic-updates/multiverse i386 Packages [5,540 B]
Get:38 http://us.archive.ubuntu.com/ubuntu bionic-updates/multiverse Translation-en [3,124 B]
Get:39 http://us.archive.ubuntu.com/ubuntu bionic-updates/multiverse amd64 DEP-11 Metadata [2,464 B]
Get:40 http://us.archive.ubuntu.com/ubuntu bionic-backports/universe amd64 DEP-11 Metadata [5,104 B]
Fetched 3,980 kB in 4s (1,079 kB/s)                                           
Reading package lists... Done
</pre>

added this deb https://qgis.org/ubuntu bionic main to the sudo nano /etc/apt/sources.list

tried running sudo apt-get install qgis python-qgis and had the same problem as before

  • 3
    I suggest to update to QGIS 3.2. The Version 3.0 had many bugs. – AndreJ Sep 28 '18 at 16:10
  • @AndreJ how do I do that? – ziggy Sep 28 '18 at 16:49
  • What do you get from apt-cache policy qgis ? Any packages held back when you do sudo apt-get update ? – AndreJ Sep 28 '18 at 17:11
  • Could you try these directions? gis.stackexchange.com/questions/133033/… I've got clean installs on Ubuntu and Mint with QGIS 3.2... – DPSSpatial Sep 28 '18 at 17:43
  • 2
    http://qgis.org/debian codename Release is surely wrong. You should replace codename release with bionic main. And http://qgis.org/ubuntugis xenial InRelease is wrong since you are running bionic, not xenial. Ubuntugis is not needed for bionic. – AndreJ Sep 28 '18 at 18:11
1

A tentative answer, too big to fit in a comment. I've not used Ubuntu for a while, but hope this helps.

apt-cache policy qgis
qgis:
 Installed: (none)
     Candidate: 1:3.2.3+28bionic
Version table:
  1:3.2.3+28bionic 500
    500 https://qgis.org/debian bionic/main amd64 Packages
  **1:3.2.3+24xenial-ubuntugis 500**
    500 http://qgis.org/ubuntugis xenial/main amd64 Packages
  2.18.20+dfsg-1~bionic1 500
    500 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu bionic/main amd64 Packages
  2.18.17+dfsg-1 500
    500 http://us.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages

Note that most of your dependencies are for Bionic, but not the one I highlighted.

Not sure if this is a packaging problem. The line that @AndreJ pointed out is certainly wrong. Check your /etc/apt/sources.list and comment out any references to ubuntugis

Whenever I hit problems like this in Ubuntu, I usually use synaptic to nuke my settings and start over. Better still, try installing on a VM first :)

1

The installation ist actually quite straight forward; @DPSpatial's linked post is a good source for instructions, and the QGIS Ubuntu/Debian download and installation instructions work out-of-the-box:

  • First, purge your installation:

    sudo apt-get remove --purge qgis python-qgis qgis-plugin-grass
    
  • and remove all relevant repositories from your /etc/apt/sources.list, e.g. by typing

    sudo nano /etc/apt/sources.list
    

    to open the nano in-terminal text editor, from which you can remove all entries that are connected to QGIS. It's only text, and you can always simply add missing/broken repos, but a little care is advisable (backup copy)

  • Add the proper repository to your /etc/apt/sources.list (the blog you linked adds the debian repository, not the one for ubuntu!):

    deb https://qgis.org/ubuntu bionic main
    
  • update apt:

    sudo apt-get update
    
  • install QGIS, pyqgis and GRASS plugin:

    sudo apt-get install qgis python-qgis qgis-plugin-grass 
    

Btw., from my machine, with up-and-running QGIS 3.2.3:

apt-cache policy qgis
qgis:
  Installed: 1:3.2.3+28bionic
  Candidate: 1:3.2.3+28bionic
  Version table:
 *** 1:3.2.3+28bionic 500
        500 https://qgis.org/ubuntu bionic/main amd64 Packages
        100 /var/lib/dpkg/status
     2.18.17+dfsg-1 500
        500 http://archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
  • if you are getting keychain errors, you'd need to add the repo key. if so, say a word – ThingumaBob Sep 29 '18 at 6:54
  • deb https://qgis.org/ubuntu bionic main is surely wrong too. For bionic, you have to add debian bionic. for xenial, ubuntugis xenial. Ubuntu is not a valid option. – AndreJ Sep 29 '18 at 9:34
  • @AndreJ this is the repo src for ubuntu, here the package releases and distro versions supported. – ThingumaBob Sep 29 '18 at 9:38
  • Oh, someone did follow my advice ;-) But both folders still contain the same debian and ubuntu packages. You see it if you open the link in a browser. – AndreJ Sep 29 '18 at 17:08
  • tried these directions but had the same problem with the installation. I deleted any qgis repositories from my /etc/apt/sources.list added the proper one as you said deb https://qgis.org/ubuntu bionic main and ran through the setup process – ziggy Oct 5 '18 at 12:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.