Ubuntu The Complete Manual 2016
Ubuntu The Complete Manual 2016
Publishing Director
Aaron Asadi
Head of Design
Ross Andrews
Editor In Chief
Jon White
Production Editor
Fiona Hudson
Designer
Perry Wardell-Wicks
Photographer
James Sheppard
Printed by
William Gibbons, 26 Planetary Road, Willenhall, West Midlands, WV13 3XT
Distributed in Australia by
Gordon & Gotch Australia Pty Ltd, 26 Rodborough Road, Frenchs Forest, NSW, 2086 Australia
Tel +61 2 9972 8800 www.gordongotch.com.au
Disclaimer
The publisher cannot accept responsibility for any unsolicited material lost or damaged in the
post. All text and layout is the copyright of Imagine Publishing Ltd. Nothing in this bookazine may
be reproduced in whole or part without the written permission of the publisher. All copyrights are
recognised and used specifically for the purpose of criticism and review. Although the bookazine has
endeavoured to ensure all information is correct at time of print, prices and availability may change.
This bookazine is fully independent and not affiliated in any way with the companies mentioned herein.
Part of the
bookazine series
Contents
What you can ind inside the bookazine
78 Monitor Software
& Updates
Keep your system up to date
Ubuntu essentials
6
Ubuntu apps Master
88 Explore the Ubuntu 108 20 LibreOffice essentials the Linux
Software Centre
Download and install apps
Work more productively with
the LibreOffice suite platform
96 Browse with Firefox
Explore the Internet’s depths
116 Text editing with gedit
Understand this built-in app
today
100 Manage emails with 120 View images with
Thunderbird Shotwell
All your email needs covered Manage all your shots here
Get to know
Ubuntu
This free, open-source operating system has gained
a lot of momentum in recent years
Ubuntu is a user-friendly Linux-based operating system that has
found its place in every corner of the world. Best of all, Ubuntu is
absolutely free, including future updates. It is also extremely light
on PC hardware, so you can install it on computers that are three
to four years old and it’ll still run smoothly. So it’s for good reason
that Ubuntu is the most widely used Linux operating system –
for desktops and in the cloud. It boasts both community and
professional support, and Ubuntu is suitable for both desktop and
server use. But that’s not all:
Ubuntu is everywhere. Almost all computer manufacturers are
shipping models based on Ubuntu.
Ubuntu is well supported. Few other Linux distros provide the
same kind of long-term support. It is more important than ever to
provide long-term support when it comes to open source projects.
Ubuntu is easy to use. It’s easy to pick up and use, even if you
come from a Windows background (Fig 1).
Ubuntu is pretty stable. For most users, Ubuntu just works. This is
because the OS is being tweaked and ixed all the time. Since all the
latest packages are not integrated during the development cycle, it
also helps in providing better stability.
8
Get to know Ubuntu Getting started
Fig 2 (above) If successful, you will be presented with the standard Ubuntu desktop
9
Getting started Get to know Ubuntu
10
Get to know Ubuntu Getting started
11
Getting started Get to know Ubuntu
"DDPVOUTFUVQ 0QUJPOTGPSJOTUBMMBUJPO
You can install Ubuntu alongside another OS or replace it
6CVOUVOFFETUPLOPX
TPNFJOGPSNBUJPOBCPVU
ZPVTPUIBUJUDBOTFUVQUIF The Ubuntu installer will automatically detect any existing operating
QSJNBSZVTFSBDDPVOUPO system installed on your machine, and present installation options
ZPVSDPNQVUFS"TZPVNJHIU
to suit your system. Please note that the following options below
FYQFDU
XIFODPOGJHVSFE
ZPVSOBNFXJMMBQQFBSPO entirely depend on your speciic system and may not all be
UIFMPHJOTDSFFOBTXFMMBT available to you:
UIFVTFSNFOV
0OUIJTTDSFFOZPVXJMMOFFE t*OTUBMMBMPOHTJEFPUIFSPQFSBUJOHTZTUFNT
UPQSPWJEFUIFGPMMPXJOH
t6QHSBEF6CVOUVyUP
JOGPSNBUJPOUP6CVOUVy
t&SBTFyBOEJOTUBMM6CVOUV
t:PVSOBNF
t4PNFUIJOHFMTF
t8IBUZPVXBOUUPDBMMZPVS
DPNQVUFS
t:PVSEFTJSFEVTFSOBNF Out of the above four options, the most preferred is ‘Upgrade
t:PVSEFTJSFEQBTTXPSE Ubuntu … to 16.04’. This is because this option will allow you to
"GUFSUIFJOTUBMMBUJPO keep all your precious documents, music, pictures and any other
JTDPNQMFUFBOEZPVS personal iles on the computer. Installed software will be retained
DPNQVUFSIBTSFTUBSUFE
when possible and system-wide settings will be cleared.
ZPVXJMMCFHSFFUFEXJUIUIF
MPHJOTDSFFOPG6CVOUV5IF The ‘Erase disk and install Ubuntu’ option can be used if you want
MPHJOTDSFFOXJMMQSFTFOUZPV to erase your entire disk. As expected, this will delete any existing
XJUIZPVSVTFSOBNF
BOE operating system that is installed on that disk and install Ubuntu in
ZPVXJMMOFFEUPFOUFSUIF
QBTTXPSEUIBUZPVQSPWJEFE its place.
QSFWJPVTMZJOPSEFSUP When you choose the ‘Something else’ option, you will be able
QSPDFFE$MJDLUPFOUFSZPVS to conigure the partitions as you need before installing Ubuntu.
VTFSOBNFBOEQBTTXPSE
ZPVDBOUIFOQSFTT&OUFSUP It can be noted here that in order to reduce the time required
BDDFTTUIF6CVOUVEFTLUPQ for installation, Ubuntu will continue the installation process in the
0ODFZPVS6CVOUVEFTLUPQJT background while the user conigures all the important user details
SFBEZ
ZPVNBZCFJOUFSFTUFE like username, password, keyboard settings, the default time zone
JOWJFXJOHUIFIJEEFOGJMFT and so on.
5IJTDBOCFFBTJMZEPOFCZ
DMJDLJOH7JFX0QUJPOT4IPX
)JEEFO'JMFT
“After successfully installing Ubuntu,
"GUFSTVDDFTTGVMMZJOTUBMMJOH
6CVOUV
ZPVNBZBMTPXBOU you may also want to encrypt your
UPFODSZQUZPVSIPNFGPMEFS
*UUBLFTWFSZMJUUMFUJNFBOE
home folder. It takes very little time
JTQSFUUZTUSBJHIUGPSXBSE and is pretty straightforward. This is
5IJTTUBHFJTDPOTJEFSFEUP
CFBOJNQPSUBOUTUFQUPUBLF considered to be an important step
CFGPSFZPVQSPDFFEBOZ
GVSUIFSXJUI6CVOUV
before you proceed any further”
12
Get to know Ubuntu Getting started
13
Getting started Get to know Ubuntu
14
Get to know Ubuntu Getting started
Fig 8 (above) Conduct a computer and Internet-wide search from the Dash
Fig 9 (above) Navigate to the browser app for more advanced searches
15
Getting started Get to know Ubuntu
16
Get to know Ubuntu Getting started
17
Getting started Get to know Ubuntu
4FDVSJOH6CVOUV
Ubuntu is considered to be
so secure primarily thanks to
the following reasons…
t.BOZWJSVTFTEFTJHOFEUP
primarily target Windows-
based systems do not affect
Ubuntu systems.
t4FDVSJUZQBUDIFTGPSPQFO
source software like Ubuntu
are often released quickly.
t0QFOTPVSDFTPGUXBSFMJLF
Ubuntu allows security flaws
to be easily detected.
t5IFCBTJDTFDVSJUZ
concepts such as file
Fig 12 (above) Use the terminal to conduct actions using the command line
permissions, passwords
and user accounts are also
by some parameters, and then press Enter in order to perform the BWBJMBCMFXJUI6CVOUV
speciied action (Fig 12). In most cases, some type of output will Understanding these
be displayed in order to conirm that the action was completed concepts will help you in
securing your computer.
successfully, although this can depend on whether the command
is executed.
Ubuntu ofers various text editors which are installed by default.
The most commonly used command-line editor is called Vim. The
table below gives quick information about some of the important
iles in Ubuntu.
Another concept that users need to know about is mounting
and unmounting removable devices. Mounting a device means
associating a directory name with the device, and this in turn
allows you to navigate to the directory to access the device’s iles.
When you’ve inished using a device, you can safely unmount it.
Unmounting a device disassociates the device from its directory,
allowing you to eject it.
/etc/apt/sources.list $POUBJOTUIFBWBJMBCMFTPVSDFTGPSTPGUXBSFJOTUBMMBUJPO
lsb_release -a 1SJOUTPVUUIF6CVOUVWFSTJPOZPVBSFSVOOJOH
/usr/share/tomcat *OTUBMMBUJPOEJSFDUPSZGPS5PNDBU
19
Ubuntu essentials Navigate the Ubuntu desktop
Navigate the
Ubuntu desktop
Find everything you need on the intuitive and attractive
Ubuntu desktop interface, Unity
When Ubuntu irst introduced its Unity desktop,
some users threatened to move back to
Windows Vista. But as time went by, the desktop Quick-launch apps
became more reliable: as of 12.04 LTS, there Right-click on the symbol of a
running application to open a
is no real reason to dislike Unity. Unity initially short menu. Selecting ‘Lock to
Launcher’ from the available
started out as a research product trying to create options ensures that the symbol
will always remain in the bar
a GUI that was better suited to netbooks: their for quick access to that specific
application, even if it is not
extremely wide displays did not work particularly currently running
21
Ubuntu essentials Dual boot with Ubuntu
Dual boot
with Ubuntu
Get Ubuntu running alongside your existing
Windows installation
Most users who want to try Ubuntu already have desktop PCs or
laptops with the Windows OS. Ubuntu can be installed alongside
Windows and both systems will coexist just ine, without interfering
with each other.
Ubuntu’s installation wizard has an advanced disk partition stage,
where you can either trust the installer to automatically shrink the
Windows partition and let Ubuntu use the freed space, or you can
do it manually. Shrinking NTFS partitions from Linux is considered
stable enough and if you didn’t have any problems with your C
drive in Windows (such as severe fragmentation), Ubuntu will resize
it correctly. The installer will create the mandatory root partition (/)
in the free disk area and sometimes also create separate partitions
for user data (/home) and swap space.
After the installer copies Ubuntu iles to the root partition, it’ll
perform post-installation arrangements and install the GRUB2
bootloader into the master boot record (MBR) of the hard drive
on older systems, or GRUB2-EFI into the dedicated FAT32 partition
on modern systems with Windows 8 or 10 and a GPT-formatted
drive. The Ubuntu installer supports the Secure Boot feature of
many modern Windows PCs and installs the GRUB2-EFI bootloader
correctly. After rebooting, you’ll see the GRUB2/GRUB2-EFI interface,
where you can choose Ubuntu or Windows.
You will ind that it’s possible for you to access Windows iles from
Ubuntu, but not vice versa.
Discover bootloader menu Find out how to use the GRUB2 bootloader
“You will ind that it’s possible for you to access Windows iles
from Ubuntu, but not vice versa”
23
Ubuntu essentials Dual boot with Ubuntu
Discover
bootloader menu
The automatic partitioning Fig 1 (above) The installation type has
been automatically detected
option in the Ubuntu
installer is definitely more
comfortable for non-tech- Dare to go for manual setup
savvy users, but it does have
Ubuntu’s installation program has been polished in recent years
certain limitations, such as
the inability to add an extra and now looks very smooth. Soon after completing basic steps
Home partition or define (like language selection), a user faces the irst real obstacle during
the swap space manually.
the ‘Installation type’ step. You can see above that Ubuntu has
Let’s use the fully fledged
partitioning method by automatically detected our Windows 7 copy and ofered the simple
choosing the ‘Something solution that does not require any extra user input (Fig 1). Here you
else’ option in the previous
can let the installer automatically guess what OS you already have
step, or by clicking the
‘Advanced partitioning tool’ and how to keep it intact. It’s safe, and you’ll be able to deine how
link in the ‘simple’ mode. much space you want to allocate for Ubuntu in the next step.
First, you’ll need to resize
Note the second option with the red Warning label – we are
the NTFS volume and make
it smaller by some number going to install Ubuntu and keep Windows working, so do not
of gigabytes. Make sure that choose this. The last option is a path to a more expert-like drive
you don’t have excessive
allocation program. Dual-booting in UEFI mode introduces more
hard disk fragmentation
in Windows, otherwise routines for the Ubuntu installer. If you’re unsure what to choose,
you may turn your NTFS go with auto mode. If your system uses a BIOS interface, you can
volume in Ubuntu installer
repartition your drive manually.
unusable. Try to guess how
much space you’ll need in
the unallocated area after
shrinking. For instance,
10GB looks like the bare
minimum – go with at least
“The automatic partitioning option in
twice as much as that for the
Ubuntu root partition. Think
the Ubuntu installer is deinitely more
ahead to cover aspects like comfortable for non-tech-savvy users,
swapping and a separate
partition for /home.
but it does have certain limitations”
24
Dual boot with Ubuntu Ubuntu essentials
25
Ubuntu essentials Customising the desktop
Customising
the desktop
Change desktop settings and add a personal touch
to Ubuntu’s exterior
01 The taskbar panel or the Launcher works just fine, but sometimes you
need to get rid of some of the default icons and add your favourite apps
instead. To remove an icon, right-click on it and select the ‘Unlock from Launcher’
option. To add an application to the taskbar you first need to find it in the Dash
and drag it to the desired position on the taskbar. You can also drag and rearrange
the existing icons on the taskbar. Use the Appearance>Look section in System
Settings to change the taskbar icon size. If you make it smaller, more icons will fit
there, which is helpful for small displays. Also, check the Behaviour tab for auto-
hiding option, enabling multiple workspaces and more.
26
Customising the desktop Ubuntu essentials
Tweak desktop settings Use related sections in Ubuntu’s System Settings app
27
Ubuntu essentials Customising the desktop
28
Customising the desktop Ubuntu essentials
04 The Unity desktop lets you assign an action to any corner of the screen,
plus to any of its sides. In order to do this, we need to access advanced
window manager settings. Launch Unity Tweak Tool and go to Window
05 The ‘System Tray’ area resides
the far-right corner of the
top bar. Some indicators can be
Manager>Hotcorners. There are eight areas (four corners and four sides) with configured individually but for more
a drop-down menu next to each, letting you choose what action will be control you will need to deal with
performed once you move your mouse to the respective area of the screen. dconf-editor (Fig 2). This twin-panel
You can set a corner or a side to toggle the desktop (for example, minimise all app has a categories list on the left
windows or bring them back on), spread windows or show workspaces. All and the contents on the right allows
changes are applied instantly, and you can check by driving your mouse to a you adjust aspects of Unity indicators.
corner or side where an action has been assigned. Go to com>canonical>indicator and
explore the parameters of each one.
You can turn indicator presence on
“Check hot corners have been applied the top bar on and off by toggling
the ‘visibility’ parameter and change
by driving your mouse to a corner or side indicators’ display format by playing
with ‘show-*’ parameters. This way
where an action has been assigned” you can keep your system tray area
clean and tidy.
29
Ubuntu essentials Discover System Settings
Discover
System Settings
Discover system details, manage user accounts and
conigure hardware
31
Ubuntu essentials Discover System Settings
32
Discover System Settings Ubuntu essentials
33
Ubuntu essentials Tweak your security settings
Tweak your
security settings
Make sure your Ubuntu setup provides proper
privacy protection
34
Tweak your security settings Ubuntu essentials
Enable uncomplicated
“A good password contains lower and firewall
uppercase letters, special characters and
digits. Thankfully, Ubuntu can help you” 03 Firewall is an effective tool for
blocking network intrusions
from the outer world and limiting
suspicious network activity in both
directions by blocking certain network
Enable automatic security updates packets in IPv4 and IPv6 protocols.
Linux has the ‘iptables’ tool for doing
02 Let’s go a little further and make Ubuntu receive important security updates
without any interaction with a user. This feature is very useful because not all
updates are installed without your awareness, but only security-related ones that fix
this job, but it is not very intuitive for
newcomers. Luckily, Ubuntu has a nice
front end to iptables called UFW – the
vulnerabilities, critical bugs, memory leakage and so on. To enable this feature, first Ubuntu FireWall (Fig 1) in its standard
start by installing the package along with the required scripts: repositories. Install it with:
35
Ubuntu essentials Tweak your security settings
Find the security settings Check out the Security & Privacy tools
Usage activities
Protect your PC record
If your PC suspends or turns Here is the global switch that
off the display after a period of triggers file and application
inactivity, you can set Ubuntu Related settings usage logging. You can turn it
to require a password in order The first link takes you to the off with just one mouse click, What about online
to resume using the PC User Accounts subsection, or alternatively decide to make search results?
where you can change your more precise adjustments A rather controversial feature,
password; the second link is for which is why Canonical decided
Power settings, where you can to put in the Off mode in 16.04.
change the time period before You can always change the
you system suspends trigger’s position here
36
Tweak your security settings Ubuntu essentials
04 The ‘sudo’ is a command that you can put before another command in
order to make it run with root privileges (Fig 2). You can use sudo anytime
and for any command but practically you only need to do so if you haven’t got
enough permissions with your regular user account – for managing printers, or
in case you need to write a file into a directory outside your home for example.
Ubuntu comes with sudo enabled by default, which lets you run any command,
but requires entering your current password (not the root password, root is
disabled in Ubuntu by default). You can change the sudo settings by issuing the $
sudo visudo command, which will open the /etc/sudoers file in the Nano editor.
You can discover the magic of sudo with $ man sudo, but there are also instant
solutions you can use by changing the following line:
37
Ubuntu essentials Find your way around Dash
Dash serves as the universal window for finding content, but as there are several
types of content on the computer, the results are segregated into smaller scopes
or lenses (Fig 1). Dash has a series of scopes that logically separate the results and
provide views to your files, folders, applications and data. The following scopes are
installed by default: Home, Applications, Files, Videos, Music, Photos and Online
(social media).
When you launch Dash, you’ll see a search bar on the top. This is common to all
scopes. Simply start typing and a list of results will appear below. Note that this is the
home lens. The home lens is the default and will appear unless you explicitly select
another lens. You can explicitly select a lens by clicking one of the options on the
bottom bar (when Dash is active). Other lenses will only show the items from the
corresponding scope that is relevant to your search query. For example, if you type
text as a search query, home lens will show the results from all over the computer,
but if you change it to an application lens, you’ll see the text editor as the first result.
39
Ubuntu essentials Find your way around Dash
40
Find your way around Dash Ubuntu essentials
“The top-right corner of each lens has the ilter option. You can
click on the ‘Filter results’ link to expand the options. Note that
the options are contextual”
Navigate the Dash display Get familiar with the display and ilter options
Text area
This is the space where Reference
you type your queries into This is the Dash result section
Dash. As you type in the that displays references related
text, you will see the space Weather to the search query. You can
below being populated Dash automatically detects the see the definition, images and
with results dynamically scopes that may be relevant to more related to the search Categories
the search query. Since there is a query here You can select the categories
place called Dash, it automatically from which you’d like to
displays the weather forecast for view results by choosing the
that location categories here
Applications Scopes
This section displays results Dash, by default, shows results
related to the applications from all the available scopes.
scope. You’ll see all the You can limit the results to
applications that match the More suggestions specific scopes by selecting Sources
search query here This is the section that displays them here This section allows you to
results from online shopping select the sources from where
websites and other sources Dash will look for results when
that are relevant to the search you enter a search query
query entered
41
Ubuntu essentials Understanding the file system
Understanding
the file system
Learn about the ile system in Ubuntu to keep
everything organised
One of the most complex things about any Linux-based computer
is probably its ile system. There are so many iles and folders that
serve so many diferent purposes. To a newcomer just getting
started with Linux, all this appears like a huge maze. This calls for a
basic, yet clear understanding of how iles and folders are organised
in Linux, and speciically Ubuntu. This is exactly what we are going
to do in this guide. Let’s start with the basics.
Ubuntu (like all Unix-like systems) organises iles in a hierarchical
tree, where relationships are thought of in terms of child and
parent. Directories can contain other directories as well as regular
iles. Any element of the tree can be referenced by a path name
– absolute or relative. An absolute path name starts with the
character ‘/’ (identifying the root directory, which contains all
other directories and iles), then every child directory that must be
traversed to reach the element is listed, each separated by a ‘/’ sign.
A relative path name is one that doesn’t start with ‘/’; in that case,
the directory tree is traversed starting from a given point, which
changes depending on context, called the current directory. The
fact that all iles and directories have a common root means that,
even if several diferent storage devices are present on the system,
they are all seen as directories somewhere in the tree, once they are
mounted to the desired place.
Understand file listing Learn the meaning of each column in the ile listing output
Special files
File listing command Wherever you issue the ‘ls’
‘ls’ lists all the files in the command in Linux, you’ll see
First column current directory and the ‘-la’ these two files listed on the
The first character indicates extension shows the files in top. However, these aren’t
whether it is a directory or long format, along with all the visible if you inspect the same File names
a file. The other nine characters hidden files. When executed directory via the GUI. The This is where all the directory/
indicate the permissions from the root directory, it single dot indicates the current file names are listed. You can
for file owners, groups and shows all the directories in the directory; double dot, the see all the top-level Linux
everybody else top-level hierarchy parent directory default directories here
43
Ubuntu essentials Understanding the file system
02 Unix abstracts the nature of tree hierarchy entirely, and the root directory is
the base of all the folders in the Ubuntu hierarchy. Indicated by the ‘/’ sign,
the root directory contains all the other folders (Fig 2). Though the root directory
is conventionally referred to as ‘/’, the directory entry itself has no name – its name
is the empty part before the initial directory separator character (/). All file system
entries, including mounted file systems, are ‘branches’ of this root. It is because
of this layout that all the absolute paths in Unix systems start with ‘/’. Even if there
are several physical or virtual storage devices attached to your computer, all the
folders will be shown under the root directory.
Note that this is not to be confused with the /root directory that serves as the
home directory for the root users.
44
Understanding the file system Ubuntu essentials
03 Let ‘s now see the various important directories present under the root directory and get an idea of which ones
serve what purpose.
/bin is a place for most commonly used terminal commands, such as ls, mount, rm, etc.
/boot contains files needed to start up the system, including the Linux kernel, a RAM disk image
and bootloader configuration files.
/dev contains all device files, which are not regular files but instead refer to various hardware devices on the system,
including hard drives.
/etc contains system-global configuration files, which affect the system’s behaviour for all users.
/home this is the place for users’ home directories.
/lib contains very important dynamic libraries and kernel modules.
/media is intended as a mount point for external devices, such as hard drives or removable media (CDs, DVDs etc).
/mnt is also a place for mount points, but it is dedicated specifically to ‘temporarily mounted’ devices such as network
file systems.
/opt can be used to store additional software for your system which is not handled by the package manager.
/proc is a virtual file system that provides a mechanism for the kernel to send information to processes.
/root is the superuser’s home directory; it’s not in /home/ to allow for booting the system even if /home/ is not
available.
/run is a temporary file system available early in the boot process where ephemeral run-time data is stored. Files under
this directory are removed or truncated at the beginning of the boot process.
/sbin contains important administrative commands that should generally only be employed by the superuser.
/srv can contain data directories of services such as HTTP (/srv/www/) or FTP.
/sys is a virtual file system that can be accessed to set or obtain information about the kernel’s view of the system.
/tmp is a place for temporary files used by applications.
/usr contains the majority of user utilities and applications, and partly replicates the root directory structure, containing
for instance, among others, /usr/bin/ and /usr/lib.
/var is dedicated to variable data, such as logs, databases, websites and temporary spool (email etc) files that persist from
one boot to the next. A notable directory it contains is /var/log, where system log files are kept.
45
Ubuntu essentials Sharing files in Ubuntu
Sharing files in
Ubuntu
Learn to create ile servers to share data from your
Ubuntu system
The default Ubuntu ile manager Nautilus ofers an easy-to-use
interface to help you share iles across systems. Behind the scenes,
however, Samba is running the show.
Samba is a software suite for seamless ile and print services. It
implements the Server Message Block (SMB)/Common Internet File
System (CIFS) protocol for Unix systems, supporting ile and printer
sharing across Windows, OS X and other Unix systems.
Samba is freely available, unlike other SMB/CIFS implementations,
and so is widely used on various systems. You can facilitate the ile
sharing between Ubuntu and Windows computers by coniguring
Samba as a ile server on one of the systems.
Samba can do several other things including acting as a server
for SMB clients: you can share printers, including PDF pseudo-
printers so all the computers in your network may write PDF iles.
Samba can also act as a domain controller in a Windows network
(authenticating users, and so on) and even help using a Windows
domain controller to authenticate the users of a Linux/Unix
machine. However we will focus only on the ile sharing aspect of
Samba in this feature.
Samba is not installed by default in Ubuntu 16.04 and so to start
ile sharing you’ll have to install Samba. We’ll see the installation
process and the steps to set up ile sharing in next sections.
01 To share a directory, you must have permission to access the directory. For
demonstration purposes, let’s take a folder from the user’s home directory,
such as Documents.
Go to your home directory. Right-click on the Documents directory and in
the pop-up menu, select Local Network Share. Then check the ‘Share this folder’
checkbox. If Samba is not installed, you will get a pop-up menu: ‘Sharing service is
not installed’. Select ‘Install additional software’ and then click Install (Fig 1). If you
get an error message that the samba .deb could not be found, open a terminal
and update apt-get like this:
Try again and Ubuntu will download and install Samba. Let’s try sharing the folder
again. Right-click on the Documents directory and in the pop-up menu, select
Local Network Share. Next, check the ‘Share this folder’ checkbox. And then click
the Share button. That’s it; the directory should now be shared and accessible
from Samba clients. You can also install Samba GUI for Ubuntu. Just type:
…or search for Samba in the Ubuntu Software Centre and install it from there.
Once installed, just search Dash for system-config-samba.
47
Ubuntu essentials Sharing files in Ubuntu
Samba clients
03 We have learnt about sharing files via the GUI, but directly editing the
configuration file gives you several more options and flexibility to implement
things exactly how you want to. So, let us now learn how to enable sharing via the
configuration file. The main Samba configuration file is located in /etc/samba/smb.
conf (Fig 2). The default configuration file has a significant number of comments
in order to document various configuration directives. First, edit the following key/
value pairs in the [global] section of the config file:
Workgroup = EXAMPLE
Security = user
[share]
comment = Ubuntu File Server Share
path = /srv/samba/share
browsable = yes
guest ok = yes
read only = no
create mask = 0755
48
Sharing files in Ubuntu Ubuntu essentials
Sharing files with Samba GUI Learn to share iles with Samba
49
Ubuntu essentials Manage drives with Disks
Manage drives
with Disks
Manage hard drives, SSDs and removable media
with Ubuntu’s Disks tool
01 Sometimes new hard drives arrive with no partitions at all and Disks will
show them as a monotonous rectangle labelled as ‘Unknown’. You may
now choose what you want to do. if you go with an upper ‘gear’ button and
format the whole disk, you will only create a partition table, not volumes. There is
the legacy MBR (Master Boot Record) type, and the modern GPT (GUID Partition
Table). The first one is compatible with everything, the other is required by new
PCs with UEFI boot and also by large disks (>2TB). Next, you may want to create
the actual volume by clicking on a volume-specific ‘gear’ button below and again
choosing the Format option. If you plan to access your disk from Windows, use
the NTFS filesystem. Otherwise, for Linux-only usage, the best option would be to
go with Ext4.
50
Manage drives with Disks Ubuntu essentials
Manage your drives Disks ofers a very neat layout with lots of powerful features
51
Ubuntu essentials Manage drives with Disks
52
Manage drives with Disks Ubuntu essentials
04 A hard drive image is a very handy thing compared to plain file backups.
It stores all drive structure, bootloader records and all other drive details,
letting you replicate your setup onto another physical drive. Again, in case of an
ageing drive, which you feel can break at any time, there’s no better way to save
it other than create an image. Depending on what ‘gear’ button you use, you
can either create an image of the whole drive, or just the current partition. When
you choose the ‘Create Disk Image’ option, Disks will prompt you to choose a
destination directory for the image file. Note that it must be saved on another
physical drive. Later on you’ll be able to restore the drive form the image file using
the ‘Restore Disk Image’ option. Fig 2 (below) Use Disks to apply
timeout settings on your system
53
Ubuntu essentials Get to grips with the Linux command line
Get to grips
with the Linux
command line
Well-chosen words can save you jumping through
GUI hoops, so ensure you use the right commands
The command line may be an older interface, but the reason
it’s survived is the power to tell the computer, in a few apposite
commands, exactly what you want. For example, a single command
can copy all of the MP3 and MP4 iles in a directory to a backup
disk or a machine elsewhere on the network – or anywhere else on
the Internet.
Many people’s irst encounter with a computer – perhaps at
university in the 1970s or 1980s – was seated at a dumb terminal,
known as a console, connected to a distant, and very large,
computer. Nowadays, computers can be the size of a credit
card – like the Raspberry Pi – but the old-fashioned terminal is
remembered in the form of the terminal program that gives you a
command-line interface to Ubuntu.
Depending on which lavour of Ubuntu you are running, the
terminal may have a diferent name, but type ‘term’ into the app
search of Unity Shell, or your menu, and you will bring up at least
one choice of terminal. Open this up and you should see a fairly
empty-looking window. Don’t be scared of that blinking cursor –
usually the ‘$’ sign, known as the ‘dollar prompt’. It’s waiting to do
whatever you tell it. You just need to know the right words – or
commands – to get it going.
Here’s an easy one for you to try irst: type evince into the
terminal - we’ll put the instructions you need to type into bold, so
you can see commands more clearly; always press Enter afterwards,
to let Ubuntu know it’s now got to do something.
Provided you didn’t mistype, you’ll have just opened Ubuntu’s
PDF reader, without using a GUI menu or shortcut item.
54
Get to grips with the Linux command line Ubuntu essentials
55
Ubuntu essentials Get to grips with the Linux command line
Tab complete
If you think that’s a lot of typing, try hitting the Tab key after a couple of
letters of each word. Where there’s only a single possible completion, the
word will be automatically filled in. Two tab clicks brings up suggestions
where there are multiple possibilities.
If you want to know more about a command, they (almost) all have
manuals – or man pages (Fig 3). man ls will tell you all about options for ls;
ls will tell you about the manual command itself.
56
Get to grips with the Linux command line Ubuntu essentials
Looking inside a file is all very well, but often we need to quickly change
something inside it.
In this example, we’re going to use Nano, a command-line text editor (Fig
4). There are many more powerful editors – and many a little friendlier, too
– but Nano is included in Ubuntu, and many other flavours of Linux, so it’s
handy to know the basics.
We’ll edit the ~/.bashrc file, a collection of customisations for the shell
environment; don’t worry that much of it won’t yet make sense. To offset
the risk of damage to your command environment, back up the file first: cp
.bashrc .bashrc.bak – then nano .bashrc.
Find the section with the alias commands near the end. Note that the
ones with a # in front of them are inactive (said to be commented out)
– remove the # to get one to work next time you log in or open a new
terminal session.
You can use the arrows to navigate to the text you want to edit; delete
and type in new text as required. Nothing too strange so far, until you’ve
finished: note those two lines at the bottom of letters preceded by a ^
(caret). These are the keyboard commands – the ^ represents the Ctrl key –
type ^O (hold down the Ctrl key and hit O), and your work will be saved; hit
^X and you’ll exit Nano.
You can set a temporary alias directly, which will last until you close the
terminal down (Fig 5):
57
Ubuntu essentials Get to grips with the Linux command line
No attachment?
While the protection offered by permissions is very useful, they are also
there to trip up the unwary. For example, using sudo, you may have copied
files from another user’s home folder. Unless you change the ownership
(see opposite), you may be left scratching your head when you try to attach
the files to an email, and they just won’t stick – because you don’t even
have permission to read the files!
58
Get to grips with the Linux command line Ubuntu essentials
Octal code
Long listing The rwx – read / write / execute
Running ls -l lets you see who owns permissions – are given respective
a file or folder, and who has permission values of 4, 2 and 1. To give a file read
to read, write and run software. Three + write + execute permissions, 4, 2 and
groups of rwx in the listing apply, 1 are added to give 7. For just read and
respectively, to the named user, the execute, 4 + 1 = 5. Applying the former
named group, and everyone else left to user and group, and the latter to
‘other’, chmod 755 file.txt.
59
Ubuntu essentials Get to grips with the Linux command line
60
Get to grips with the Linux command line Ubuntu essentials
61
Ubuntu essentials Use GNOME Terminal & Xterm
Use GNOME
Terminal &
Xterm
Explore the basics and beneits of the terminal
emulators in Ubuntu
01 Every Linux distribution uses Bash (Bourne-again shell) in text mode and
graphical mode within a terminal emulator, including Xterm and GNOME
Terminal. Bash has a very rich set of supported commands, but the most useful
feature comes from its popularity; all Linux users use their terminals with the
same syntax. However, there are other shells – such as a highly customisable ZSH
with an even wider feature set, or CSH with a built-in scripting language – that
have similarities with the C language. To change the default shell from Bash to
something else in GNOME Terminal, go to Edit>Profile Preferences, switch to the
Title and Command tab, enable the ‘Run a custom command instead of my shell’
option and put the name of your desired shell in the Custom Command field.
02 Let’s make the GNOME Terminal look a little more personal by changing
text font, colour and background (Fig 1). Go to Edit>Profile Preferences and
switch to the Colors tab. Uncheck the ‘Use colors from my system theme’ option
and choose any combination of colours for text, text in bold and background.
There is a list of good presets in the ‘Built-in schemes’ drop-down menu; it can
save you from an agony of choosing. To change the font itself, go to the General
tab and uncheck the ‘Use the system fixed width font’. After that, you’ll be able to
select another Mono font.
63
Ubuntu essentials Use GNOME Terminal & Xterm
Save yourself time Working with terminal emulators is easier than you’d think
Edit your
terminal profile Try a fail-safe Non-distracting
Change the title, cursor solution scrollbars
shape, scrolling options and Xterm is relatively old, GNOME Terminal drew ugly,
command behaviour, as well however, it delivers a pure Bash thick scrollbars in the past.
as colours, fonts, some historic experience without any bells Sometime later, Canonical
legacy stuff (like Backspace and whistles. Xterm comes in applied its overlay bars, and
and Delete-key behaviour) every OS that uses X.org (all removed the 1-pixel outline
and more Linux distros do) around the terminal frame
64
Use GNOME Terminal & Xterm Ubuntu essentials
03 Knowing tricks for GNOME Terminal in Ubuntu can save time and increase
productivity. We start with the simplest: launch the application using the
Ctrl+Alt+T sequence anywhere in Unity. When browsing your files in Nautilus,
it is useful to open a terminal window for the current directory. Nautilus can do
it when you right-click on an empty space within a view area and select ‘Open
in Terminal’, but this feature is not enabled by default in Ubuntu. Fix it with the
following command:
then restart the file manager. When you need to copy or paste text, use Ctrl+Ins
and Shift+Ins respectively, instead of laboriously right-clicking menus. To clear
the input, you can either cancel a command with Ctrl+C, or clear what has been
written with Alt+R.
04 Working in the terminal goes long into the history of Linux and UNIX,
so it’s no wonder we have a decent number of discovered Easter eggs
and jokes that bring in some fun and help you to feel more comfortable in the
terminal. Start with $ sudo apt-get install moo to bring up a jolly cow (Fig 2),
find another Easter egg with $ aptitiude moo and then $ aptitude --v moo
and add an extra ‘v’ three more times to see a snake that has eaten an elephant.
The $ sl shows a steam locomotive and finally the $ fortune | cowsay
shows a cow that tells your fortune. However, to finish up, let’s do something
massive and change our boring GNOME Terminal to a Hollywood Technodrama
showcase, mimicking an FBI command centre (Fig 1, page 63):
65
Ubuntu essentials Secure files with Déjà Dup
Secure your data quickly Déjà Dup is an intuitive app for managing backed up iles
“If we had a crystal ball, we’d use it. But the fact is that nobody
knows when things will go wrong”
68
Secure files with Déjà Dup Ubuntu essentials
69
Ubuntu essentials Use Startup Disk Creator
70
Use Startup Disk Creator Ubuntu essentials
Get a live Ubuntu system Use a regular USB lash drive or any mass-storage device
Operating system version Copy the files Capacity and free space
Sometimes it’s not clear exactly which Check everything one more time and You can find the total size of the media as
version of a system is inside an ISO, or press the Make Startup Disk button. well as the amount of free space on it. This
what is on that unlabelled optical disc. The application will show a progress feature is designed for USB sticks that are
The column entitled OS Version extracts dialog and copy the files onto the target formatted to FAT16 or FAT32 file systems
necessary details USB medium and may contain user data
71
Ubuntu essentials Use Startup Disk Creator
Select the proper source sharing the results will be welcome. USB card reader. Virtually everything
If you have an Ubuntu-compatible that can be connected as a USB
system on CD or DVD, it will be a good mass-storage device in Linux will work
01 Startup Disk Creator is designed
to work with Ubuntu and other
systems derived from it. Here is a short
idea to transfer it to USB and benefit
from higher boot speed, better
fine (Fig 1), including odd things like
your smartphone’s internal storage.
and incomplete list: Kubuntu, Linux compatibility and persistent storage. Startup Disk Creator doesn’t wipe any
Mint, Xubuntu, Lubuntu, Ultimate- data from FAT32 volumes once there
Edition, elementaryOS, Peppermint Prepare the target is enough space there for a source
One, Peppermint Ice, Deepin and image. Although, it is recommended
to use a clean flash drive or at least
Zorin OS. Other flavours of Linux,
especially those non-Debian based,
might not work with Startup Disk
02 Common target devices are
flash drive – also known as a
USB stick or thumb drive – an external
format it to avoid issues resulting
from heavy use of that flash drive (for
Creator. If you have a free target USB USB hard drive, an SD card or any other instance, a flash drive might suffer
medium, testing other Linux OSs and memory card connected through a from fragmentation).
can install extra software or remove Disk Creator adds the Ubuntu
Create a persistence file something unnecessary and keep it bootloader to the FAT32 volume
after shutting down or rebooting the of your USB medium, so that it can
73
Ubuntu essentials Unleash the Archive Manager
Unleash the
Archive Manager
Make use of this small accessory that sits inside
your Ubuntu system
Archive Manager is a small tool for opening compressed iles and
creating your own archives. Years ago, when people had small hard
drives, Archive Manager was king of the hill. It’s still an important
part of the standard desktop experience, as it is the easiest way to
unpack downloaded archives or combine many iles into one (Fig 1).
The standard Ubuntu Archive Manager follows the generic
naming policy and therefore doesn’t have any special name
(together with Disks, Backups and so on). However, Ubuntu had
taken it from the GNOME desktop, where the archive manager is
called File Roller. You can check it out by launching the $ file-
roller command in the terminal in Ubuntu. When launched
separately, the File Roller interface looks quite empty as because it is
designed to show .contents in the largest area of its window.
Fig 1 Compress files with the archive manager Fig 2 Protect files with a password
75
Ubuntu essentials Use the Disk Usage Analyzer
Dive into statistics When you see the resulting ring chart, hover
There are no limitations with which directory you your mouse over a slice to see the details. Click
want to analyse. Disk Usage Analyzer lets you a slice to dive in and set it as a top directory. The
open any directory, be it a local or remote one. chart will adjust automatically and you will see
Click the small ‘gear’ icon in the top-right corner more details about what content inputs to overall
to open the desired location. If it is a remote one, directory weight. The left part of the screen
please use the ‘Scan Remote Folder’ option and compliments the chart with a tree view, with
provide the correct address, for example Samba extra columns for usage percentage, size and
share addresses start with smb://. number of items.
Switch between graphical views actually works better when you need to estimate
This ring chart isn’t the only way you can get a the relative sizes of diferent units. A treemap
graphical representation of data. In the lower right- may be hard to understand when you irst look
hand corner of the application you’ll notice two at it, but it does help when you know how it’s
buttons that let you switch between ring chart built. Disk Usage Analyzer irst draws the largest
and treemap modes. Treemap is an alternative rectangle for your top-level drive or directory
method of data visualisation with a strong focus and then recursively subdivides it into smaller
on the size of units. rectangles according to the size of the content
The main diference between a ring chart and a inside. Larger rectangles display their names
treemap is that the latter shows all units together instantly, others will give more information once
along with subdirectories and large iles. This hovered with a mouse.
77
Ubuntu essentials Monitor Software & Updates
Monitor
Software &
Updates
Add more application sources and keep your
system up to date
Ubuntu comes with pre-installed applications and accessories for
basic computing tasks and activities. Software & Updates lets you
customise the standard set of software sources, conigure updates
and manage additional drivers. A software source is a general term
that includes both online repositories and local media. You can turn
standard Ubuntu software source on and of, manage third-party
source and authenticate them with signing keys. With Nvidia or
AMD graphics, you can install a proprietary driver, but it cannot be
included in Ubuntu right away due to license restrictions.
79
Ubuntu essentials Work with Universal Access
Work with
Universal Access
Conigure accessibility settings to make Ubuntu
more user friendly
Ubuntu is a friendly place for everyone, including people with
Type the way you
need to reduced capabilities or disabilities. If you need to use special settings
for a more comfortable user experience in Ubuntu, there is a
The Typing tab in Universal dedicated subsection called Universal Access inside System Settings.
Access houses a list of options If you want to, you can also launch it separately by searching its
that help input data using
a keyboard for those who name in the Dash or by using the $ unity-control-center
are unable to type and need universal-access command in the terminal. Universal Access
assistance (Fig 2). The most consists of a large number of settings divided into four individual
noticeable option here is the
on-screen keyboard switch categories: seeing, hearing, typing, and pointing and clicking. Each
that enables text input using category has switches that improve usability and make the most
mouse clicks. The on-screen out of Ubuntu. Ubuntu ships with a high-contrast icon theme and
keyboard will appear after
you re-log in to a session. It the Large Text switcher, both of which help visually impaired people
looks like a desktop widget see more on their screens. There is also a screen reader (Fig 1), which
that flows at the top of any pronounces window titles and messages, an on-screen keyboard,
windows. There are various
keyboard tweaks that can advanced sound notiications and more.
ease input in some cases,
such as sticky keys (treats a
sequence of modifier keys as
Using the keyboard as a cursor
a key combination), slow keys If moving a mouse in a regular manner is uncomfortable, you can
(puts a delay between when control the mouse cursor from a keyboard using the arrows. This
a key is pressed and when it
is accepted) and bounce keys
accessibility feature can be enabled by going to the Pointing &
(ignores double pressing a Clicking tab and putting the Mouse Clicks switcher on. There are
key in a short period). This also two ways to trigger a mouse click without clicking its buttons.
can be complemented with
extra audible notifications,
The irst tweak is to simulate secondary click in double-clicking by
such as beeping when holding the left mouse button down for some time. Second, you
certain keys are pressed. can simulate a click by hovering a mouse cursor over an item and
The on-screen keyboard in
Ubuntu can also be used
waiting longer. For either, there are helpful sliders that let us adjust a
for extra security if you feel delay. Regular mouse settings in the Mouse & Touchpad subsection
like the use of a physical also contribute to a more lexible mouse performance. There you
keyboard can compromise
your privacy.
can lower the double-click delay, change cursor speed and switch
buttons arrangement if you need a mouse for left-handed use.
80
Work with Universal Access Ubuntu essentials
81
Ubuntu essentials Configure network connections
Configure
network
connections
Setting up a network connection in Ubuntu is easy
Those who only need to plug their Ethernet cable into their
computer’s network port in order to have an instant access to
the Internet can skip this section (perhaps those running Ubuntu
inside a virtual environment can do that too). The majority of
Linux newbies, however, often need assistance in connecting
to the Internet or changing their network parameters. During
the last decade, almost every Linux distribution has relied on
NetworkManager – a stable, feature-rich and intuitive network
handler for Linux. The Unity desktop in Ubuntu has a tight
integration with NetworkManager by ofering a network indicator
on the top bar and a standalone graphical utility called Network (Fig
1). You can search for it in Dash, open it as a subsection in System
Settings or launch from command line ($ unity-control-center
network). Both wired and wireless network connections can be
added and modiied or even removed here.
82
Configure network connections Ubuntu essentials
83
Ubuntu essentials Connect with Online Accounts
Connect with
Online Accounts
Enjoy a more convenient integration with online services in Ubuntu
Online social services are already a part of everyday life for an average user. Most of us use these services
for connecting with friends and relatives, for sharing photos, videos and other iles. Almost every online
service requires authentication, which is commonly about registering an account and using it later for
accessing the personal part of a service. Ubuntu simpliies the general experience with online services
by eliminating the need to sign into one account several times in diferent applications. It also makes
using local applications easier because it is much more convenient to provide your username and
password on a classic login web page than to have the hassle of local application settings. A good
example is the Evolution email client. Years ago people had to remember incoming and outgoing
server addresses, ports, security settings and the authentication method. Now all you have to do is
provide your username and password for your email service in Ubuntu’s Online Accounts – when you
log in there Evolution will already be conigured and automatically display your inbox.
84
Connect with Online Accounts Ubuntu essentials
in a built-in browser window, right there in Online Online Accounts lets you enable, disable and
Accounts. You can even add more than one change options of added entries at any time. After
account of the same service, or add accounts you are done, you can launch Empathy and start
from various diferent services to one application. chatting immediately.
85
Ubuntu essentials Use System Monitor
Use System
Monitor
View and manage system resources using
the System Monitor app
System Monitor is a tool for managing running processes and
Find out details
about file systems monitoring system resources. It is one of many accessories
borrowed from the Gnome desktop. You can run from Dash or
The File Systems tab displays from command line ($ gnome-system-monitor). The application
a table of all file systems that looks and works similarly to its analogues in Windows and OS X, and
are currently mounted in
Ubuntu. You can find out the contains three logical tabs: Processes, Resources and File systems.
device name, file system type, Launch the application with a speciic tab showing by using
mount point, total capacity command line parameters ‘-p’ for processes, ‘-r’ for resources and
and available disk space. Of
course, you can find out a ‘-f’ for ile systems. Launching with the File Systems tab shown can
similar set of information in be done with the ‘$ gnome-system-monitor -f’ command line.
Ubuntu’s disk utility (Disks, System Monitor is used to tackle system sluggishness. You could
p.50), but System Monitor
offers a more comfortable also use the CPU load graph to ind out if hardware-accelerated
view, which lets you quickly video output really works.
analyse how much space is
left on your device and sort
them by various criteria. Manage system processes
The Used column doubles Each application in Linux creates at least one process. Some
the information about free
processes refer to graphical applications, others run in the
disk space, but shows it in
the form of a percentage background and provide service functionality. With the help of
bar. When the bar fills up System Monitor you can view the list of all processes, know their
to approximately 90 per
names, ind out which process belongs to which users, detect
cent or more, it means that
you are running low on processes that devour too much CPU cycles or draw high levels
free disk space, which can of RAM, associate processes with their low-level IDs and manage
be troublesome for certain
process priority. Normally you’ll see a list of processes sorted
workflow scenarios. Ubuntu
cannot work properly if the by name. Note that you can click the name of a column to sort
root partition (/) gets 100 per processes by it. It is very helpful to sort them by CPU percentage
cent full. You can also check
or memory usage. If a process belongs to you (or if you have the
for free disk space in terminal
by using the ‘$ df’ command permissions), you can kill it or lower its priority. Select the process
(disk free), although it doesn’t you want to get rid of and press the End Process button in the
let you sort or reorder any of
lower right corner of the window. Right-click the process and select
the lines.
the Change Priority menu to alter its priority.
86
Use System Monitor Ubuntu essentials
87
Ubuntu apps Explore the Ubuntu Software Centre
Explore
the Ubuntu
Software Centre
Navigate your one-stop shop for purchasing,
installing and removing apps
Ubuntu Software Centre, aka USC, is a package management portal
– that is, a consolidated platform where you can search for, install or
purchase software, and even remove apps from the list of installed
software. Initially released on 29 October 2009, Ubuntu Software
Centre is developed in Python and contains more than 53,000 apps.
Previously, Ubuntu programs were downloaded from the repository
as tar iles, unzipped and then installed, by manually running the
commands in the console. Even the previous versions of Ubuntu
had many graphical utilities for adding/removing software, which
88
Explore the Ubuntu Software Centre Ubuntu apps
ultimately led to redundancy and fragmented Software Centre etc, which are displayed vertically
development efort. To ease this cumbersome in the left sidebar. To get started, search for the
process, USC came with a worthwhile approach shopping bag icon in the display and click it to
where all the software is installed with the click launch Ubuntu Software Centre.
of a few buttons. The search for speciic software Upon the launch of USC, the home screen
ends here as USC has name/description-based appears, which contains diferent categories of
search functionality, with multiple options to software, recommended software, newly added
choose from. The rating and users’ review helps software (Fig 2), top rated software and many
you to ind the best software. USC also provides more. For instance, if you’re looking for a text
Ubuntu application developers a prominent way editor, you can type the keyword in the search
to ofer their software to potential users. bar, which shows the diferent text editors present
The latest version of Ubuntu comes with in USC in a list view. You can just select any
some preconigured tools and software like the one of them and click the Install button to start
LibreOice suite, Mozilla Firefox, text editors, download the program.
89
Ubuntu apps Explore the Ubuntu Software Centre
Get to know Software Centre Start installing the software you need
On the top of the home screen you will ind the the Back button once, you’ll reach the page
section navigation commands: All Software and you just left. The Back command is unavailable
Installed (Fig 1, page 88). The Back and Forward whenever no previous screens exist in the history,
buttons – displayed as ‘<’ and ‘>’ respectively – and the Forward command whenever no later
help you navigate the diferent pages. USC keeps screens exist in the history. The All Software
the visited pages in memory so that by clicking section presents all the programs available, be
“In the Installed section you will ind the list of programs that
are installed on your Ubuntu machine”
90
Explore the Ubuntu Software Centre Ubuntu apps
they already installed on the computer or not. details in the form with a valid email ID (Fig 3).
In the Installed section you will ind the list of You will receive the veriication code at the email
programs that are installed on your Ubuntu address provided (Fig 4). Once that process is
machine, with the date of installation speciied. complete, you will receive a success message and
When a software item is selected, if the item is Ubuntu starts recommending useful software
not currently installed in your system, you will see to you, which you can select and install on your
an Install button. Click to install the software on machine with ease.
your machine. If the software is already installed, a
Remove button is available; clicking it will uninstall
the software.
On the home screen itself, you will ind the
section ‘Recommended For You’. In order to make
use of the recommendation facility, you have
to register yourself in Ubuntu by providing the Fig 4 (above) A verification email will confirm the process
Navigate via categories The various ways to navigate the Software Centre
The USC segregates software into diferent categories, such
as accessories, developer tools, books and magazines, games,
Top Rated
education, oice and many more. Upon clicking the Accessories
tab, for instance, a list of accessories is displayed, including Speed In terms of display, if the
Crunch (precision calculator), 7zip (compression/uncompression category is set to ‘Show non-
tool), PuTTY (SSH/Telnet client) and Shutter (screenshot utility). The applications by default’, then
results are displayed in a list
software listed in the Accessories tab is by default sorted by rating; view; otherwise tile view is
the other sorting criteria are name and release date. used, and non-application
items are hidden by default.
The top rated applications
“The software listed in the Accessories are also displayed on the
home screen using tile view
tab is by default sorted by rating” in descending order of DR
(dampened rating), regardless
of whether they are installed
Moving on to the Developer Tools page, you will ind many or not. Applications with
seven five-star ratings and
open source tools which are subcategorised into version control,
one four-star will be displayed
IDEs (integrated development environments), web development before other applications
and so on. The version control subcategory has many lavours of having two five-star ratings.
12 items are displayed in the
versioning software, prominent ones being Git-Cola, qgit and ggit.
home screen under the Top
The IDEs tab has Netbeans, Ninja, Spyder and Eclipse, which can be Rated tab; when the More
installed and used for software development. There are also other button is clicked, you land on
a page where 60 items are
subcategories named after software languages – like Java, Python
displayed in decreasing order
and Perl – that contain the diferent versions and tools related to the of DR using the list view.
speciic language.
91
Ubuntu apps Explore the Ubuntu Software Centre
On the home screen of USC you will ind the chronological order; (newest on top). Clicking
History tab; when clicked, this shows the ‘All anywhere on a branch (or pressing the space-
Changes’ page by default. Under the navigation bar when it is selected) should expand it if it is
bar are tabs for All Changes, Installations, Updates collapsed, and collapse it if it is expanded.
and Removals (Fig 5). The entries are grouped The branch on which the recent activity has
in branches and labelled by the day in reverse occurred is opened by default in the USC history
92
Explore the Ubuntu Software Centre Ubuntu apps
screen. The items displayed in the History tab contain the icon of
the software, name, plus the date and time of installation. Under the One-stop shop
for Ubuntu
Installation tab, you will ind all the installed applications grouped
by their installation dates. The Updates tab, on the other hand, lists As well as offering a vast
selection of free software
all the updated applications along with their update dates. Finally,
to download, the Ubuntu
the Removal tab displays the list of applications which have been Software Centre provides
uninstalled from the system. the option to purchase and
install commercial software.
In the History tab, the search bar present on the top right can
The Software Centre contains
search for applications which are already installed or have been a list of programs which are
removed from the system. Whenever the Back ports channel provided by Ubuntu itself,
along with software offered
contains a version of any application which is newer than the
by Canonical’s partners
one installed, an Updates item appears in the last navigation bar. (those programs which
The Updates section displays the number of application updates abide by the software rules
of Ubuntu). The number of
available, along with an Update All button. The list contains the icon,
programs available in the
title, the newer version of the application and an Update button at Software Centre continues to
the far right end. grow rapidly, so there’s a lot
of choice. In simple terms, the
When an item is selected, pressing the Enter key should activate
Ubuntu Software Centre is
its Update button; when an update is installed or waiting to be the equivalent of the Google
installed, its Update button should be inactive. Play Store (or Apple App
Store) for Ubuntu, where
you can find thousands
of programs, tools and
“The Software Centre contains a list of applications which can be
programs provided by Ubuntu itself” installed with just a few clicks.
displayed in a list view (Fig 6). Now select the item graphically displaying the status of the installation.
Open JDK Java 7 Runtime and on the right side Once it’s complete, you will be redirected to the
you will ind the Install button; click it to install success page, which also contains the Remove
the packages. You’ll then be prompted to enter button in order to uninstall the program.
your administrator password; type the correct Click the Back button to search for the IDEs
password and hit Enter to start the installation. section; now click the IDEs icon to see the list of
During installation, you will ind the progress icon IDEs present in USC. Type ‘Eclipse’ in the search
94
Explore the Ubuntu Software Centre Ubuntu apps
bar to search for the Eclipse IDE. Select the Eclipse Create a project named ‘Hello’, with a Java
IDE (blue ball icon) and then click the Install ilename of Hello.java, in the test package. Now
button; enter the administrator password to start run this program to get an output in the console.
installation. Once Eclipse has successfully installed, This conirms that both Java and Eclipse are up
open it by double-clicking. and running.
Switching from Developer Tools to Internet in the category section of USC, you will ind many program
to install, such as chat applications, ile sharing tools, email clients and web browsers. By clicking the File
Sharing tab, you will see many tools, FileZilla being the highest rated one (Fig 7). FileZilla uses FTP, SFTP
and FTPS mechanisms to share and upload iles to diferent systems. Just click on the Install button and
start sharing your iles within diferent systems.
In order to use your Ubuntu computer for oice work and view diferent formats of iles, you will ind
the Kile application under the Oice category. The source editor is a multi-document editor designed
for .tex and .bib iles. Menus, wizards and auto-completion are provided to assist with tag insertion and
code generation.
95
Ubuntu apps Browse the Internet with Firefox
Browse the
Internet with
Firefox
One of Ubuntu’s default browsers, explore the
hidden features of Mozilla Firefox
Address and search bar Add and view Icon bar Editing
Enter the website address here to bookmarks This bar holds icons for other services buttons
browse the Internet. The address bar You can add a bookmark with like Pockets (to save reading lists), You can edit website URLs or
is smart, as it automatically suggests the star icon and view all the Downloads, Home and Chat. The last text that you enter in websites
websites based on your history and saved bookmarks by clicking on icon opens up the Settings menu using this buttons
bookmarks. You can enter search the next icon
queries in the search bar
Search website from the search field. Select ‘Add a Keyword’ bookmarks, links and other things
for this search. The ‘Add Bookmark’ are synced across devices seamlessly.
address bar dialog appears. Enter an appropriate Firefox does this with a feature called
name for the bookmark (for example: Sync. It lets you share your data and
‘Wikipedia search’). Create a keyword preferences (such as your bookmarks,
01 There are steps that you will
repeat several times a day
without realising how much time they
(like ‘wikipedia’). Select the bookmark
folder to contain the smart keyword.
history, passwords, open tabs, Reading
List and installed add-ons) across all
take, for example, searching specific Click OK. To use the created smart your devices.
websites. Instead of going to the bookmark, enter the keyword and Let us see how to set up and sync
search engine, finding the search box, search string in the Location bar then an account in Firefox. First, click on
entering the keyword and executing press Return. the menu button and click ‘Sign in to
the search, you can directly search the Sync’. The sign-in page will open in a
Internet using Firefox, while you are on Sync information across new tab. Click the ‘Get Started’ button.
any website. Fill out the form to create an account
To set this up on your browser,
devices and click ‘Next’. Take note of the email
visit the page on the target website address and password you used; you’ll
that has the search field you would
normally use to search the site. Hold 02 People now use multiple
devices to access the Internet.
Firefox helps to make sure all your
need it later to log in. Check your
emails for the verification link and click
down the Ctrl key and click on the on it to confirm your email address.
Fig 1 (above) It takes a few simple steps to change our default home page
98
Browse the Internet with Firefox Ubuntu apps
You’re ready to go! Now you just need pages you’ve previously visited. Private This paves the way for thousands of
to log in to Sync on all your other Browsing also includes Tracking interesting and useful apps in the
devices and let it do the rest. Protection, which prevents companies Mozilla marketplace (Fig 2). With a
from tracking your browsing history wide selection of games, music and
Protect your privacy across multiple sites. To open a private productivity apps, Firefox Marketplace
browsing session, click on the menu has something for everybody. To
while browsing button and then click ‘New Private install an app, open Firefox, click on
Window’. If you want to directly the ‘Tools’ menu and select ‘Apps’. This
03 As you browse the web, Firefox
remembers lots of information,
for example the sites you’ve visited
open a link in a new private window,
hold down the Ctrl key while you
will open up the marketplace. Now,
type a search query in the search box
click on this link and choose the to look for a specific app or choose
and your passwords. There may be a category for the type of app you
option to ‘Open Link in New Private
times, however, when you don’t want are looking for. You can also choose
Window’ from the context menu.
people with access to your computer the screen type from the drop-down
to see this information. Private Install an app menu to see apps optimised for that
Browsing allows you to browse screen size. Click on an app to view its
the Internet without saving any
information about which sites and 04 Mozilla offers the browser
platform to developers as well.
details. Finally, if you’re ready to install
an app, click the blue install button.
Manage your
emails with
Thunderbird
Work remotely and learn to manage all your
email accounts using Thunderbird
101
Ubuntu apps Manage your emails with Thunderbird
102
Manage your emails with Thunderbird Ubuntu apps
Multiple mail
accounts with
unified folders
Communicate
with Empathy
Learn how to set up and utilise Empathy text
messenger to the full
Instant messaging, also abbreviated to IM, is a text-based means
to communicate instantly over the Internet and the local network.
While some IM applications need you to create a new account,
others provide IM facilities by using accounts from diferent service
providers like Google, Yahoo, etc. IM applications can also be used
to connect to chat rooms. For the uninitiated, chat rooms are online
places where like-minded people meet to talk.
In this feature, we are going to explore Empathy. It is a messaging
program that supports text, voice, video chat, and ile transfers
over many diferent protocols. Empathy also lets you add accounts
from diferent services and uses them to chat with your contacts.
Based on Telepathy for protocol support and a UI based on Gossip,
Empathy is the default chat client in current versions of GNOME,
(and hence Ubuntu).
To get started with Empathy simply type ‘Empathy’ in Dash.
Then click on the Empathy icon to launch the application. When
you launch it for the irst time, you’ll be asked to link your online
accounts. Just link your accounts and you can then easily talk
to all your contacts. Using Empathy, you can also group all the
conversations in a single window, have multiple windows for
diferent kinds of conversations, easily search through your previous
conversations, and share your desktop in just two clicks. Now let’s
learn about Empathy in more detail.
The Empathy interface Understand how Empathy works and what you can change
105
Ubuntu apps Communicate with Empathy
Add a new account information though. Finally click Add the Identifier field, enter your contact’s
to confirm the process and save the login ID, username, screen name, or
account details. other appropriate identifier for the
01 You can add instant messaging
accounts from several
supported services (Fig 1). For some Manage contacts
service type. In the Alias field, type
your contact’s name as you would like
account providers, these steps it to appear in your contact list. Finally,
click Add to add the person to your list
will also allow you to register for a
new account. To add an account,
click Empathy>Accounts and then
02 After you have your accounts
added to Empathy, the next
step is to add your contacts and
of contacts.
If one or more of your contacts
press +. From the ‘What kind of chat manage them. To add contacts, click has multiple accounts with different
account do you have?’ drop-down list, Chat>Add Contact. Then from the messaging services, you can combine
select the type of account you wish to accounts drop-down list select the these accounts into a single contact.
add. Enter the required information. account you wish to use to connect The resulting contact is called a meta-
For most accounts, you will only need to your contact. Note that your contact: a contact composed from
a login ID and a password. Some contact should be using the same different single contacts. To link
accounts may require additional service as the account you select. In accounts press the tick button to
select entries you want to link. This will with all users on all other servers
enable selection mode and you can on that network. You can also add
see a checkbox for each entry. Tick and remove servers for this network
the checkboxes that correspond to a using the Add and Remove buttons.
single person’s contact entries. Finally, When a server is selected, click the
press Link. field under Server or Port to edit it.
Alternatively, use the left and right
arrow keys to focus the field, and press
Audio and video the space bar to begin editing.
communication
107
Ubuntu apps 20 LibreOffice essentials
20 LibreOffice
essentials
Make your working day more productive with
these indispensable tips for the LibreOffice suite
108
20 LibreOffice essentials Ubuntu apps
Writer
Quick maths
04 Quick
maths
04 Even when
you’re writing,
you might need to do
a quick bit of maths.
Instead of switching to
Google or a calculator
app, you can use
the formula bar. Go
to Insert, Object,
Formula and write
out the calculation
you want. Once you
have confirmed it,
the outcome of the
formula appears
where your cursor
was placed.
Quick navigation
05 Pressing F5 or going
to the View menu
will allow you to use the
Navigator function. You can
use it in large documents
to quickly move between
different headings, tables,
graphics, bookmarks and
many more objects in the
document. It’s not a proper
dock, so you can move it
around to see what you
want at any given time.
06 By default, Writer will save new files as ODTs, the open document format. This works in most other word processors,
but if you’re regularly working with files that need to work on Microsoft Office, you can change the default file format
to be .doc or .docx. Go to Tools, Options and find the General settings under Load/Save to change the default.
110
20 LibreOffice essentials Ubuntu apps
07 Writer has a recovery tool for when unexpected shutdowns happen, but that relies on temporary files and other
related files that aren’t always there when you really need them. Writer does have a backup system that it can make
use of though; enable ‘Always create backup copy’ in the Load/Save General options to cover this.
Change case
08 Got a
sentence
or a word and it’s
not quit capitalised
correctly? Pasted
some text and
it’s all randomly
capitalised? You
can change the
case of specific
sections of text
without re-writing.
Simply select
what you want
to change, right
click and select
the Change Case
option to tweak.
111
Ubuntu apps 20 LibreOffice essentials
Calc
AutoFormat tables
09 If you’ve created a table, you may need to add a touch of colour in order
to make it more readable. You can do this manually, however Calc has
a built-in format option under Format>AutoFormat. From here you can give a
colour scheme to a table that you’ve selected and even customise what is taken
into account for formatting.
10 Protect
your Protect your
spreadsheet spreadsheet
Learn more!
10 Shared spreadsheets
are good for
productivity, but the
more complicated they
There are many more become, the more
functions to learn that can difficult it can be to track
help you do more with down an accidental
LibreOffice and the first step change made by one
is to have a look through of the users. You can
some of the documentation protect the spreadsheet
for the software, or just have by using Tools>Protect
a quick browse through Document>Sheet in order
all of the options and the to give it a password so
available menus. that only certain people
can make changes.
112
20 LibreOffice essentials Ubuntu apps
AutoFilter rows
“Filtering rows helps to organise data,
but if you’re not sure how exactly to go 12 Filtering rows helps to organise
data, but if you’re not sure
how exactly to go about doing that,
about doing that, Calc has an automatic Calc has an automatic filtering tool
iltering tool you can use” you can use. Select a row, then go to
Data>Filter>Auto for it to create an
automatic filtering system based on
that row. You can also modify it a bit
once it’s in place.
Grouped cells
13 Sometimes you don’t need to see specific chunks of data all the time, and collapsing it like in a piece of code will add
a bit more space to the viewable page. Using the Outline function under Data>Group and Outline>AutoOutline, you
can create these collapsible groups, which use a thick outline to indicate themselves.
Auto-increment
or copy cells
14 If you’ve never
stumbled across
it, Calc is very smart
when it comes to
replicating cells. If you
write down two or
three numbers or even
dates, selecting one
and dragging the black
square down to copy
will automatically fill in
the cells with numbers
or dates in the correct
sequence. If you don’t
want it to do that, press
and hold Control when
copying the cell for
regular duplication.
113
Ubuntu apps 20 LibreOffice essentials
15 It seems fairly natural for the Enter key to move you down a row of cells and that’s what Calc does by default. However,
you can actually change the behaviour of the Enter key by going to Tools>Options>LibreOffice Calc, then General to
have it move along a row instead.
Freeze columns
in place
114
20 LibreOffice essentials Ubuntu apps
Miscellaneous
Presenter mode
17 When using Impress for presenting slides, you will often be hooked up to a projector or television that either mirrors
or acts as an extension to your laptop. Impress has a neat feature where the actual presentation will be shown on the
big screen, while you can turn on a presenter console just for your laptop display that shows you what’s coming up in your
presentation, along with notes.
115
Ubuntu apps Text editing with gedit
Text editing
with gedit
Understand its features and learn about its
many purposes
Text Editor (aka gedit) is the default GUI text editor in the Ubuntu
OS and the GNOME desktop environment. It is UTF-8 compatible
and supports most standard text editor functions as well as many
advanced features like multilingual spell-checking, extensive
support of syntax highlighting, and a large number of official and
third-party plug-ins. With multiple character sets, Text Editor can
play a versatile role – you can use it to prepare simple notes and
documents, or create source code using its advanced features just
like an integrated development environment. gedit is installed
by default on Ubuntu 16.04 and can be launched via Dash or an
application shortcut. If you prefer the command line, you can use
the gedit command to directly interact with the tool.
To open a speciic ile with gedit, type gedit <filename>
at the command prompt. To open multiple iles, type gedit
<filename1> <filename2> and so on. You can also open a ile at a
speciic line number by including +<line number> in the ile path,
like this: gksudo gedit +21 /etc/apt/sources.list.
gedit ofers several helpful options, under Edit>Preferences, that
you may want to review. For example, gedit automatically creates
a backup copy of iles you edit. If you are running low on space,
however, you can disable this: just go to Edit>Preferences>Editor tab
and deselect ‘Create a backup copy’.
117
Ubuntu apps Text editing with gedit
Fig 1 Use this dialog box to navigate to text file you want to open
Handling files with gedit tab. You can also open files that are Handling text
located on other machines with gedit.
119
Ubuntu apps Manage images with Shotwell
Manage images
with Shotwell
Keep tabs on large numbers of photographs
with ease using the Shotwell app
Organise your shots Store and retrieve your pictures in no time at all
121
Ubuntu apps Manage images with Shotwell
122
Manage images with Shotwell Ubuntu apps
process is complete, a message titled Share RAW files industry-standard picture file. After
‘Keep or Delete’ will be displayed. It clicking OK, the program displays a
permits you to decide whether the dialog permitting you to select the
images should stay on the memory
card – picking yes is not an issue, as
04 Be it fast-moving objects or
the darkness of the Albaycin
in Grenada, when the imaging
target. Then images can be sent via
Bluetooth or email.
they will not be imported again. situation gets tough, shooting in RAW
helps you to make the most of your Share in Bulk
images. Sadly, the resulting files are
See what happened not well-suited for sharing because
most people don’t have the necessary 05 Sending images out one
by one is a painstaking task
123
Ubuntu apps Listen to songs with Rhythmbox
Listen to songs
with Rhythmbox
Use your workstation to listen to music while
you work
125
Ubuntu apps Listen to songs with Rhythmbox
Import the tracks Set importing options Click the Import button to add
them to the media catalogue of the
126
Listen to songs with Rhythmbox Ubuntu apps
127
of al
r
al ci
fe
tri Spe
Enjoyed
this book?
Exclusive offer for new
Try
3 issues
for just
£5 *
* This ofer entitles new UK direct debit subscribers to receive their irst three issues for £5. After these issues,
subscribers will then pay £25.15 every six issues. Subscribers can cancel this subscription at any time. New
subscriptions will start from the next available issue. Ofer code ZGGZINE must be quoted to receive this special
subscriptions price. Direct debit guarantee available on request. This ofer will expire 30 September 2017.
** This is a US subscription ofer. The USA issue rate is based on an annual subscription price of £65 for 13 issues,
which is equivalent to approx $102 at the time of writing compared with the newsstand price of $16.99 for 13 issues
$220.87. Your subscription will start from the next available issue. This ofer expires 30 September 2017.
128
The only magazine
all about Linux
Written for you
Linux User & Developer is the only
magazine dedicated to advanced users, developers
and IT professionals
subscribers to…
129
From the makers of
Also available…