
{"id":33633,"date":"2021-04-24T17:03:31","date_gmt":"2021-04-24T17:03:31","guid":{"rendered":"https:\/\/ubuntuhandbook.org\/?p=33633"},"modified":"2021-04-25T16:24:23","modified_gmt":"2021-04-25T16:24:23","slug":"install-deb-file-ubuntu-4-ways","status":"publish","type":"post","link":"https:\/\/ubuntuhandbook.org\/index.php\/2021\/04\/install-deb-file-ubuntu-4-ways\/","title":{"rendered":"[Beginner&#8217;s Guide] How to Install deb file in Ubuntu in 4 Different Ways"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2020\/06\/software-icon.png\" alt=\"\" width=\"245\" height=\"250\" class=\"alignleft size-full wp-image-10282\" \/><\/p>\n<p>Got a deb file download from the web? This is a beginner&#8217;s guide shows you how to install the file in Ubuntu.<\/p>\n<p>DEB is the software package format for Debian \/ Ubuntu based systems. Besides Ubuntu main \/ universe repositories and Ubuntu PPAs, some applications offer .deb files for downloading in their project pages or websites.<\/p>\n<h3>Option 1.) Directly install via double-click.<\/h3>\n<p>Like EXE file for Windows, you can simply double click on a deb file. By default, it opens <i>Ubuntu Software<\/i> with an option to install the software package.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/doubleclick-giara.png\" alt=\"\" width=\"600\" height=\"365\" class=\"aligncenter size-full wp-image-33634\" \/><\/p>\n<p>This is the easiest way. However Ubuntu Software is buggy, it&#8217;s one of the top core apps being criticized for years.<\/p>\n<h3>Option 2.) Use Gdebi Package Installer.<\/h3>\n<p>Gdebi package installer is the most recommended way to handle .deb packages. It&#8217;s default in Linux Mint. Ubuntu users can either install it from <i>Ubuntu Software<\/i> or by running command in terminal (Ctrl+Alt+T):<\/p>\n<pre style=\"border:none;\">sudo apt install gdebi<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/apt-gdebi-focal.jpg\" alt=\"\" width=\"600\" height=\"221\" class=\"aligncenter size-full wp-image-33635\" \/><\/p>\n<p>After installed it, just right-click on a deb file, select &#8220;<i>Open With Other Application<\/i>&#8221; and choose Gdebi package installer to open the file.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/open-viaotherapp.png\" alt=\"\" width=\"600\" height=\"377\" class=\"aligncenter size-full wp-image-33636\" \/><\/p>\n<p>When Gdebi opens, it shows the package details including app description, dependency libraries, and installed files. To install it, click on &#8220;Install Package&#8221; button.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/gdebi-giara.png\" alt=\"\" width=\"600\" height=\"415\" class=\"aligncenter size-full wp-image-33637\" \/><\/p>\n<p>And a &#8216;Remove Package&#8217; button will be available once you installed it.<\/p>\n<h3>Option 3.) Using apt command:<\/h3>\n<p>Apt is the most commonly used command to install, remove, and manage software packages from Ubuntu repositories, PPAs, and third-party apt repositories.<\/p>\n<p>It seems to start from Ubuntu 20.04, the apt command added support for installing local deb files.<\/p>\n<p>Firstly, right-click on blank area of the folder that contains the deb file. Then select &#8216;Open in Terminal&#8217;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/open-downloadsfolder-terminal.png\" alt=\"\" width=\"600\" height=\"361\" class=\"aligncenter size-full wp-image-33638\" \/><\/p>\n<p>When terminal opens, run command to install local deb file:<\/p>\n<pre style=\"border:none;\">sudo apt install .\/PACKAGE_NAME.deb<\/pre>\n<p>You can use wildcard character * in file name. In my case, the command can be:<\/p>\n<pre style=\"border:none;\">sudo apt install .\/giara_0.3*.deb<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/apt-local-giara.png\" alt=\"\" width=\"600\" height=\"305\" class=\"aligncenter size-full wp-image-33639\" \/><\/p>\n<h3> Option 4.) Using dpkg command:<\/h3>\n<p>dpkg is the command line package manager for Debian. I used to use the command to install local deb files in Ubuntu. The downside is that dpkg does not install missing dependency packages automatically.<\/p>\n<p>To install a deb file via dpkg command, run:<\/p>\n<pre style=\"border:none;\">sudo dpkg -i \/path\/to\/file_name.deb<\/pre>\n<p>Same to the previous option, you can use &#8220;Open in Terminal&#8221; option to open folder in terminal and then run command:<\/p>\n<pre style=\"border:none;\">sudo dpkg -i giara_0.3*.deb<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2021\/04\/dpkg-giara.png\" alt=\"\" width=\"600\" height=\"407\" class=\"aligncenter size-full wp-image-33640\" \/><\/p>\n<p>Since it does not handle dependency automatically, the command often output error and leave package unconfigured. You have to run one more command to fix it:<\/p>\n<pre style=\"border:none;\">sudo apt -f install<\/pre>\n<h3>Conclusion:<\/h3>\n<p>Since Ubuntu Software is buggy and dpkg command does not handle dependency packages, <b>Gdebi<\/b> and apt command can be the best choices to install local deb file in Ubuntu via either graphical or command line.<\/p>","protected":false},"excerpt":{"rendered":"<p>Got a deb file download from the web? This is a beginner&#8217;s guide shows you how to install the file in Ubuntu. DEB is the software package format for Debian \/ Ubuntu based systems. Besides Ubuntu main \/ universe repositories and Ubuntu PPAs, some applications offer .deb files for downloading in their project pages or [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[2029],"class_list":["post-33633","post","type-post","status-publish","format-standard","hentry","category-howtos","tag-deb"],"_links":{"self":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/33633","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/comments?post=33633"}],"version-history":[{"count":0,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/33633\/revisions"}],"wp:attachment":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/media?parent=33633"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/categories?post=33633"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/tags?post=33633"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}