Tag Archives: ubuntu

Chakra Linux: Its Own Beast, Its Own Beauty | Linux.com


There are so many Linux distributions available—so many, in fact, that it can become a bit of a challenge to find the one right for you. After you’ve looked at them enough, it seems the variations tend to blur together, such that one flavor of Linux is only a slight shift away from another.

Perhaps your distribution of choice may have a sweet-looking desktop, but it might be the standard Ubuntu underneath. Or, maybe you’ve found that a distro is using the same GNOME as everyone else, with the slightest variation under the hood. That’s how it goes in the selection of Linux. The good news is that, even with that familiarity, there are some truly brilliant distributions available. Some of them advance the desktop interface well beyond the standard, while others go out of their way to be familiar.

Chakra Linux is a combination of the above descriptions. What initially started out as a variation on Arch Linux, with the name KDEmod, the distribution used a “lightified and modular” version of the KDE desktop, built exclusively for Arch Linux. This take on KDE offered a significant performance increase and improved customizations over the standard KDE installation, and it quickly gained a following.

After a while, however, it was determined that the LiveCD Project would be a much better fit and Chakra was born. Since then, the environment has slowly morphed into its own beast, a unique merging of ideologies and designs that deliver a solid and beautiful experience.

Chakra’s main vision is to provide a pure KDE/Qt desktop, with a nod to simplicity and transparency. Of course, simplicity is in the eye of the beholder. Even though KDE makes for an incredibly user-friendly environment, a new-to-Linux user will find themselves a bit confused when it comes to certain tasks. Let’s dive in and see what Chakra’s all about.

At first blush

Chakra is a beautiful desktop—if you’re okay with flat themes (Figure 1).

Check out the Chakra menu, and you’ll find just about every piece of software you need. The one caveat to this is the choice of office suit. Instead of the more popular LibreOffice, Chakra installs the KDE-specific Calligra. As long as you don’t need to interact with MS Office, that’s not completely a bad thing. If, however, you have to open any MS Office document (later than Office 2007), you’re out of luck. As much as I respect what Calligra is doing, without the ability to interact with the likes of .docx, it simply will not do (especially in a business environment).

Of course, that’s not really too much of an issue, as you can open up the Octopi software installer and install LibreOffice. Unfortunately, the version available is a bit out of date. Currently, the latest release of LibreOffice is 5.4.0.3 and the version available to Chakra (after an initial update) is 5.3.5-1. Unfortunately, there is no latest version of the office suite to be downloaded for the platform, so users would have to wait until the developers make it available for update.

Speaking of which…

Another issue new users will find with Chakra is the update process. With most Linux distributions, you can head to the desktop menu and find an entry for updating software. Not so with Chakra. Any updating to be done, must be handled through the command line. So to upgrade your system, you must open up the terminal window and issue the command:

sudo pacman -Syu

After running the command, you must okay every single one of the updates, before the process will continue (do note, the first run will take considerable time).

Speaking of which…

A unique aspect of Chakra is that it is a half-rolling release distribution. This means that Chakra works with a stable core and rolling applications on top. With this idea, you will always have the latest desktop software, running on top of a not-so-latest release of the core. This forms a solid foundation for which to run software. For instance, after an initial update, Chakra was using KDE 5.10.4-1 (the latest release) and kernel is 4.8.6-1. The mainline kernel is currently at 4.13-rc4, so this is certainly a stable kernel.

Fortunately, you do not have to install applications from the command line (you certainly can, if you choose). If you prefer a GUI for installing software, Chakra includes the Octopi front end for that particular task (Figure 2).

It is very important that you run the sudo pacman -Syu command before first using Octopi—otherwise, you’ll have out of date packages available for installation.

Some nice choices

Looking beyond the Calligra over LibreOffice issue, some nice choices have been made for default software. Take, for instance, the selection of Clementine as the default music player. This happens to be my favorite of all the available players on the market. It offers an amazing array of features, with a great user interface. Good choice. Another solid choice is Qupzilla, a lightweight web browser that uses the Qt webengine. This browser is faster to open that Firefox, offers more features than Midori, and renders as well as Chrome.

