- How to Install Google Chrome Using Terminal on Linux
- Community Q&A
- How to install software from the Linux command line
- What is a package management system?
- Debian, Ubuntu, Mint, and others
- RHEL, CentOS, Fedora, Mageia, and OpenMandriva
- How do I install a .deb file via the command line?
- Install a package
- Remove a package
- Reconfigure an existing package
How to Install Google Chrome Using Terminal on Linux
This article was co-authored by wikiHow staff writer, Nicole Levine, MFA. Nicole Levine is a Technology Writer and Editor for wikiHow. She has more than 20 years of experience creating technical documentation and leading support teams at major web hosting and software companies. Nicole also holds an MFA in Creative Writing from Portland State University and teaches composition, fiction-writing, and zine-making at various institutions.
The wikiHow Tech Team also followed the article’s instructions and verified that they work.
This article has been viewed 606,792 times.
Need to install Google Chrome on Linux from the command line? Whether you’re logged in remotely or using a terminal window, it’s easy to install Chrome using wget to download the installer and dpkg to run it. This wikiHow article will walk you through installing Chrome from the terminal on Ubuntu or Debian Linux.
- Type sudo apt update and press the Enter key. [1] X Research source
- Type sudo apt upgrade and press the Enter key.
- Type wget —version and press the Enter key. If you see a version number, just skip to the next step now.
- If you get an error because wget is not installed, type sudo apt install wget and press the Enter key to install it.
- Type wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb and press the Enter key.
- After the package is finished downloading, you’ll return to the command prompt.
Fix errors that occurred in the Chrome installation. If you see any errors during the installation, type sudo apt-get install -f and press the Enter key to repair them.
Community Q&A
I downloaded Google Chrome for Linux in the terminal and launched it by typing «google-chrome,» but it said «Command not found.» What do I do?
You have to install it. Downloading is only half the job. Only installed packages can be run from terminal. In Unix systems it usually means it’s extracted into a specific path, which is usually done by the package manager itself.
Thanks! We’re glad this was helpful.
Thank you for your feedback.
As a small thank you, we’d like to offer you a $30 gift card (valid at GoNift.com). Use it to try out great new products and services nationwide without paying full price—wine, food delivery, clothing and more. Enjoy! Claim Your Gift If wikiHow has helped you, please consider a small contribution to support us in helping more readers like you. We’re committed to providing the world with free how-to resources, and even $1 helps us in our mission. Support wikiHow
Make sure you have recent version of Linux and active internet connection. Old version of Linux have old repository links which may not be available.
Thanks! We’re glad this was helpful.
Thank you for your feedback.
As a small thank you, we’d like to offer you a $30 gift card (valid at GoNift.com). Use it to try out great new products and services nationwide without paying full price—wine, food delivery, clothing and more. Enjoy! Claim Your Gift If wikiHow has helped you, please consider a small contribution to support us in helping more readers like you. We’re committed to providing the world with free how-to resources, and even $1 helps us in our mission. Support wikiHow
1. Is it necessary to always open Google Chrome from terminal, and 2. Must the terminal screen be kept open for Google Chrome to keep working?
No. Chrome should show up in the applications of menu of most desktop environments. You can also launch it from a simple run prompt in most environments by pressing Alt-F2, and then entering google-Chrome in the box. Normally, closing the terminal would close Chrome (or most applications launched from it). If you launch google-chrome as a background process (using the command «google-chrome &») and then disown the process (running «disown #», where # is the PID of the process), you can close the terminal and leave Chrome running. Alternatively, launch Chrome with nohup («nohup google-chrome») and then close the terminal.
Thanks! We’re glad this was helpful.
Thank you for your feedback.
As a small thank you, we’d like to offer you a $30 gift card (valid at GoNift.com). Use it to try out great new products and services nationwide without paying full price—wine, food delivery, clothing and more. Enjoy! Claim Your Gift If wikiHow has helped you, please consider a small contribution to support us in helping more readers like you. We’re committed to providing the world with free how-to resources, and even $1 helps us in our mission. Support wikiHow
How to install software from the Linux command line
If you use Linux for any amount of time, you’ll soon learn there are many different ways to do the same thing. This includes installing applications on a Linux machine via the command line. I have been a Linux user for roughly 25 years, and time and time again I find myself going back to the command line to install my apps.
The most common method of installing apps from the command line is through software repositories (a place where software is stored) using what’s called a package manager. All Linux apps are distributed as packages, which are nothing more than files associated with a package management system. Every Linux distribution comes with a package management system, but they are not all the same.
What is a package management system?
A package management system is comprised of sets of tools and file formats that are used together to install, update, and uninstall Linux apps. The two most common package management systems are from Red Hat and Debian. Red Hat, CentOS, and Fedora all use the rpm system (.rpm files), while Debian, Ubuntu, Mint, and Ubuntu use dpkg (.deb files). Gentoo Linux uses a system called Portage, and Arch Linux uses nothing but tarballs (.tar files). The primary difference between these systems is how they install and maintain apps.
You might be wondering what’s inside an .rpm , .deb , or .tar file. You might be surprised to learn that all are nothing more than plain old archive files (like .zip ) that contain an application’s code, instructions on how to install it, dependencies (what other apps it may depend on), and where its configuration files should be placed. The software that reads and executes all of those instructions is called a package manager.
Debian, Ubuntu, Mint, and others
Debian, Ubuntu, Mint, and other Debian-based distributions all use .deb files and the dpkg package management system. There are two ways to install apps via this system. You can use the apt application to install from a repository, or you can use the dpkg app to install apps from .deb files. Let’s take a look at how to do both.
Installing apps using apt is as easy as:
$ sudo apt install app_name
Uninstalling an app via apt is also super easy:
To upgrade your installed apps, you’ll first need to update the app repository:
Once finished, you can update any apps that need updating with the following:
What if you want to update only a single app? No problem.
Finally, let’s say the app you want to install is not available in the Debian repository, but it is available as a .deb download. You can install it manually using dpkg , the system that apt helps manage:
RHEL, CentOS, Fedora, Mageia, and OpenMandriva
Red Hat, its upstream project Fedora, and its «midstream» project CentOS, use the dnf package manager. It has its own syntax, and is a front-end to the RPM system. Although the syntax is different, dnf is similar to apt in the sense that the mechanisms and goals are the same. The Mageia and OpenMandriva distributions, once focused exclusively on urpmi for package management, now also includes dnf in their distributions.
The dnf package manager is the successor to the previous yum command. The yum had a long time to engrain itself in the minds and servers of users, so to avoid breaking custom scripts that have been around on users’ systems for over a decade, yum and dnf are now interchangeable (in fact, yum is now based on dnf .)
$ sudo dnf install app_name
Removing unwanted applications is just as easy.
The dnf (or yum ) command is a front-end for the RPM packaging system. If you can’t find an app in your software repository but you can find it for download directly from its vendor site, you can use dnf to manually install an .rpm file.
$ sudo dnf install ./app_name.rpm
As you can see, installing, uninstalling, and updating Linux apps from the command line isn’t hard at all. In fact, once you get used to it, you’ll find it’s faster than using desktop GUI-based management tools!
For more information on installing apps from the command line, please visit the Debian Apt wiki, the Yum cheat sheet, and the DNF wiki.
How do I install a .deb file via the command line?
Packages are manually installed via the dpkg command (Debian Package Management System). dpkg is the backend to commands like apt-get and aptitude , which in turn are the backend for GUI install apps like the Software Center and Synaptic.
Something along the lines of:
dpkg —> apt-get , aptitude —> Synaptic, Software Center
But of course the easiest ways to install a package would be, first, the GUI apps (Synaptic, Software Center, etc..), followed by the terminal commands apt-get and aptitude that add a very nice user friendly approach to the backend dpkg, including but not limited to packaged dependencies, control over what is installed, needs update, not installed, broken packages, etc.. Lastly the dpkg command which is the base for all of them.
Since dpkg is the base, you can use it to install packaged directly from the command line.
Install a package
For example if the package file is called askubuntu_2.0.deb then you should do sudo dpkg -i askubuntu_2.0.deb . If dpkg reports an error due to dependency problems, you can run sudo apt-get install -f to download the missing dependencies and configure everything. If that reports an error, you’ll have to sort out the dependencies yourself by following for example How do I resolve unmet dependencies after adding a PPA?.
Remove a package
For example if the package is called askubuntu then you should do sudo dpkg -r askubuntu .
Reconfigure an existing package
sudo dpkg-reconfigure PACKAGE_NAME
This is useful when you need to reconfigure something related to said package. Some useful examples it the keyboard-configuration when you want to enable the Ctrl + Alt + Backspace in order to reset the X server, so you would the following:
sudo dpkg-reconfigure keyboard-configuration
Another great one is when you need to set the Timezone for a server or your local testing computer, so you use use the tzdata package:
sudo dpkg-reconfigure tzdata