2

I am a complete noob who just installed an Ubuntu guest in VirtualBox. I did a minimal installation, because the only program I want is LibreOffice. I did some research on how to install LibreOffice on Ubuntu, but I found different answers. Some recommend installing it from Ubuntu Software Center (USC), others, from the official site, and a third group prefer to install it from the terminal typing “sudo apt install libreoffice”.

Like I said, I am a complete beginner with this so I am confused on how to proceed.

What is the difference between the different options? What is the best way to install this software?

4
  • 3
    If you are interested only in using Libreoffice, you can always install it directly in your operating system of choice, BTW, what is your base Operating System? Congrats on trying Ubuntu. My answer below. – ram0nvaldez Mar 29 at 5:16
  • 3
    As mentioned above, you do not need Ubuntu to install Libreoffice. – Ken Sharp Mar 29 at 6:12
  • I want to transition from windows 10 to ubuntu, so I wanted to try it first on a virtual machine and use it like it was my only os installed. So far I like it so I am considering on just go and make it my main os – Erazzbazz Mar 29 at 14:37
  • That's a different matter then, go for it! APT based answers may be not that easy but definitely those will give you the power for taking control of your system. – ram0nvaldez Mar 29 at 16:31
5

The best way to install LibreOffice in Ubuntu is without any doubt by what you call the USC. The former USC has now been replaced by the "Snap Store", a customized version of Gnome Software. The Snap Store contains two different entries of LibreOffice. One of the entries is an install of the software through a novel approach for software packaging, i.e. "snap". The other entry is the version that comes by default with a full install of Ubuntu, and is distributed using the traditional APT software distribution system.

Just check in the Snap Store whether it is the APT or the snap version you are looking at: click on the entry, and on the page that appears, you will see the source. If that says "snapcraft", you are looking at the snap version.

From the command line, the two different versions are installed with following commands, for the APT and the snap version respectively:

sudo apt install libreoffice

and

sudo snap install libreoffice

Difference between the packages

  • APT packages are compiled and tested for a specific version of Ubuntu. During the lifetime of the Ubuntu version, the LibreOffice version will essentially remain the same. Only minor security updates are provided.
  • snap versions, on the other hand, are containerized and thus will run in a range of Linux distributions without change. That is a significant advantage of the latter packaging version. That also makes it much more manageable to regularly update the package. Therefore, you will typically see that the snap is a newer version. A disadvantage is that snaps use more disk space and, currently, still are somewhat slower during initial startup.

Which one of these two is the best? Both of these packages are officially available within Ubuntu and are installed with an established and tested framework: you will not break your system. Go for the APT version that comes with the distribution if you want maximum stability; go for the snap if you want the newest version.

3
  • 7
    Snaps cannot access /tmp either, which is a massive pain and another reason not to use them. – Ken Sharp Mar 29 at 6:11
  • 1
    and they have problems accessing network drives, like samba. The problem with /tmp means that if the user downloads a file in the web browser and wants to directly open it (not saving) then libreoffice fails to open it. – fsasm Mar 29 at 14:36
  • Snaps are of real benefit only to developers who no longer have to deal with "well it works on my machine". Always a problem for noobs. – Stephen Boston Mar 29 at 16:30
3

I would always advice using USC or the command line equivalent if there are no special needs

usc, others, from the official site, and a third group prefer to install it from the terminal typing “sudo apt install libreoffice”.

USC does sudo apt install libreoffice so those are the same. USC is using the desktop. The other one from command line.

from the official site

That can be an option if you want a newer version than Ubuntu provides. If not needed use the one from the software center.

By the way: there is a 3rd opion: using a "snap" install. Snaps are containers (so sandboxed installations). If that one is available in USC you see it mentioned in the description (also means there are TWO references in USC). The equivalent command line method is sudo snap install libreoffice.

1

I don't see anyone actually addressing why you'd choose to install from repositories vs. downloading from the official site, so...

Command line/Software Center

  • note that these are functionally the same (in the background, Software Center will run the same commands you'd run if you installed it through bash). The only difference is whether you navigate the GUI or use command line. I would recommend learning to use command line: It makes things easier in the long run.
    +You'll get automatic updates: Whenever you update Ubuntu (whether automatically through software updater, or by manually running sudo apt update and sudo apt upgrade), LibreOffice is updated to the newest version in the repositories (this, incidentally, is the main reason to use the package manager: you don't have to worry about whether you've updated program x or y; it just happens automatically, and since it's all from the repositories, you know you'll get a version that's compatible with your system.)
    +You'll get a known stable version: There are very unlikely to be any major bugs that render the software unusable
    -You'll get a known stable version: It won't contain all the newest bugfixes and features