Another nice touch is the addition of the Yakuake drop-down terminal. I like a good terminal that is quick to open and quick to get out of the way; Yakuake does this with ease.

Who should be using Chakra

Chakra is a unique distribution that offers an interface and stability that begs for new users to come play, but with just enough added complexity that might challenge them to learn a bit more (or make them slightly hesitant). On the other hand, Chakra does deliver serious performance and plenty of tools (such as Package Changelogs, Chakra Bug Tracking System, Qt Designer, Vim text editor, and more) that will make more hard-core users quite happy.

If you’re a new user, who doesn’t mind working at the command line now and then, Chakra will serve you well. If you’re already well versed in Linux, Chakra will give you just enough to keep you curious and happy, while remaining stable underneath.

Manipulate IPv6 Addresses with ipv6calc | Linux.com


Last week, you may recall, we looked at calculating network addresses with ipcalc. Now, dear friends, it is my pleasure to introduce you to ipv6calc, the excellent IPv6 address manipulator and query tool by Dr. Peter Bieringer. ipv6calc is a little thing; on Ubuntu /usr/bin/ipv6calc is about 2MB, yet it packs in a ton of functionality. 

Here are some of ipv6calc’s features:

  • IPv4 assignment databases (ARIN, IANA, APNIC, etc.)
  • IPv6 assignment databases
  • Address and logfile anonymization
  • Compression and expansion of addresses
  • Query addresses for geolocation, registrar, address type
  • Multiple input and output formats

It includes multiple commands. We’re looking at the ipv6calc command in this article. It also includes ipv6calcweb and mod_ipv6calc for websites, ipv6logconv log converter, and ipv6logstats log statistics generator.

If your Linux distribution doesn’t compile all options, it’s easy to build it yourself by following instructions on The ipv6calc Homepage.

One useful feature it does not include is a subnet calculator. We’ll cover this in a future article.

Run ipv6calc -vv to see a complete features listing. Refer to man ipv6calc and The ipv6calc Homepage to learn all the command options.

Compression and Decompression

Remember how we can compress those long IPv6 addresses by condensing the zeroes? ipv6calc does this for you:

$ ipv6calc --addr2compaddr 2001:0db8:0000:0000:0000:0000:0000:0001
2001:db8::1

You might recall from Practical Networking for Linux Admins: Real IPv6 that the 2001:0DB8::/32 block is reserved for documentation and testing. You can uncompress IPv6 addresses:

$ ipv6calc --addr2uncompaddr 2001:db8::1
2001:db8:0:0:0:0:0:1

Uncompress it completely with the --addr2fulluncompaddr option:

$ ipv6calc --addr2fulluncompaddr 2001:db8::1
2001:0db8:0000:0000:0000:0000:0000:0001

Anonymizing Addresses

Anonymize any address this way:

$ ipv6calc --action anonymize 2001:db8::1
No input type specified, try autodetection...found type: ipv6addr
No output type specified, try autodetection...found type: ipv6addr
2001:db8::9:a929:4291:c02d:5d15

If you get tired of “no input type” messages, you can specify the input and output types:

$ ipv6calc --in ipv6addr --out ipv6addr  --action anonymize 2001:db8::1
2001:db8::9:a929:4291:c02d:5d15

Or use the “quiet” option to suppress the messages:

$ ipv6calc -q --action anonymize 2001:db8::1
2001:db8::9:a929:4291:c02d:5d15

Getting Information

What with all the different address classes and sheer size of IPv6 addresses, it’s nice to have ipv6calc tell you all about a particular address:

