Category Archives: Linux

Colourfull CLI

The Bashrc file controls the options in your terminal.
In order to open that file enter the following command:

  • sudo nano ~/.bashrc

Look for the line and uncomment it:

#force_color_prompt=yes

to be:

  • force_color_prompt=yes

save then execute source ~/.bashrc

When you reconnect to your terminal, you should see some fancy colours.

Installing MemCached

Memcached is a high performance in-memory caching system that can be used to speed up applications and websites that use databases. Memcached does not write to disk, instead store its content in system memory which makes it faster.

Majority of the content management systems in used today have tools to take advantage of Memcached. If configured correctly, you may be able to see huge improvements to your websites and applications.

This brief tutorial shows you how to install Memcached on Ubuntu 17.04 / 17.10 servers

Continue reading Installing MemCached

Updating Ubuntu servers

One of the most effective ways to protect your servers is by updating them regularly. These updates and patches are released to fix security vulnerabilities, enhance performance and resolve issues.

The process of updating Ubuntu is fairly simple. All one needs is administrative access to the server terminal usually via SSH or other means.

Advanced Packaging Tool (APT) is a powerful command line tool which works with Ubuntu. It’s the default package management and installation tool for Ubuntu and other distributions.

Checking For Updates On Ubuntu Servers

To check for updated software that are available for Ubuntu server, run the commands below.

sudo apt-get update && apt-get -s upgrade

The command above will is all or any upgradable packages to choose from and give you the option to upgrade a single package or all the packages on the system.

Updating Ubuntu Packages

A single command s used to update all Ubuntu install packages. That command is shown below:

sudo apt-get update

You can also run the commands below to update as well as upgrade Ubuntu packages at the same time.

sudo apt-get update && sudo apt-get dist-upgrade

When you run the above commands, you’ll be prompted to confirm the update. You can then type Y for yes and press Enter to continue with the updates. Depending on the size of the update and your Internet connection speed, it may take few minutes to an hour.

After all the packages are downloaded and installed,  you can continue working and knowing that you server is updated and protected.

Ubuntu in-place upgrade to 18.04 LTS

Ubuntu 18.04 LTS (Bionic Beaver) is released on April 26th, 2018. This is a LTS version will be supported for about 5 years. This is a great version to upgrade to if you’re running earlier versions of Ubuntu..

You may be able to upgrade from Ubuntu 16.04 LTS to 18.04 LTS, this blog post will tell you how.

If you don’t want to do an in-place upgrade, you can download the ISOs image from its download page and do a clean install.

To upgrade Ubuntu, please follow the steps below

Step 1: Update Ubuntu 16.04 Server

Before upgrading to Ubuntu 18.04, you should first update the current 16.04. It’s recommended to update/upgrade all installed packages before upgrading. To update Ubuntu, connect to the server and run the commands below:

sudo apt update && sudo apt dist-upgrade && sudo apt autoremove

Step 2: Install Ubuntu Update Manager

After updating Ubuntu 16.04 server, run the commands below to install update-manager-core if it is not already installed.

sudo apt-get install update-manager-core

Then open the update-manager configuration file and make sure the Prompt line is set to lts

sudo nano /etc/update-manager/release-upgrades

Confirm that the Prompt is equal lts

# Default behavior for the release upgrader.

[DEFAULT]
# Default prompting behavior, valid options:
#
#  never  - Never check for a new release.
#  normal - Check to see if a new release is available.  If more than one new
#           release is found, the release upgrader will attempt to upgrade to
#           the release that immediately succeeds the currently-running
#           release.
#  lts    - Check to see if a new LTS release is available.  The upgrader
#           will attempt to upgrade to the first LTS release available after
#           the currently-running one.  Note that this option should not be
#           used if the currently-running release is not itself an LTS
#           release, since in that case the upgrader won't be able to
#           determine if a newer release is available.
Prompt=lts

If not, change it to lts and save the file.

Step 3: Perform Ubuntu 18.04 LTS Upgrade

Now that your system is ready, run the commands below to begin Ubuntu upgrade to the latest development release..

sudo do-release-upgrade -d

Follow the on-screen instructions…. y = yes and N= No. When prompted whether you wish to upgrade type y for yes.

Do you want to start the upgrade?

1 installed package is no longer supported by Canonical. You can
still get support from the community.

2 packages are going to be removed. 64 new packages are going to be
installed. 394 packages are going to be upgraded.

You have to download a total of 234 M. This download will take about
1 minute with your connection.

Installing the upgrade can take several hours. Once the download has
finished, the process cannot be canceled.

 Continue [yN]  Details [d] y

Wait for all the newer packages to be downloaded… this may take a while depending on your internet connection speed. After all packages are downloaded, your system will begin upgrading immediately….

Once new packages have finished installing, you’ll be asked whether to remove obsolete packages. Type y here. If you have a system that you have customized, you may wish to enter d to view the list… just in case you may need to reinstall..

Remove obsolete packages?

53 packages are going to be removed.

 Continue [yN]  Details [d]y

Wait for the process to complete, the reboot to finish.. you’ll be notify to reboot.

Restart required

To finish the upgrade, a restart is required.
If you select 'y' the system will be restarted.

Continue [yN] y

When everything is setup correctly, you system should be upgraded to the latest Ubuntu release.

Welcome to Ubuntu 18.04 LTS (GNU/Linux 4.15.0-19-generic x86_64)

Or check the exact function by using the commands in my previous post.