The official website
+You'll get the latest version, directly from the source. This includes all the latest bugfixes, as well as any bells and whistles you never knew you needed(well, you likely still don't know that you need them, or care that they exist, but hey)
-The version you get may include major bugs: This is not likely for major software like LibreOffice, but finding and fixing bugs is not an exact science.
-To update, you'll have to redo the installation process: Go to the website, download the latest .apt package, and install.

PPA

  • This is the option you didn't mention. Ubuntu includes a way of adding third-party repositories to the system, allowing you to install software not included in the official repositories via apt. Some software even has official (or officially endorsed) PPAs like Wine and Pale Moon.
    +You'll get the very latest version and the convenience of automatic updates
    -You have to manually add the repository (thankfully, most PPAs come with explicit instructions on what to do)
    -(in case there isn't any official PPA direct from the developers) You'll have to trust yet another third party with the keys to your system: they just might decide to slip by an "update" that actually includes malware. This may be acceptable risk in some cases (indeed, I'm sure many of them are perfectly fine), but I would advice against making a habit out of it.

So which should you use? In case of LibreOffice, you're probably not missing out anything major by not having the very latest version, so I would advice just installing via apt (or Software Center). In the rare cases where you really want to have the latest version (Wine is one example, if you plan to do lots of gaming), use the official PPA if available, or install manually if not. I would, as a rule, stay away from PPAs that don't come directly from the developers, but sometimes you may have to make a judgement call about whether a third party can be trusted.

0

To install libreoffice use the following command:

sudo apt install libreoffice-gnome libreoffice

Other ways to install libreoffice:

  • Extracting the tarball libreoffice.*.tar.xz
  • By installing the .deb from the official website.
  • From Snapcraft.

Installing the package through apt from the official Ubuntu repositories allowing you to apply the security updates automatically during the system update because the package is maintained by Ubuntu developpers.

2
  • 1
    "What is the difference between the different options?, what is the best way to install this software?." are the questions that need to be addressed. (s)he already knows how to install as indicated in the 1st part of the question ;) – Rinzwind Mar 28 at 20:02
  • @Rinzwind See my update, please. – GAD3R Mar 29 at 7:47
0

This is how I actually install LibreOffice. Visit the LibreOffice Download page and download the deb file.

Go to the downloads folder. Then, extract LibreOffice. There will be two folders, Debs and readmes.

Then, run a terminal (Ctrl + Alt + T) and:

cd Downloads/LibreOffice/DEBS/    # Change "LibreOffice" to your LibreOffice folder name
sudo dpkg -i *.deb

dpkg = Debian package manager. dpkg -i *.deb means install(-i) debian package manager of all file which ends with deb.

You can also install it this way if you want to install anything from a snap:

snap install libreoffice

But, if you don't know what does call in snap, then you can search

snap search libreOffice

Enter image description here

Maybe, you can install by sudo apt-get install libreoffice. I am not sure; I never tried it...

Vanadium explained snap and apt very beautifully...

2
  • What do you mean by "Install Debian package manager every file which ends with .deb."? It seems incomprehensible. Please (mainly) respond by editing your answer, not here in comments (without "Edit:", "Update:", or similar - the question/answer should appear as if it was written today). – Peter Mortensen Mar 29 at 14:27
  • @PeterMortensen I think it was actually my weak English issue... Please, check that is it ok now? – Istiak Mar 29 at 15:02
-1

Ubuntu (and all Linux distributions) offers several different ways to accomplish every task. The main decision here may be to choose between a command line and a GUI, if you are a noob (as you describe yourself) it may be easier to go with the GUI, so there you have the Ubuntu Software where you can select the LibreOffice suite. Apparently it will use the snap approach, which I think the last option I would use, but this is for you, not for me, and given you are using this VM for LibreOffice only, it may be easier for you to install it this way.

I have used Ubuntu for many years, and I'd prefer to use the APT approach. It is more robust and if you use it consistently it will maintain your system neat, clean and consistent. It can be used from the command line (with apt) or via a GUI tool like the Synaptic package manager, which may be installed first from the same Ubuntu software.

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