$ ipv6calc -qi 2001:db8::1
Address type: unicast, global-unicast, productive, iid, iid-local
Registry for address: reserved(RFC3849#4)
Address type has SLA: 0000
Interface identifier: 0000:0000:0000:0001
Interface identifier is probably manual set

$ ipv6calc -qi fe80::b07:5c7e:2e69:9d41
Address type: unicast, link-local, iid, iid-global, iid-eui64
Registry for address: reserved(RFC4291#2.5.6)
Interface identifier: 0b07:5c7e:2e69:9d41
EUI-64 identifier: 09:07:5c:7e:2e:69:9d:41
EUI-64 identifier is a global unique one

One of these days, I must write up a glossary of all of these crazy terms, like EUI-64 identifier. This means Extended Unique Identifier (EUI), defined in RFC 2373. This still doesn’t tell us much, does it? EUI-64 addresses are the link local IPv6 addresses, for stateless auto-configuration. Note how ipv6calc helpfully provides the relevant RFCs.

This example queries Google’s public DNS IPv6 address, showing information from the ARIN registry:

$ ipv6calc -qi 2001:4860:4860::8844
Address type: unicast, global-unicast, productive, iid, iid-local
Country Code: US
Registry for address: ARIN
Address type has SLA: 0000
Interface identifier: 0000:0000:0000:8844
Interface identifier is probably manual set
GeoIP country name and code: United States (US)
GeoIP database: GEO-106FREE 20160408 Bu
Built-In database: IPv6-REG:AFRINIC/20150904 APNIC/20150904 ARIN/20150904 
IANA/20150810 LACNIC/20150904 RIPENCC/20150904

You can filter these queries in various ways:

$ ipv6calc -qi --mrmt GEOIP 2001:4860:4860::8844
GEOIP_COUNTRY_SHORT=US
GEOIP_COUNTRY_LONG=United States
GEOIP_DATABASE_INFO=GEO-106FREE 20160408 Bu

$ ipv6calc -qi --mrmt  IPV6_COUNTRYCODE 2001:4860:4860::8844
IPV6_COUNTRYCODE=US

Run ipv6calc -vh to see a list of feature tokens and which ones are installed.

DNS PTR Records

Now we’ll use Red Hat in our examples. To find the IPv6 address of a site, you can use good old dig to query the AAAA records:

$ dig AAAA www.redhat.com
[...]
;; ANSWER SECTION:

e3396.dscx.akamaiedge.net. 20   IN      AAAA    2600:1409:a:3a2::d44
e3396.dscx.akamaiedge.net. 20   IN      AAAA    2600:1409:a:397::d44

And now you can run a reverse lookup:

$ dig -x 2600:1409:a:3a2::d44 +short
g2600-1409-r-4.4.d.0.0.0.0.0.0.0.0.0.0.0.0.0.2.a.3.0.a.
 0.0.0.deploy.static.akamaitechnologies.com.
g2600-1409-000a-r-4.4.d.0.0.0.0.0.0.0.0.0.0.0.0.0.2.a. 
 3.0.deploy.static.akamaitechnologies.com.

As you can see, DNS is quite complex these days thanks to cloud technologies, load balancing, and all those newfangled tools that datacenters use.

There are many ways to create those crazy long PTR strings for your own DNS records. ipv6calc will do it for you:

$ ipv6calc -q --out revnibbles.arpa 2600:1409:a:3a2::d44
4.4.d.0.0.0.0.0.0.0.0.0.0.0.0.0.2.a.3.0.a.0.0.0.9.0.4.1.0.0.6.2.ip6.arpa.

If you want to dig deeper into IPv6, try reading the RFCs. Yes, they can be dry, but they are authoritative. I recommend starting with RFC 8200, Internet Protocol, Version 6 (IPv6) Specification.

Learn more about Linux through the free “Introduction to Linux” course from The Linux Foundation and edX.

How to Integrate Git into Your Linux Desktop | Linux.com


Ask a developer to name their most important tools and very often the reply will include Git. There’s a good reason for that: Git is one of the most widely used distributed version control systems. Git can be set up as a local repository, used on a LAN, or used via the official, global service. With Git you can do things like add access control to your code, display the contents of a Git repository (via the web), and manage multiple repositories.

Most users (especially of the Linux variety) work with Git through the command line—with good reason. The Git command-line tools are second nature to Linux users; and considering that most developers working on the Linux platform are already acclimated to the command line, it’s efficient. However, not every user wants to spend all of their Git time working within the terminal. Fortunately, for those users, there are plenty of various GUI tools that can help you get your Git on. Not all of these tools are created equal, so what you use will depend upon your needs.

I want to highlight three such tools—centered on file manager/desktop integration. How you use Git (and how you need it integrated into your desktop) will determine what tool is best for you.

First, we’ll talk about tools that integrate into your file manager. For this, I’m going to focus on the GNOME and KDE desktops (as these two offer the best integration environments). Next, we’ll discuss a very powerful tool that does a great job of integrating into the Linux desktop and connecting with your remote Git account.

With that said, let’s take a look at two very handy tools that integrate into file managers.

RabbitVCS-git

If you use GNOME, chances are you use Nautilus. If you use Nautilus and work with Git, you’re going to want to install one of the best Linux desktop integration tools for Git—RabbitVCS-git. RabbitVCS-git is an SCM client that integrates itself with the Nautilus file manager to manage local Git or SVN repositories.

To install RabbitVCS-git on Ubuntu (or a Ubuntu derivative), issue the following commands from the terminal window:

sudo add-apt-repository ppa:rabbitvcs/ppa
sudo apt-get update
sudo apt-get install rabbitvcs-nautilus 

Once installed, logout of GNOME and log back in. Open up Nautilus and navigate to any project folder, and right-click a blank spot to reveal the RabbitVCS-git contextual menu (Figure 1).

At this point, you can begin to work with a very well done bit of Git integration with Nautilus.

Git in KDE

The KDE file manager, Dolphin, offers Git integration by way of a plugin. Before you attempt to use the plugin, you might have to install it. Open up a terminal window and issue the command:

sudo apt-get install dolphin-plugins

Once that command completes, open up Dolphin and then click the Control button > Configure Dolphin. Click on the Services tab, scroll down until you find Git, and click to enable (Figure 2).

With Git checked, click OK and then, when prompted, click to restart Dolphin. There is one thing to note: Installing the Dolphin plugins package does not install git. If you haven’t installed the git package (which I assume you already have), you’ll need to do so before Dolphin can actually work with Git. You will also have had to create a new repository from the command line and do a first commit. Once you’ve taken care of that, you will see the Git-related right-click context menu entries in Dolphin (Figure 3).

From that context menu, you can checkout, show local changes, commit, create tags, push, and pull.

SparkleShare

Now we’re going to venture into the realm of something a bit more powerful than simple file manager integration. The tool I want to demonstrate is SparkleShare, a unique self-hosted service that allows you to do file syncing/sharing, as well as version control, client-side encryption, and (to the point) connect and sync with your GitHub account.

SparkleShare is available from within the standard repositories, so to install (I’ll be demonstrating this on Linux Mint, using the Cinnamon desktop), the following steps will do the trick:

  1. Open a terminal window.

  2. Update apt with the command sudo apt-get update.

  3. Type your sudo password and hit Enter.

  4. Once the update completes, issue the command sudo apt-get install -y sparkleshare.

  5. Allow the installation to finish.

Once the installation is done, go to your desktop menu and search for the SparkleShare entry. Upon first run, you will be prompted for a name and email address (Figure 4).

Click Continue and then either view the tutorial or click to skip. You will be given a unique Client ID (an ssh-rsa key). Copy and save that key. Click the Finish button. Before you continue on with the SparkleShare GUI setup tool, you need to configure your GitHub account with your SparkleShare ssh-rsa pub key. To do this, follow these steps:

  1. Open a terminal window.

  2. Issue the command cd ~/.config/sparkleshare.

  3. Find the name of your .pub key with the command ls (it will end in .pub).

  4. Open the pub key with a text editor and copy the contents.

  5. Open your GitHub account in your desktop browser.

  6. Go to Settings | SSH and GPG keys.

  7. Click New SSH Key.

  8. Title the key SparkleShare.

  9. Copy the contents of your SparkleShare pub key into the Key text area (Figure C).

  10. Click Add SSH Key.

With the key in place, you can finish up the SparkleShare GitHub connection. You will see a new icon in your system tray; click that icon and then select SparkleShare > Add Hosted Project. Select GitHub from the list and then fill out the Remote Path section in the form /gitusername/repository (Figure 5).

SparkleShare will automatically sync the repository to your desktop, where you can start to work locally on your project, knowing the files will seamlessly sync back to your GitHub account.

Git integration made easy

And there you have it, Git integration into your Linux desktop made easy. If you’re a developer who works on the Linux desktop, and you use Git, you’ll want to try one of these three tools. Yes, there are full-blown Git GUIs for Linux (such as Giggle, Git GUI, Git-Cola, Smart Git, and many more), but if you’re looking for easy file manager or desktop integration, look no further than these options.

Learn more about Linux through the free “Introduction to Linux” course from The Linux Foundation and edX.

Install Freeradius on ubuntu 17.04 Server and manage using daloradius (Freeradius web management application)


Sponsored Link

RADIUS, which stands for “Remote Authentication Dial In User Service”, is a network protocol — a system that defines rules and conventions for communication between network devices — for remote user authentication and accounting. Commonly used by Internet Service Providers (ISPs), cellular network providers, and corporate and educational networks, the RADIUS protocol serves three primary functions:

• Authenticates users or devices before allowing them access to a network

• Authorizes those users or devices for specific network services

• Accounts for and tracks the usage of those services

Freeradius Features

• An open and scalable solution

• Broad support by a large vendor base

• Easy modification

• Separation of security and communication processes

• Adaptable to most security systems

• Workable with any communication device that supports RADIUS client protocol

daloRADIUS is an advanced RADIUS web platform aimed at managing Hotspots and general-purpose ISP deployments. It features rich user management, graphical reporting, accounting, and integrates with GoogleMaps for geo-locating (GIS). daloRADIUS is written in PHP and JavaScript and utilizes a database abstraction layer which means that it supports many database systems, among them the popular MySQL, PostgreSQL, Sqlite, MsSQL, and many others.

It is based on a FreeRADIUS deployment with a database server serving as the backend. Among other features it implements ACLs, GoogleMaps integration for locating hotspots/access points visually and many more features. daloRADIUS is essentially a web application to manage a radius server so theoretically it can manage any radius server but specifically it manages FreeRADIUS and it’s database structure. Since version 0.9-3 daloRADIUS has introduced an application-wide database abstraction layer based on PHP’s PEAR::DB package which support a range of database servers.

Before Installing make sure you have Ubuntu 17.04 LAMP server installed and ready for freeradius.

Preparing your system

Open the terminal and run the following command

sudo apt-get install php-common php-gd php-curl php-mail php-mail-mime php-pear php-db php-mysql

Install freeradius using the following command

sudo apt-get install freeradius freeradius-mysql freeradius-utils

Create Freeradius Database

You can use the following command to create freeradius database

sudo mysql -u root -p

Enter password:

mysql> create database radius;

mysql> grant all on radius.* to radius@localhost identified by “password”;

Query OK, 0 rows affected (0.00 sec)

Insert the freeradius database scheme using the following commands

sudo mysql -u root -p radius

Enter password:

sudo mysql -u root -p radius

Enter password:

Create new user for radius database

sudo mysql -u root -p

mysql> use radius;

Reading table information for completion of table and column names

You can turn off this feature to get a quicker startup with -A

Database changed

mysql> INSERT INTO radcheck (UserName, Attribute, Value) VALUES (‘sqltest’, ‘Password’, ‘testpwd’);

Query OK, 1 row affected (0.04 sec)

mysql> exit

Bye

Freeradius Configuration

You need to edit /etc/freeradius/sql.conf file

sudo vi /etc/freeradius/sql.conf

Make sure you have the following details

database = mysql
login = radius
password = password

Uncomment the following

readclients = yes

Save and Exit the file

Now you need to edit the /etc/freeradius/sites-enabled/default file

sudo vi /etc/freeradius/sites-enabled/default

Uncomment the sql option in the following sections

accounting

# See “Authorization Queries” in sql.conf

sql

session

# See “Authorization Queries” in sql.conf

sql

Post-Auth-Type

# See “Authorization Queries” in sql.conf

sql

Save and Exit the file

Now edit /etc/freeradius/radiusd.conf file

sudo vi /etc/freeradius/radiusd.conf

#Uncomment the following option

$INCLUDE sql.conf

Save and exit the file

Now you can stop the free radius server using the following command

sudo /etc/init.d/freeradius stop

Run freeradius in debugging mode. If there is no error, you are ready to go.

sudo freeradius -X

Start the freeradius using the following command

sudo /etc/init.d/freeradius start

Test the radius server using the following command

sudo radtest sqltest testpwd localhost 18128 testing123

Ouput as follows

Sending Access-Request of id 68 to 127.0.0.1 port 1812
User-Name = “sqltest”
User-Password = “testpwd”
NAS-IP-Address = 127.0.1.1
NAS-Port = 18128
Message-Authenticator = 0x00000000000000000000000000000000
rad_recv: Access-Accept packet from host 127.0.0.1 port 1812, id=68, length=20

Daloradius Installation

You can download the Daloradius latest version from here

Once you downloaded the daloradius-0.9-9.tar.gz file you need to extract using the following command

$ tar xvfz daloradius-0.9-9.tar.gz

$ mv daloradius-0.9-9 daloradius

$ mv daloradius /var/www/html

Change Permissions

sudo chown www-data:www-data /var/www/html/daloradius -R

sudo chmod 644 /var/www/html/daloradius/library/daloradius.conf.php

Mysql database need to setup for daloradius.We need to do is to import the daloradius scheme into our existing radius database.

$ cd /var/www/html/daloradius/contrib/db

sudo mysql -u root -p radius
configure the following daloradius setting.

sudo vi /var/www/html/daloradius/library/daloradius.conf.php

Change the database password

$configValues[‘CONFIG_DB_PASS’] = ‘password’;

Save and exit the file

Now you need to configure daloradius website under /etc/apache2/sites-available

sudo vi /etc/apache2/sites-available/daloradius.conf

add the following lines

Alias /daloradius “/var/www/html/daloradius/”

<Directory /var/www/html/daloradius/>
Options None
Order allow,deny
allow from all
</Directory>

Save and exit the file

Enable daloradius website using the following command

sudo a2ensite daloradius

Enabling site daloradius.

To activate the new configuration, you need to run:

sudo service apache2 reload

Daloradius Web GUI

you can access daloradius GUI using http://server-ip/daloradius and the login screen as follows

1

Use the following login details

username: administrator
password: radius

If you are running PHP 7 then you might see the following error

Database connection error
Error Message: DB Error: extension not found

To fix the above error you need to do the following changes Credit goes here

Changing file library/daloradius.conf.php

It’s required to update daloRADIUS’s database connection code so that it identifies the MySQL server using the new and improved mysqli driver:

Open for editing the file library/daloradius.conf.php and locate the configuration variable CONFIG_DB_ENGINE and change it to the value of mysqli (it is now probably set to mysql, notice the extra i). It should end up looking as follows: $configValues[‘CONFIG_DB_ENGINE’] = ‘mysqli’;
Changing file library/opendb.php

Open for editing the file library/opendb.php

At the very end of the file just add this new line of code: $dbSocket->query(“SET GLOBAL sql_mode = “;”); which makes the MySQL version work with less strict SQL syntax

Once you logged in you should see similar to the following screen

2

Sponsored Link



Related posts

Easily Update Ubuntu and Debian Systems with uCareSystem | Linux.com


Updates are something that are often ignored for one reason or another. However, if you’re not making a daily (or at least weekly) habit of updating your systems, then you are doing yourself, your servers, and your company a disservice.

And, even if you are regularly updating your Ubuntu and Debian systems, you may be doing the bare minimum, thereby leaving out some rather important steps.

As with nearly every aspect of Linux, fortunately, there’s an app that does an outstanding job of taking care of those upgrading tasks. A single command will:

  • Update the list of available packages

  • Download and install all available updates for the system

  • Check for and remove any old Linux kernels (retaining the current running kernel and one previous version)

  • Clear the retrieved packages

  • Uninstall obsolete and orphaned packages

  • Delete package settings from previously uninstalled software

That’s a lot of jobs for one command—but ucaresystem-core handles all this with ease. Considering that one command takes the place of at least eight commands, that’s a big time saver.

In fact, here are the commands ucaresystem-core can take care of:

  • apt update

  • apt upgrade

  • apt autoremove

  • apt clean

  • uname -r (do NOT remove this kernel)

  • dpkg –list | grep linux-image

  • sudo apt-get purge linux-image-X.X.X-X-generic (Where X.X.X-X is the kernel to be removed)

  • sudo update-grub2

If you love spending time at a terminal window, that’s great. But if you have a lot of systems to update, you’re probably looking out for something to make your job a bit more efficient. That’s where ucaresystem-core comes in.

I’ve been using ucaresystem-core for more than a year now (with Elementary OS and Ubuntu) and have yet to encounter a single problem. In fact, this particular tool has become one of the first I install on all Ubuntu and Debian systems. I trust it…it works.

So, how can you get this incredibly handy tool? Let’s walk through the process of installing ucaresystem-core, how to use it, and how to automate it.

Installation

The first thing you must do is install ucaresystem-core. We’ll be downloading the .deb file (as the Utappia repository seems to no longer contain a release file). Here’s how:

  1. Download the .deb file that matches your operating system release into your ~/Downloads directory

  2. Change into the ~/Downloads directory with the command cd ~/Downloads

  3. Install the deborphan dependency with the command sudo apt install deborphan

  4. Install ucaresystem-core with the command sudo dpkg -i ucaresystem-core*.deb

That’s it for the installation; ucaresystem-core is ready to go.

Running ucaresystem-core

You might have guessed by now that running this all-in-one command is very simple, and you would be correct. To fire up ucaresystem-core, go back to your terminal and issue the command:

sudo ucaresystem-core

This will launch the tool, which will immediately warn you that it will kick off in five seconds (Figure 1).

As the command runs, it requires zero user input, so you can walk away and wait for the process to complete (how long it takes will depend upon how much needs to be updated, how much needs to be removed, the speed of your system, and the speed of your Internet connection).

The one caveat to ucaresystem-core is that it does not warn you should you need to reboot your machine (if a newer kernel be installed). Instead, you have to scroll up to near the beginning of the output to see what has been upgraded (Figure 2).

If you cannot scroll up in your terminal, you can always view the dpkg log found in /var/log/dpkg.log. In this file, you will see everything ucaresystem-core has upgraded (including a handy time-stamp — Figure 3).

How much space did we gain?

Since my Elementary OS is set up such that ucaresystem-core is run as a cron job, I installed a fresh instance on a Ubuntu 17.10 desktop to test how much space would be freed after a single run. This instance was a VirtualBox VM, so space was at a premium. Prior to running the ucaresystem-core command the VM was using 6.8GB out of 12GB. After the run, the VM was using 6.2GB out of 12GB. Although that may not seem like a large amount, when you’re dealing with limited space, every bit counts. Plus, if you consider it went from 37 percent to 34 percent usage, it might seem like a better savings. On top of that, the system is now clean and running the most recent versions of all software…with the help of a single command.

Automating the task

Because ucaresystem-core doesn’t require user input, it is very easy to automate this, with the help of cron. Let’s say you want to run ucaresystem-core every night at midnight. To do this, open a terminal window and issue the command sudo crontab -e. Once you’re in your crontab editor, add the following to the bottom of the file:

0 0 * * * /usr/bin/ucaresystem-core

Save and close the crontab file. The command will now run every night at Midnight. Thanks to the dpkg log file, you can check to see the results.

Should you want to set up ucaresystem-core to run at a different time/day, I suggest using the Crontab Guru to help you know how to enter the time/date for your cron job.

Keep it simple, keep it clean

You will be hard-pressed to find a simpler method to keep your Ubuntu and Debian systems both updated and clean, than with ucaresystem-core. I highly recommend you employ this very handy tool for any system that you want always updated and free of the cruft that can be left behind by such a process.

Of course, if you prefer to do everything by hand, that is an even more reliable method. However, when you don’t always have time for that, there’s always ucaresystem-core.

Learn more about Linux through the free “Introduction to Linux” course from The Linux Foundation and edX.