How to add/install Ubuntu fonts in CentOS/Red Hat Linux

In this tutorial we will learn,how to add/install Ubuntu fonts in CentOS/Red Hat Linux.The Ubuntu fonts are very popular in typography.The Ubuntu fonts are funded by Canonical . Its wonderful design work and implementation has been taken care by Dalton Maag . To know about more Ubuntu Fonts, here is the link.In this practical we will install Ubuntu fonts system wide but fonts can also be installed for an individual user

System details where practical last applied:

Operating System : CentOs 6.5
Arch: x86_64
Runlevel: 3

To add/install ubuntu fonts System Wide, follow the given below steps

We will install the Ubuntu Fonts in fontconfig and will be applicable System Wide.

Step 1: Login as a root else login as super user.Download the Ubuntu Fonts from the URL http://font.ubuntu.com/

To download the Ubuntu fonts through command line

Open the terminal and type below given command


cd /root
yum install wget       (you can skip this step if wget is already installed)
wget font.ubuntu.com/download/ubuntu-font-family-0.80.zip

Step 2:Check if the directory /usr/share/fonts exist. If the fonts directory do not exist,you can create yourself.

mkdir -p /usr/share/fonts

Step 3 : Now unzip the downloaded Ubuntu fonts file

cd /root
yum install unzip  (You can skip this step,if unzip is already installed)
unzip ubuntu-font-family-0.80.zip

Step 4: Now copy ubuntu-font-family-0.80 directory into /usr/share/fonts/

cp -rvf ubuntu-font-family-0.80 /usr/share/fonts/

Inside directory ubuntu-font-family,you can see many .ttf files . (Know about ttf)

[root@CentOS-server ubuntu-font-family-0.80]# 
[root@CentOS-server ubuntu-font-family-0.80]# ls -l
total 4120
-rw-r--r-- 1 root root    865 Sep 22  2011 CONTRIBUTING.txt
-rw-rw-r-- 1 root root    155 Sep 26  2011 copyright.txt
-rw-r--r-- 1 root root  10120 Sep 26  2011 FONTLOG.txt
-rw-rw-r-- 1 root root   8980 Sep 26  2011 LICENCE-FAQ.txt
-rw-rw-r-- 1 root root   4673 Oct  8  2010 LICENCE.txt
-rw-r--r-- 1 root root    612 Sep 22  2011 README.txt
-rw-r--r-- 1 root root    183 Sep 22  2011 TRADEMARKS.txt
-rw-r--r-- 1 root root 356980 Sep 22  2011 Ubuntu-BI.ttf
-rw-r--r-- 1 root root 333616 Sep 22  2011 Ubuntu-B.ttf
-rw-r--r-- 1 root root 350420 Sep 22  2011 Ubuntu-C.ttf
-rw-r--r-- 1 root root 409608 Sep 22  2011 Ubuntu-LI.ttf
-rw-r--r-- 1 root root 415552 Sep 22  2011 Ubuntu-L.ttf
-rw-r--r-- 1 root root 366992 Sep 22  2011 Ubuntu-MI.ttf
-rw-rw-r-- 1 root root 216208 Sep 26  2011 UbuntuMono-BI.ttf
-rw-rw-r-- 1 root root 191400 Sep 26  2011 UbuntuMono-B.ttf
-rw-rw-r-- 1 root root 210216 Sep 26  2011 UbuntuMono-RI.ttf
-rw-rw-r-- 1 root root 205748 Sep 26  2011 UbuntuMono-R.ttf
-rw-r--r-- 1 root root 341324 Sep 22  2011 Ubuntu-M.ttf
-rw-r--r-- 1 root root 386440 Sep 22  2011 Ubuntu-RI.ttf
-rw-r--r-- 1 root root 353824 Sep 22  2011 Ubuntu-R.ttf
[root@CentOS-server ubuntu-font-family-0.80]# 

Step 5: Now run the fc-cache command. The fc-cache command build the information caches in directory.If you do not get any error then the fonts are successfully installed.

fc-cache -fv

You have more options with fc-cache command. for this run the command
fc-cache --help

[root@CentOS-server ~]# fc-cache --help
usage: fc-cache [-frsvVh] [--force|--really-force] [--system-only] [--verbose] [--version] [--help] [dirs]
Build font information caches in [dirs]
(all directories in font configuration by default).

  -f, --force          scan directories with apparently valid caches
  -r, --really-force   erase all existing caches, then rescan
  -s, --system-only    scan system-wide directories only
  -v, --verbose        display status information while busy
  -V, --version        display font config version and exit
  -h, --help           display this help and exit

Ubuntu Font Family is also available in Google Fonts.

Important Note: It is important to note that Fontconfig has /etc/fonts/fonts.conf configuration file, which should not be edited by hand.

Installing Ubuntu fonts for an individual user ,Here is the link

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.