How to Install Different PHP (5.6, 7.0 and 7.1) Versions in Ubuntu

PHP (recursive acronym for PHP: Hypertext Preprocessor) is an open source, popular general-purpose scripting language that is widely-used and best suited for developing websites and web-based applications. It is a server-side scripting language that can be embedded in HTML.

Currently, there are three supported versions of PHP, i.e PHP 5.67.0 and 7.1. Meaning PHP 5.35.4 and 5.5have all reached end of life; they are no longer supported with security updates.

In this article, we will explain how to install all the supported versions of PHP in Ubuntu and its derivatives with most requested PHP extensions for both Apache and Nginx web servers using a Ondřej Surý PPA. We will also explain how to set default version of PHP to be used on the Ubuntu system.

Note that PHP 7.x is the supported stable version in the Ubuntu software repositories, you can confirm this by running the apt command below.

$sudo apt show php
OR
$ sudo apt show php -a
Show PHP Version Information
Package: php
Version: 1:7.0+35ubuntu6
Priority: optional
Section: php
Source: php-defaults (35ubuntu6)
Origin: Ubuntu
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Original-Maintainer: Debian PHP Maintainers <pkg-php-maint@lists.alioth.debian.org>
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 11.3 kB
Depends: php7.0
Supported: 5y
Download-Size: 2,832 B
APT-Sources: http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages
Description: server-side, HTML-embedded scripting language (default)
 PHP (recursive acronym for PHP: Hypertext Preprocessor) is a widely-used
 open source general-purpose scripting language that is especially suited
 for web development and can be embedded into HTML.
 .
 This package is a dependency package, which depends on Debian's default
 PHP version (currently 7.0).

To install the default PHP version from the Ubuntu software repositories, use the command below.

$ sudo apt install php

Install PHP (5.6, 7.0, 7.1) on Ubuntu Using PPA

1. First start by adding Ondřej Surý PPA to install different versions of PHP – PHP 5.6PHP 7.0 and PHP 7.1 on Ubuntu system.

$ sudo apt install python-software-properties
$ sudo add-apt-repository ppa:ondrej/php

Add PPA in Ubuntu

Add PPA in Ubuntu

2. Next, update the system as follows.

$ sudo apt-get update

3. Now install different supported versions of PHP as follows.

For Apache Web Server

$ sudo apt install php5.6   [PHP 5.6]
$ sudo apt install php7.0   [PHP 7.0]
$ sudo apt install php7.1   [PHP 7.1]

For Nginx Web Server

$ sudo apt install php5.6-fpm   [PHP 5.6]
$ sudo apt install php7.0-fpm   [PHP 7.0]
$ sudo apt install php7.1-fpm   [PHP 7.1]

4. To install any PHP modules, simply specify the PHP version and use the auto-completion functionality to view all modules as follows.

------------ press Tab key for auto-completion ------------ 
$ sudo apt install php5.6 
$ sudo apt install php7.0 
$ sudo apt install php7.1 

Search PHP Modules

Search PHP Modules

5. Now you can install most required PHP modules from the list.

------------ Install PHP Modules ------------
$ sudo apt install php5.6-cli php5.6-xml php5.6-mysql 
$ sudo apt install php7.0-cli php7.0-xml php7.0-mysql 
$ sudo apt install php7.1-cli php7.1-xml php7.1-mysql 

6. Finally, verify your default PHP version used on your system like this.

$ php -v 

Check Default PHP Version in Ubuntu

Check Default PHP Version in Ubuntu

Set Default PHP Version in Ubuntu

7. You can set the default PHP version to be used on the system with the update-alternatives command, after setting it, check the PHP version to confirm as follows.

------------ Set Default PHP Version 5.6 ------------
$ sudo update-alternatives --set php /usr/bin/php5.6

Set PHP 5.6 Version in Ubuntu

Set PHP 5.6 Version in Ubuntu

------------ Set Default PHP Version 7.0 ------------
$ sudo update-alternatives --set php /usr/bin/php7.0

Set PHP 7.0 Version in Ubuntu

Set PHP 7.0 Version in Ubuntu

------------ Set Default PHP Version 7.1 ------------
$ sudo update-alternatives --set php /usr/bin/php7.1

Set PHP 7.1 Version in Ubuntu

Set PHP 7.1 Version in Ubuntu

8. To set the PHP version that will work with Apache web server, use the commands below. First disable the current version with the a2dismod command and then enable the one you want with the a2enmod command.

$ sudo a2dismod php7.0
$ sudo a2enmod php7.1
$ sudo systemctl restart apache2

Enable Disable PHP Modules for Apache

Enable Disable PHP Modules for Apache

9. After switching from one version to another, you can find your PHP configuration file, by running the command below.

------------ For PHP 5.6 ------------
$ sudo update-alternatives --set php /usr/bin/php5.6
$ php -i | grep "Loaded Configuration File"

------------ For PHP 7.0 ------------
$ sudo update-alternatives --set php /usr/bin/php7.0
$ php -i | grep "Loaded Configuration File"

------------ For PHP 7,1 ------------
$ sudo update-alternatives --set php /usr/bin/php7.1
$ php -i | grep "Loaded Configuration File"

Find PHP Configuration File

Find PHP Configuration File

You may also like:

  1. How to Use and Execute PHP Codes in Linux Command Line
  2. 12 Useful PHP Commandline Usage Every Linux User Must Know
  3. How to Hide PHP Version in HTTP Header

In this article, we showed how to install all the supported versions of PHP in Ubuntu and its derivatives. If you have any queries or thoughts to share, do so via the feedback form below.

Source

How to Create an HTTP Proxy Using Squid on CentOS 7

Web proxies have been around for quite some time now and have been used by millions of users around the globe. They have a wide range of purposes, most popular being online anonymity, but there are other ways you can take advantage of web proxies. Here are some ideas:

  • Online anonymity
  • Improve online security
  • Improve loading times
  • Block malicious traffic
  • Log your online activity
  • To circumvent regional restrictions
  • In some cases can reduce bandwidth usage

How Proxy Server Works

The proxy server is a computer that is used as an intermediary between the client and other servers from which client may request resources. A simple example of this is when a client makes online requests (for example want to open a web page), he connects first to the proxy server.

The proxy server then checks its local disk cache and if the data can be found in there, it will return the data to the client, if not cached, it will make the request in the client’s behalf using the proxy IP address (different from the clients) and then return the data to the client. The proxy server will try to cache the new data and will use it for future requests made to the same server.

What is Squid Proxy

Squid is a web proxy used my wide range of organizations. It is often used as caching proxy and improving response times and reducing bandwidth usage.

For the purpose of this article, I will be installing Squid on a Linode CentOS 7 VPS and use it as an HTTP proxy server.

How to Install Squid on CentOS 7

Before we start, you should know that Squid, does not have any minimum requirements, but the amount of RAM usage may vary depending on the clients browsing the internet through the proxy server.

Squid is included in the base repository and thus the installation is simple and straightforward. Before installing it, however, make sure your packages are up to date by running.

# yum -y update

Proceed by installing squid, start and enable it on system startup using following commands.

# yum -y install squid
# systemctl start squid
# systemctl  enable squid

At this point your Squid web proxy should already be running and you can verify the status of the service with.

# systemctl status squid
Sample Output
 squid.service - Squid caching proxy
   Loaded: loaded (/usr/lib/systemd/system/squid.service; enabled; vendor preset: disabled)
   Active: active (running) since Thu 2018-09-20 10:07:23 UTC; 5min ago
 Main PID: 2005 (squid)
   CGroup: /system.slice/squid.service
           ├─2005 /usr/sbin/squid -f /etc/squid/squid.conf
           ├─2007 (squid-1) -f /etc/squid/squid.conf
           └─2008 (logfile-daemon) /var/log/squid/access.log

Sep 20 10:07:23 tecmint systemd[1]: Starting Squid caching proxy...
Sep 20 10:07:23 tecmint squid[2005]: Squid Parent: will start 1 kids
Sep 20 10:07:23 tecmint squid[2005]: Squid Parent: (squid-1) process 2007 started
Sep 20 10:07:23 tecmint systemd[1]: Started Squid caching proxy.

Here are some important file locations you should be aware of:

  • Squid configuration file: /etc/squid/squid.conf
  • Squid Access log: /var/log/squid/access.log
  • Squid Cache log: /var/log/squid/cache.log

A minimum squid.conf configuration file (without comments in it) looks like this:

acl localnet src 10.0.0.0/8	# RFC1918 possible internal network
acl localnet src 172.16.0.0/12	# RFC1918 possible internal network
acl localnet src 192.168.0.0/16	# RFC1918 possible internal network
acl localnet src fc00::/7       # RFC 4193 local private network range
acl localnet src fe80::/10      # RFC 4291 link-local (directly plugged) machines
acl SSL_ports port 443
acl Safe_ports port 80		# http
acl Safe_ports port 21		# ftp
acl Safe_ports port 443		# https
acl Safe_ports port 70		# gopher
acl Safe_ports port 210		# wais
acl Safe_ports port 1025-65535	# unregistered ports
acl Safe_ports port 280		# http-mgmt
acl Safe_ports port 488		# gss-http
acl Safe_ports port 591		# filemaker
acl Safe_ports port 777		# multiling http
acl CONNECT method CONNECT
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localhost manager
http_access deny manager
http_access allow localnet
http_access allow localhost
http_access deny all
http_port 3128
coredump_dir /var/spool/squid
refresh_pattern ^ftp:		1440	20%	10080
refresh_pattern ^gopher:	1440	0%	1440
refresh_pattern -i (/cgi-bin/|\?) 0	0%	0
refresh_pattern .		0	20%	4320

Configuring Squid as an HTTP Proxy

Here, we will show you how to configure squid as an HTTP proxy using only the client IP address for authentication.

Add Squid ACLs

If you wish to allow IP address to access the web through your new proxy server, you will need to add new acl(access control list) line in the configuration file.

# vim /etc/squid/squid.conf

The line you should add is:

acl localnet src XX.XX.XX.XX

Where XX.XX.XX.XX is the actual client IP address you wish to add. The line should be added in the beginning of the file where the ACLs are defined. It is a good practice to add a comment next to ACL which will describe who uses this IP address.

It is important to note that if Squid is located outside your local network, you should add the public IP address of the client.

You will need to restart Squid so the new changes can take effect.

# systemctl  restart squid

Open Squid Proxy Ports

As you may have seen in the configuration file, only certain ports are allowed for connecting. You can add more by editing the configuration file.

acl Safe_ports port XXX

Where XXX is the actual port you wish to load. Again it is a good idea to leave a comment next to that will describe what the port is going to be used for.

For the changes to take effect, you will need to restart squid once more.

# systemctl  restart squid

Squid Proxy Client Authentication

You will most probably want your users to authenticate before using the proxy. For that purpose, you can enable basic http authentication. It is easy and fast to configure.

First you will need httpd-tools installed.

# yum -y install httpd-tools

Now lets create a file that will later store the username for the authentication. Squid runs with user “squid” so the file should be owned by that user.

# touch /etc/squid/passwd
# chown squid: /etc/squid/passwd

Now we will create a new user called “proxyclient” and setup its password.

# htpasswd /etc/squid/passwd proxyclient

New password:
Re-type new password:
Adding password for user proxyclient

Now to configure the autnetication open the configuration file.

# vim /etc/squid/squid.conf

After the ports ACLs add the following lines:

auth_param basic program /usr/lib64/squid/basic_ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm Squid Basic Authentication
auth_param basic credentialsttl 2 hours
acl auth_users proxy_auth REQUIRED
http_access allow auth_users

Save the file and restart squid so that the new changes can take effect:

# systemctl restart squid

Block Websites on Squid Proxy

Finally we will create one last ACL that will help us block unwanted websites. First create the file that will store the blacklisted sites.

# touch /etc/squid/blacklisted_sites.acl

You can add some domains you wish to block. For example:

.badsite1.com
.badsite2.com

The proceding dot tells squid to block all referecnes to that sites including www.badsite1subsite.badsite1.cometc.

Now open Squid’s configuration file.

# vim /etc/squid/squid.conf

Just after the ports ACLs add the following two lines:

acl bad_urls dstdomain "/etc/squid/blacklisted_sites.acl"
http_access deny bad_urls

Now save the file and restart squid:

# systemctl restart squid

Once everyting configured correctly, now you can configure your local client browser or operating system’s network settings to use your squid HTTP proxy.

Conclusion

In this tutorial you learned how to install, secure and configure a Squid HTTP Proxy server on your own. With the information you just got, you can now add some basic filtering for incoming and outgoing traffic through Squid.

If you wish to go the extra mile, you can even configure squid to block some websites during working hours to prevent distractions. If you have any questions or comments, please post them in the comment section below.

Source

How to Setup “Squid Proxy” Server on Ubuntu and Debian

Squid is a most popular caching and forwarding HTTP web proxy server used my wide range of companies to cache web pages from a web server to improve web server speed, reduce response times and reduce network bandwidth usage.

Read AlsoHow to Create an HTTP Proxy Using Squid on CentOS 7

In this article, we will explain how to install a squid proxy server on Ubuntu and Debian distributions and use it as an HTTP proxy server.

How to Install Squid on Ubuntu

Before we begin, you should know that Squid server doesn’t have any requirements, but the amount of RAM utilization may differ based on the clients browsing the internet via the proxy server.

Squid package is available to install from the base Ubuntu repository, but before that make sure to update your packages by running.

$ sudo apt update

Once your packages are up to date, you can proceed further to install squid and start and enable it on system startup using following commands.

$ sudo apt -y install squid
$ sudo systemctl start squid
$ sudo systemctl enable squid

At this point your Squid web proxy should already be running and you can verify the status of the service with.

$ sudo systemctl status squid
Sample Output
● squid.service - LSB: Squid HTTP Proxy version 3.x
   Loaded: loaded (/etc/init.d/squid; generated)
   Active: active (running) since Tue 2018-12-04 06:42:43 UTC; 14min ago
     Docs: man:systemd-sysv-generator(8)
    Tasks: 4 (limit: 1717)
   CGroup: /system.slice/squid.service
           ├─2761 /usr/sbin/squid -YC -f /etc/squid/squid.conf
           ├─2766 (squid-1) -YC -f /etc/squid/squid.conf
           ├─2768 (logfile-daemon) /var/log/squid/access.log
           └─2772 (pinger)

Dec 04 06:42:43 tecmint systemd[1]: Starting LSB: Squid HTTP Proxy version 3.x...
Dec 04 06:42:43 tecmint squid[2708]:  * Starting Squid HTTP Proxy squid
Dec 04 06:42:43 tecmint squid[2708]:    ...done.
Dec 04 06:42:43 tecmint systemd[1]: Started LSB: Squid HTTP Proxy version 3.x.
Dec 04 06:42:43 tecmint squid[2761]: Squid Parent: will start 1 kids
Dec 04 06:42:43 tecmint squid[2761]: Squid Parent: (squid-1) process 2766 started

Following are the some important squid file locations you should be aware of:

  • Squid configuration file: /etc/squid/squid.conf
  • Squid Access log: /var/log/squid/access.log
  • Squid Cache log: /var/log/squid/cache.log

The default configuration file contains some configuration directives that needs to be configured to affect the behavior of the Squid.

Now open this file for editing using Vi editor and make changes as shown below.

$ sudo vim /etc/squid/squid.conf

Now, you may search about the following lines and change them as requested, in the Vi editor, you may search about those lines by hitting the ‘ESC’ and typing “/” key to writing the specific lines to look for.

  • http_port : This is the default port for the HTTP proxy server, by default it is 3128, you may change it to any other port that you want, you may also add the “transparent” tag to the end of the line like http_port 8888 transparent to make Squid proxy act like a transparent proxy if you want.
  • http_access deny all : This line won’t let anybody to access the HTTP proxy server, that’s why you need to change it to http_access allow all to start using your Squid proxy server.
  • visible_hostname : This directive is used to set the specific hostname to a squid server. You can give any hostname to squid.

After making above changes, you may restart the Squid proxy server using the command.

$ sudo systemctl restart squid

Configuring Squid as an HTTP Proxy on Ubuntu

In this squid configuration section, we will explain you how to configure squid as an HTTP proxy using only the client IP address for authentication.

Add Squid ACLs

If you wish to allow only one IP address to access the internet through your new proxy server, you will need to define new acl (access control list) in the configuration file.

$ sudo vim /etc/squid/squid.conf

The acl rule you should add is:

acl localnet src XX.XX.XX.XX

Where XX.XX.XX.XX is the IP address of client machine. This acl should be added in the beginning of the ACL’s section as shown in the following screenshot.

Add IP Address to Allow Web

Add IP Address to Allow Web

It is always a good practice to define a comment next to ACL which will describe who uses this IP address, for example.

acl localnet src 192.168.0.102  # Boss IP address

You will need to restart Squid service to take the new changes into effect.

$ sudo systemctl restart squid

Open Ports in Squid Proxy

By default, only certain ports are allowed in the squid configuration, if you wish to add more just define them in the configuration file as shown.

acl Safe_ports port XXX

Where XXX is the port number that you wish to allow. Again it is a good practive to define a comment next to acl that will describe what the port is going to be used for.

Add Ports in Squid Proxy

Add Ports in Squid Proxy

For the changes to take effect, you will need to restart squid once more.

$ sudo systemctl restart squid

Squid Proxy Client Authentication

To allow users to authenticate before using the proxy, you need to enable basic http authentication in the configuration file, but before that you need to install apache2-utils package using following command.

$ sudo apt install apache2-utils

Now create a file called “passwd” that will later store the username for the authentication. Squid runs with user “proxy” so the file should be owned by that user.

$ sudo touch /etc/squid/passwd
$ sudo chown proxy: /etc/squid/passwd
$ ls -l /etc/squid/passwd

Now we will create a new user called “tecmint” and setup its password.

$ sudo htpasswd /etc/squid/passwd tecmint

New password: 
Re-type new password: 
Adding password for user tecmint

Now to enable basic http authentication open the configuration file.

$ sudo vim /etc/squid/squid.conf

After the ports ACLs add the following lines:

auth_param basic program /usr/lib64/squid/basic_ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm Squid Basic Authentication
auth_param basic credentialsttl 2 hours
acl auth_users proxy_auth REQUIRED
http_access allow auth_users

Enable Squid User Authentication

Enable Squid User Authentication

Save the file and restart squid so that the new changes can take effect:

$ sudo systemctl restart squid

Block Websites on Squid Proxy

To block access to unwanted websites, first create a file called “blacklisted_sites.acl” that will store the blacklisted sites in it.

$ sudo touch /etc/squid/blacklisted_sites.acl

Now add the websites that you wish to block access, for example.

.badsite1.com
.badsite2.com

The proceeding dot informs squid to block all references to that sites including www.badsite1subsite.badsite1.com etc.

Now open Squid’s configuration file.

$ sudo vim /etc/squid/squid.conf

Just after the above ACLs add the following two lines:

acl bad_urls dstdomain "/etc/squid/blacklisted_sites.acl"
http_access deny bad_urls

Block Websites in Squid

Block Websites in Squid

Now save the file and restart squid:

$ sudo systemctl restart squid

Block Specific Keyword with Squid

To block a list of keywords, first create a file called “blockkeywords.lst” that will store the blacklisted keywords in it.

$ sudo touch /etc/squid/blockkeywords.lst

Now add the keywords that you wish to block access, for example.

facebook
instagram
gmail

Now open Squid’s configuration file and add the following rule.

acl blockkeywordlist url_regex "/etc/squid/blockkeywords.lst"
http_access deny blockkeywordlist

Now save the file and restart squid:

$ sudo systemctl restart squid

Once everything configured accurately, you can now configure your local client web browser or operating system’s network settings to use your newly configured squid HTTP proxy.

Configure Client to Use Squid Proxy

Now to test that your proxy server is working or not, you may open Firefox and go to Edit –> Preferences –> Advanced –> Network –> Settings and select “Manual proxy configuration” and enter your proxy server IP address and Port to be used for all connection as it follows.

Configure Client to Use Squid Proxy

Configure Client to Use Squid Proxy

Once you fill all the required proxy details, you will be able to surf the Web using your Squid proxy server, you may do the same thing in any other browser or program you want.

To make sure that you are surfing the web using your proxy server, you may visit http://www.ipaddresslocation.org/, in the right top corner you must see the same IP address as your server IP address.

For more additional configuration settings, you may check official squid documentation. If you have any questions or comments, please add them in the comment section below.

Source

Installation of Ubuntu 16.04 Server Edition and Initial Ubuntu Server Setup

Ubuntu Server 16.04, also named Xenial Xerus, has been released by Canonical and it’s now ready for installation.

The details about this new LTS version can be found on the previous article: How to upgrade Ubuntu 15.10 to 16.04.

This topic will guide you on how you can install Ubuntu 16.04 Server Edition with Long Time Support on your machine.

If you’re looking for Desktop Edition, read our previous article: Installation of Ubuntu 16.04 Desktop

Requirements

  1. Ubuntu 16.04 Server ISO Image

Install Ubuntu 16.04 Server Edition

1. On the first step visit the above link and download the latest version of Ubuntu Server ISO image on your computer.

Once the image download completes, burn it to a CD or create a bootable USB disk using Unbootin (for BIOS machines) or Rufus (for UEFI machines).

2. Place the bootable media intro the appropriate drive, start-up the machine and instruct the BIOS/UEFI by pressing a special function key (F2F11F12) to boot-up from the inserted USB/CD drive.

In a few seconds you will be presented with the first screen of Ubuntu installer. Select your language to perform the installation and hit Enter key to move to the next screen.

Choose Ubuntu 16.04 Server Installation Language

Choose Ubuntu 16.04 Server Installation Language

3. Next, select the first option, Install Ubuntu Server and press Enter key to continue.

Install Ubuntu 16.04 Server

Install Ubuntu 16.04 Server

4. Select the language you with to install the system and press Enter again to continue further.

Select Language for Ubuntu 16.04 Server

Select Language for Ubuntu 16.04 Server

5. On the next series of screen choose your physical location from the presented list. If your location is different than the ones offered on the first screen, select other and hit Enter key, then select the location based on your continent and country. This location will be also used by the timezone system variable. Use the below screenshots as a guide.

Choose Location for Ubuntu 16.04 Server

Choose Location for Ubuntu 16.04 Server

Select Country Region

Select Country Region

Select Area Location

Select Area Location

6. Assign the locales and keyboard settings for your system as illustrated below and hit Enter to continue the installation setup.

Configure Locales

Configure Locales

Configure Keyboard Layout

Configure Keyboard Layout

7. The installer will load a series of additional components required for the next steps and will automatically configure your network settings in case you have a DHCP server on the LAN.

Because this installation is intended for a server it’s a good idea to setup a static IP address for your network interface.

To do this you can interrupt the automatic network configuration process by pressing on Cancel or once the installer reaches hostname phase you can hit on Go Back and choose to Configure network manually.

Set Ubuntu 16.04 Hostname

Set Ubuntu 16.04 Hostname

Configure Network Manually

Configure Network Manually

8. Enter your network settings accordingly (IP Address, netmask, gateway and at least two DNS nameservers) as illustrated on the below images.

Set Static IP Address on Ubuntu 16.04

Set Static IP Address on Ubuntu 16.04

Configure Network Mask for Ubuntu 16.04

Configure Network Mask for Ubuntu 16.04

Configure Network Gateway for Ubuntu 16.04

Configure Network Gateway for Ubuntu 16.04

Configure Network DNS on Ubuntu 16.04

Configure Network DNS on Ubuntu 16.04

9. On the next step setup a descriptive hostname for your machine and a domain (not necessary required) and hit on Continue to move to the next screen. This step concludes the network settings.

Set Ubuntu 16.04 Server Hostname

Set Ubuntu 16.04 Server Hostname

Set Ubuntu 16.04 Domain Name

Set Ubuntu 16.04 Domain Name

10. On this step the installer prompts you to setup a username and a password for your system. This username will be granted by the system with sudo powers, so, technically, this user will be the supreme administrator next to root account (which is disabled by default).

Thus, choose an inspired username, maybe hard to guess for security reasons, with a strong password and hit on Continue. Choose not to encrypt your home directory and press Enter to continue further.

Setup User and Password

Setup User and Password

11. Next, the installer will automatically set your clock based on the physical location configured earlier. In case the location is correctly chosen hit on Yes to continue to disk partition layout.

Configure System Clock

Configure System Clock

12. On the next step you can choose the method that will be used to slice up your disk. For instance, if you need to create custom partition scheme (such as /home/var/boot etc) choose Manual method.

For a general purpose server you can stick to Guided with LVM method as illustrated below, which automatically creates the partitions on your behalf.

Select Partition Method

Select Partition Method

13. Next, select the disk that will be used by the installer to create partitions and press Enter key.

Select Disk Partition

Select Disk Partition

14. Answer with Yes at the next screen in order to commit changes to disk with LVM scheme and hit on Continue to use the entire disk space for guided partitions.

Add Disk Partition Size

Add Disk Partition Size

Confirm Disk Partition Changes

Confirm Disk Partition Changes

15. Finally, approve for the last time the changes to be written to disk by pressing on Yes and the installation will now begin. From this step on all the changes will be committed to disk.

Confirm Disk Partition Changes

Confirm Disk Partition Changes

Installing Ubuntu 16.04 Server

Installing Ubuntu 16.04 Server

16. In case your system is behind a proxy or a firewall use the next screen to bypass the network restrictions, otherwise just leave it black and hit on Continue.

Configure System Package Manager

Configure System Package Manager

17. Next, the installer will configure apt repositories and will install the selected software. After it finishes the installation tasks a new screen will appear which will ask you how to manage the upgrade process. Select Noautomatic updates for now (you will manually select what updates are necessary) and hit Enter key to continue.

Manage Ubuntu 16.04 Upgrades

Manage Ubuntu 16.04 Upgrades

18. On the next step you will be asked to select what software to install. Select only standard system utilities and OpenSSH server (if you require remote access) by pressing the spacebar key and hit on Continue.

System Software Selection

System Software Selection

19. Once the installer finishes installing the software, a new screen will prompt you whether to install the Grubboot loader to hard disk MBR (first 512 byte sector). Obviously without the GRUB you can’t boot up your system after restart, so hit on Yes to continue with the installation.

Install Grub Boot Loader

Install Grub Boot Loader

20. Finally, after the boot loader is written to Hard Disk MBR, the installation process finishes. Hit on Continue to reboot the machine and remove the installation media.

Finish Ubuntu 16.04 Server Installation

Finish Ubuntu 16.04 Server Installation

21. After reboot, login to your system console using the credentials configured during the installation process and you’re good to go on production with your server.

Ubuntu 16.04 Server Login Prompt

Ubuntu 16.04 Server Login Prompt

That’s all! Keep in mind that this version of Ubuntu has official maintenance support from Canonical until 2021for hardware, bugs, software and security updates.

Initial Ubuntu Server Setup for Beginners

This tutorial will guide you on the first basic steps you need to configure on a new installed Ubuntu server in order to increase security and reliability for your server.

The configurations explained in this topic are almost the same for all Ubuntu server systems, regarding of the underlying OS platform, whether Ubuntu is installed on a bare-metal server, in a private virtual machine or a virtual machine spinned-out in a VPS public cloud.

Requirements

  1. Ubuntu Server Edition installation

Update and Upgrade Ubuntu System

The first step you need to take care of in case of fresh installation of Ubuntu server or a new deployed Ubuntu VPS is to make sure the system and all system components, such as the kernel, the package manager and all other installed packages are up-to-date with the latest released versions and security patches.

To update Ubuntu server, to log in to server’s console with an account with root privileges or directly as root and run the below commands in order to perform the update and upgrade process.

$ sudo apt update 

Update Ubuntu Server

Update Ubuntu Server

After running the update command, you will see the number of available packages for upgrading process and the command used for listing the packages upgrades.

$ sudo apt list --upgradable

List Upgrade Ubuntu Packages

List Upgrade Ubuntu Packages

After you’ve consulted the list of packages available for upgrading, issue the below command to start system upgrade process.

$ sudo apt upgrade

Upgrade Ubuntu Server Packages

Upgrade Ubuntu Server Packages

In order to remove all locally downloaded deb packages and all other apt-get caches, execute the below command.

$ sudo apt autoremove
$ sudo apt clean

Autoremove APT Packages and Cache

Autoremove APT Packages and Cache

Create New Account in Ubuntu

By default, as a security measure, the root account is completely disabled in Ubuntu. In order to create a new account on the system, log in to the system with the account user with root privileges and create a new account with the below command.

This new account will be granted with root powers privileges via sudo command and will be used to perform administrative tasks in the system. Make sure you setup a strong password to protect this account. Follow the adduser prompt to setup the user details and password.

$ sudo adduser ubuntu_user

Create User in Ubuntu

Create User in Ubuntu

If this account will be assigned to another system admin, you can force the user to change its password at the first log in attempt by issuing the following command.

$ sudo chage -d0 ubuntu_user

For now, the new added user cannot perform administrative tasks via sudo utility. To grant this new user account with administrative privileges you should add the user to “sudo” system group by issuing the below command.

$ sudo usermod -a -G sudo ubuntu_user

By default, all users belonging to the “sudo” group are allowed to execute commands with root privileges via sudo utility. Sudo command must be used before writing the command needed for execution, as shown in the below example.

$ sudo apt install package_name

Test if the new user has the root privileges granted, by logging in to the system and run the apt updatecommand prefixed with sudo.

$ su - ubuntu_user
$ sudo apt update

Verify New User

Verify New User

Configure System Hostname in Ubuntu

Usually, the machine hostname is set-up during the system installation process or when the VPS is created in the cloud. However, you should change the name of your machine in order to better reflect the destination of your server or to better describe its final purpose.

In a large company, machines are named after complex naming schemes in order to easily identify the machine in datacenter’s racks. For instance, if your Ubuntu machine will operate a mail server, the name of the machine should reflect this fact and you can setup machine hostname as mx01.mydomain.lan, for example.

To show details about your machine hostname run the following command.

$ hostnamectl

In order to change the name of your machine, issue hostnamectl command with the new name you will configure for your machine, as illustrated in the below excerpt.

$ sudo hostnamectl set-hostname tecmint

Verify the new name of your system with one of the below commands.

$ hostname
$ hostname -s
$ cat /etc/hostname 

Set Hostname in Ubuntu Server

Set Hostname in Ubuntu Server

Setup SSH with Public Key Authentication in Ubuntu

To increase system security degree of an Ubuntu server, you should set-up SSH public key authentication for an local account. In order to generate SSH Key Pair, the public and private key, with a specifying a key length, such as 2048 bits, execute the following command at your server console.

Make sure you’re logged in to the system with the user you’re setting up the SSH key.

$ su - ubuntu_user
$ ssh-keygen -t RSA -b 2048

Setup SSH Keys in Ubuntu

Setup SSH Keys in Ubuntu

While the key is generated, you will be prompted to add passphrase in order to secure the key. You can enter a strong passphrase or choose to leave the passphrase blank if you want to automate tasks via SSH server.

After the SSH key has been generated, you can copy the public key to a remote server by executing the below command. To install the public key to the remote SSH server you will need a remote user account with the proper permissions and credentials to log in to remote server.

$ ssh-copy-id remote_user@remote_server

Copy SSH Key to Remote Server

Copy SSH Key to Remote Server

You should be able to automatically log in via SSH to the remote server using the public key authentication method. You won’t need to add the remote user password while using SSH public key authentication.

After you’ve logged in to the remote server, you can start to execute commands, such as w command to list ssh remote logged in users, as shown in the below screenshot.

Type exit in the console to close the remote SSH session.

$ ssh remote_user@remote_server
$ w
$ exit

Verify SSH Passwordless Login

Verify SSH Passwordless Login

To see the content of your public SSH key in order to manually install the key to a remote SSH server, issue the following command.

$ cat ~/.ssh/id_rsa.pub

View SSH Key

View SSH Key

Secure SSH Server in Ubuntu

In order to secure the SSH daemon you should change the default SSH port number from 22 to a random port, higher than 1024, and disallow remote SSH access to the root account via password or key, by opening SSH server main configuration file and make the following changes.

$ sudo vi /etc/ssh/sshd_config

First, search the commented line #Port22 and add a new line underneath (replace the listening port number accordingly):

Port 2345

Don’t close the file, scroll down and search for the line #PermitRootLogin yes, uncomment the line by removing the # sign (hashtag) from the beginning of the line and modify the line to look like shown in the below excerpt.

PermitRootLogin no

Secure SSH Service

Secure SSH Service

Afterwards, restart the SSH server to apply the new settings and test the configuration by trying to log in from a remote machine to this server with the root account via the new port number. The access to root account via SSH should be restricted.

$ sudo systemctl restart sshd

Also, run netstat or ss command and filter the output via grep in order to show the new listening port number for SSH server.

$ sudo ss -tlpn| grep ssh
$ sudo netstat -tlpn| grep ssh

Verify SSH Port

Verify SSH Port

There are situations where you might want to automatically disconnect all remote SSH connections established into your server after a period of inactivity.

In order to enable this feature, execute the below command, which adds the TMOUT bash variable to your account .bashrc hidden file and forces every SSH connection made with the name of the user to be disconnected or dropped-out after 5 minutes of inactivity.

$ echo 'TMOUT=300' >> .bashrc

Run tail command to check if the variable has been correctly added at the end of .bashrc file. All subsequent SSH connections will be automatically closed after 5 minutes of inactivity from now on.

$ tail .bashrc

In the below screenshot, the remote SSH session from drupal machine to Ubuntu server via ubuntu_user account has been timed out and auto-logout after 5 minutes.

Auto Disconnect SSH Sessions

Auto Disconnect SSH Sessions

Configure Ubuntu Firewall UFW

Every server needs a well configured firewall in order to secure the system at network level. Ubuntu server uses UFW application to manage the iptables rules on the server.

Check the status of UFW firewall application in Ubuntu by issuing the below commands.

$ sudo systemctl status ufw
$ sudo ufw status

Check UFW Firewall Status

Check UFW Firewall Status

Usually, the UFW firewall daemon is up and running in Ubuntu server, but the rules are not applied by default. Before enabling UFW firewall policy in you system, first you should add a new rule to allow SSH traffic to pass through firewall via the changed SSH port. The rule can be added by executing the below command.

$ sudo ufw allow 2345/tcp

After you’ve allowed SSH traffic, you can enable and check UFW firewall application with the following commands.

$ sudo ufw enable
$ sudo ufw status

Open SSH Port and Verify

Open SSH Port and Verify

To add new firewall rules for other network services subsequently installed on your server, such as HTTP server, a mail server or other network services, use the below firewall commands examples as guide.

$ sudo ufw allow http  #allow http traffic
$ sudo ufw allow proto tcp from any to any port 25,443  # allow https and smtp traffic

To list all firewall rules run the below command.

$ sudo ufw status verbose

Check UFW Firewall Rules

Check UFW Firewall Rules

Set Ubuntu Server Time

To control or query Ubuntu server clock and other related time settings, execute timedatectl command with no argument.

In order to change your server’s time zone settings, first execute timedatectl command with list-timezones argument to list all available time zones and, then, set the time zone of your system as shown in the below excerpt.

$ sudo timedatectl 
$ sudo timedatectl list-timezones 
$ sudo timedatectl set-timezone Europe/Vienna

Set Ubuntu Timezone

Set Ubuntu Timezone

The new systemd-timesyncd systemd daemon client can be utilized in Ubuntu in order to provide an accurate time for your server across network and synchronize time with an upper time peer server.

To apply this new feature of Systemd, modify systemd-timesyncd daemon configuration file and add the closest geographically NTP servers to NTP statement line, as shown in the below file excerpt:

$ sudo nano /etc/systemd/timesyncd.conf

Add following configuration to timesyncd.conf file:

[Time]
NTP=0.pool.ntp.org 1.pool.ntp.org
FallbackNTP=ntp.ubuntu.com

NTP Time Configuration

NTP Time Configuration

To add your nearest geographically NTP servers, consult the NTP pool project server list at the following address: http://www.pool.ntp.org/en/

Afterwards, restart the Systemd timesync daemon to reflect changes and check daemon status by running the below commands. After restart, the daemon will start to sync time with the new ntp server peer.

$ sudo systemctl restart systemd-timesyncd.service 
$ sudo systemctl status systemd-timesyncd.service

Start TimeSyncd Service

Start TimeSyncd Service

Disable and Remove Unneeded Services in Ubuntu

In order to get a list of all TCP and UDP network services up-and-running by default in your Ubuntu server, execute the ss or netstat command.

$ sudo netstat -tulpn
OR
$ sudo ss -tulpn

List All Running Services

List All Running Services

Staring with Ubuntu 16.10 release, the default DNS resolver is now controlled by systemd-resolved service, as revealed by the output of netstat or ss commands.

You should also check the systemd-resolved service status by running the following command.

$ sudo systemctl status systemd-resolved.service

Check Systemd Resolved Status

Check Systemd Resolved Status

The systemd-resolved service binds on all enabled network interfaces and listens on ports 53 and 5355 TCPand UDP.

Running system-resolved caching DNS daemon on a production server can be dangerous due to the numerous number of DDOS attacks performed by malicious hackers against unsecured DNS servers.

In order to stop and disable this service, execute the following commands.

$ sudo systemctl stop systemd-resolved
$ sudo systemctl disable systemd-resolved

Disable Systemd Resolved Service

Disable Systemd Resolved Service

Verify if the service has been stopped and disabled by issuing ss or netstat command. The systemd-resolved listening ports, 53 and 5355 TCP and UDP, should not be listed in netstat or ss command output, as illustrated in the below.

You should also reboot the machine in order to completely disable all systemd-resolved daemon services and restore the default /etc/resolv.conf file.

$ sudo ss -tulpn
$ sudo netstat -tulpn
$ sudo systemctl reboot

Verify All Running Services

Verify All Running Services

Although, you’ve disabled some unwanted networking services to run in your server, there are also other services installed and running in your system, such as lxc process and snapd service. These services can be easily detected via pstop or pstree commands.

$ sudo ps aux
$ sudo top
$ sudo pstree

List Running Services in Tree Format

List Running Services in Tree Format

In case you’re not going to use LXC container virtualization in your server or start installing software packaged via Snap package manager, you should completely disable and remove these services, by issuing the below commands.

$ sudo apt autoremove --purge lxc-common lxcfs
$ sudo apt autoremove --purge snapd

That’s all! Now, Ubuntu server is now prepared for installing additional software needed for custom network services or applications, such as installing and configuring a web server, a database server, a file share service or other specific applications.

Source

How to Install Ubuntu via PXE Server Using Local DVD Sources

PXE or Preboot eXecution Environment is a server-client mechanism which instructs a client machine to boot form network.

In this guide we’ll show how to install Ubuntu Server via a PXE server with local HTTP sources mirrored from Ubuntu server ISO image via Apache web server. The PXE server used in this tutorial is Dnsmasq Server.

Requirements:

  1. Ubuntu Server 16.04 or 17.04 Installation
  2. A network interface configured with Static IP address
  3. Ubuntu Server 16.04 or 17.04 ISO image

Step 1: Install and Configure DNSMASQ Server

1. In order to setup the PXE server, on the first step login with the root account or an account with root privileges and install Dnsmasq package in Ubuntu by issuing the following command.

# apt install dnsmasq

2. Next, backup dnsmasq main configuration file and then start editing the file with the following configurations.

# mv /etc/dnsmasq.conf /etc/dnsmasq.conf.backup
# nano /etc/dnsmasq.conf

Add the following configuration to dnsmasq.conf file.

interface=ens33,lo
bind-interfaces
domain=mypxe.local

dhcp-range=ens33,192.168.1.230,192.168.1.253,255.255.255.0,1h
dhcp-option=3,192.168.1.1
dhcp-option=6,192.168.1.1
dhcp-option=6,8.8.8.8
server=8.8.4.4
dhcp-option=28,10.0.0.255
dhcp-option=42,0.0.0.0

dhcp-boot=pxelinux.0,pxeserver,192.168.1.14

pxe-prompt="Press F8 for menu.", 2
pxe-service=x86PC, "Install Ubuntu 16.04 from network server 192.168.1.14", pxelinux
enable-tftp
tftp-root=/srv/tftp

On the above configuration file replace the following lines accordingly.

  • interface Replace with your own machine network interface.
  • domain – Replace it with your domain name.
  • dhcp-range – Define your own network range for DHCP to allocate IPs to this network segment and how long should an IP address for a client should be granted.
  • dhcp-option=3 – Your Gateway IP.
  • dhcp-option=6 DNS Server IPs – several DNS IPs can be defined.
  • server – DNS forwarder IPs Address.
  • dhcp-option=28 – Your network broadcast address.
  • dhcp-option=42 – NTP server – use 0.0.0.0 Address is for self-reference.
  • dhcp-boot – the pxe boot file and the IP address of the PXE server (here pxelinux.0 and IP address of the same machine).
  • pxe-prompt – Uses can hit F8 key to enter PXE menu or wait 2 seconds before automatically switching to PXE menu.
  • pxe=service – Use x86PC for 32-bit/64-bit architectures and enter a menu description prompt under string quotes. Other values types can be: PC98, IA64_EFI, Alpha, Arc_x86, Intel_Lean_Client, IA32_EFI, BC_EFI, Xscale_EFI and X86-64_EFI.
  • enable-tftp – Enables the build-in TFTP server.
  • tftp-root – the system path for net boot files.

3. Also, after you’ve finished editing the dnsmasq configuration file, create the directory for the PXE netboot files by issuing the below command and restart dnsmasq daemon to apply changes. Check dnsmasq service status to see if it has been started.

# mkdir /srv/tftp
# systemctl restart dnsmasq.service
# systemctl status dnsmasq.service

Step 2: Install TFTP Netboot Files

4. On the next step grab the latest version of Ubuntu server ISO image for 64-bit architecture by issuing the following command.

# wget http://releases.ubuntu.com/16.04/ubuntu-16.04.3-server-amd64.iso

5. After Ubuntu server ISO has been downloaded, mount the image in /mnt directory and list the mounted directory content by running the below commands.

# mount -o loop ubuntu-16.04.3-desktop-amd64.iso /mnt/
# ls /mnt/

Verify Ubuntu ISO Files

Verify Ubuntu ISO Files

6. Next, copy the netboot files from Ubuntu mounted tree to tftp system path by issuing the below command. Also, list tftp system path to see the copied files.

# cp -rf /mnt/install/netboot/* /srv/tftp/
# ls /srv/tftp/

Copy and Verify TFTP Files

Copy and Verify TFTP Files

Step 3: Prepare Local Installation Source Files

7. The local network installation sources for Ubuntu server will be provided via HTTP protocol. First, install, start and enable Apache web server by issuing the following commands.

# apt install apache2
# systemctl start apache2
# systemctl status apache2
# systemctl enable apache2

8. Then, copy the content of the mounted Ubuntu DVD to Apache web server web root path by executing the below commands. List the content of Apache web root path to check if Ubuntu ISO mounted tree has been completely copied.

# cp -rf /mnt/* /var/www/html/
# ls /var/www/html/

9. Next, open HTTP port in firewall and navigate to your machine IP address via a browser (http://192.168.1.14/ubuntu) in order to test if you can reach sources via HTTP protocol.

# ufw allow http

Check HTTP Ubuntu Sources

Check HTTP Ubuntu Sources

Step 4: Setup PXE Server Configuration File

10. In order to be able to pivot the rootfs via PXE and local sources, Ubuntu needs to be instructed via a preseed file. Create the following local-sources.seed file in your web server document root path with the following content.

# nano /var/www/html/ubuntu/preseed/local-sources.seed

Add following line to local-sources.seed file.

d-i live-installer/net-image string http://192.168.1.14/ubuntu/install/filesystem.squashfs

Here, make sure you replace the IP address accordingly. It should be the IP address where web resources are located. In this guide the web sources, the PXE server and TFTP server are hosted on the same system. In a crowded network you might want to run PXE, TFTP and web services on separate machines in order to improve PXE network speed.

11. A PXE Server reads and executes configuration files located in pxelinux.cfg TFTP root directory in this order: GUID files, MAC files and default file.

The directory pxelinux.cfg is already created and populated with the required PXE configuration files because we’ve earlier copied the netboot files from Ubuntu mounted ISO image.

In order to add the above preseed statement file to Ubuntu installation label in PXE configuration file, open the following file for editing by issuing the below command.

# nano /srv/tftp/ubuntu-installer/amd64/boot-screens/txt.cfg

In Ubuntu PXE txt.cfg configuration file replace the following line as illustrated in the below excerpt.

append auto=true url=http://192.168.1.14/ubuntu/preseed/local-sources.seed vga=788 initrd=ubuntu-installer/amd64/initrd.gz --- quiet

The /srv/tftp/ubuntu-installer/amd64/boot-screens/txt.cfg file should have the following global content:

default install
label install
	menu label ^Install Ubuntu 16.04 with Local Sources
	menu default
	kernel ubuntu-installer/amd64/linux
	append auto=true url=http://192.168.1.14/ubuntu/preseed/local-sources.seed vga=788 initrd=ubuntu-installer/amd64/initrd.gz --- quiet 
label cli
	menu label ^Command-line install
	kernel ubuntu-installer/amd64/linux
	append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false vga=788 initrd=ubuntu-installer/amd64/initrd.gz --- quiet

12. In case you want to add the preseed url statement to Ubuntu Rescue menu, open the below file and make sure you update the content as illustrated in the below example.

# nano /srv/tftp/ubuntu-installer/amd64/boot-screens/rqtxt.cfg

Add the followng configuration to rqtxt.cfg file.

label rescue
	menu label ^Rescue mode
	kernel ubuntu-installer/amd64/linux
	append auto=true url=http://192.168.1.14/ubuntu/preseed/local-sources.seed vga=788 initrd=ubuntu-installer/amd64/initrd.gz rescue/enable=true --- quiet

The important line you should update is url=http://192.168.1.14/ubuntu/preseed/local-sources.seed which specifies the URL address where the pressed file is located in your network.

13. Finally, open Ubuntu pxe menu.cfg file and comment the first three lines in order to expand the PXE boot screen as illustrated in the below screenshot.

# nano /srv/tftp/ubuntu-installer/amd64/boot-screens/menu.cfg

Comment these three following lines.

#menu hshift 13
#menu width 49
#menu margin 8

PXE Menu Configuration

PXE Menu Configuration

Step 5: Open Firewall Ports in Ubuntu

14. Execute netstat command with root privileges to identify dnsmasq, tftp and web open ports in listening state on your server as illustrated in the below excerpt.

# netstat -tulpn

Verify Open Ports

Verify Open Ports

15. After you’ve identified all required ports, issue the below commands to open the ports in ufw firewall.

# ufw allow 53/tcp
# ufw allow 53/udp
# ufw allow 67/udp
# ufw allow 69/udp
# ufw allow 4011/udp

Step 6: Install Ubuntu with Local Sources via PXE

16. To install Ubuntu server via PXE and use the local network installation sources, reboot your machine client, instruct the BIOS to boot from network and at the first PXE menu screen choose the first option as illustrated in the below images.

Select Network Boot

Select Network Boot

Select PXE Boot Option

Select PXE Boot Option

Install Ubuntu using PXE

Install Ubuntu using PXE

17. The installation procedure should be performed as usual. When the installer reaches the Ubuntu archive mirror country setup, use the up keyboard arrow to move to the first option, which says: enter information manually.

Select Ubuntu Mirror Archive

Select Ubuntu Mirror Archive

18. Press [enter] key to update this option, delete the mirror string and add the IP address of the web server mirror sources and press enter to continue as illustrated in the below image.

http://192.168.1.14

Enter Ubuntu Mirror Archive Hostname

Enter Ubuntu Mirror Archive Hostname

19. On the next screen, add your mirror archive directory as shown below and press enter key to continue with the installation process and usually.

/ubuntu

Select Ubuntu Mirror Archive Directory

Select Ubuntu Mirror Archive Directory

20. In case you want to see information about what packages are downloaded from your network local mirror, press [CTRL+ALT+F2] keys in order to change machine virtual console and issue the following command.

# tail –f /var/log/syslog

Check Network Mirror Logs

Check Network Mirror Logs

21. After the installation of the Ubuntu server finishes, login to the newly installed system and run the following command with root privileges in order to update the repositories packages from local network sources to official Ubuntu mirrors.

The mirrors needs to be changed in order to update the system using the internet repositories.

$ sudo sed –i.bak ‘s/192.168.1.14/archive.ubuntu.com/g’ /etc/apt/sources.list

Change Ubuntu Network Sources

Change Ubuntu Network Sources

Assure you replace the IP address according to the IP address of your own web local sources.

Official Ubuntu Network Sources

Official Ubuntu Network Sources

That’s all! You can now update your Ubuntu server system and install all required software. Installing Ubuntu via PXE and a local network source mirror can improve the installation speed and can save internet bandwidth and costs in case of deploying a large number of servers in a short period of time at your premises.

Source

How to Block USB Storage Devices in Linux Servers

In order to protect sensitive data extraction from servers by users who have physical access to machines, it’s a best practice to disable all USB storage support in Linux kernel.

In order to disable USB storage support, we first need to identify if the storage driver is loaded into Linux kernel and the name of the driver (module) responsible with storage driver.

Run the lsmod command to list all loaded kernel drivers and filter the output via grep command with the search string “usb_storage”.

# lsmod | grep usb_storage

List USB Storage Drivers

List USB Storage Drivers

From lsmod command, we can see that the sub_storage module is in use by UAS module. Next, unload both USB storage modules from kernel and verify if the removal has been successfully completed, by issuing the below commands.

# modprobe -r usb_storage
# modprobe -r uas
# lsmod | grep usb

Next, list the content of the current runtime kernel usb storage modules directory by issuing the below command and identify the usb-storage driver name. Usually this module should be named usb-storage.ko.xz or usb-storage.ko.

# ls /lib/modules/`uname -r`/kernel/drivers/usb/storage/

In order to block USB storage module form loading into kernel, change directory to kernel usb storage modules path and rename the usb-storage.ko.xz module to usb-storage.ko.xz.blacklist, by issuing the below commands.

# cd /lib/modules/`uname -r`/kernel/drivers/usb/storage/
# ls
# mv usb-storage.ko.xz usb-storage.ko.xz.blacklist

Block USB Storage in Linux

Block USB Storage in Linux

In Debian based Linux distributions, issue the below commands to block usb-storage module from loading into Linux kernel.

# cd /lib/modules/`uname -r`/kernel/drivers/usb/storage/ 
# ls
# mv usb-storage.ko usb-storage.ko.blacklist

Block USB in Debian and Ubuntu

Block USB in Debian and Ubuntu

Now, whenever you plug-in a USB storage device, the kernel will be fail to load the storage device driver intro kernel. To revert changes, just rename the usb module blacklisted back to its old name.

# cd /lib/modules/`uname -r`/kernel/drivers/usb/storage/
# mv usb-storage.ko.xz.blacklist usb-storage.ko.xz

However, this method applies only to runtime kernel modules. In case you want to blacklist USB storage modules form all available kernels in the system, enter each kernel module directory version path and rename the usb-storage.ko.xz to usb-storage.ko.xz.blacklist.

Source

Showterm.io – A Terminal/Shell Recording, Upload and Share Tool for Linux

For recording Desktop screen there are a bunch of software’s available on the web, but have you ever thought about recording your Terminal? Well, it’s very much possible thanks to this nifty little program called Showterm.

Install Showterm.io in Linux

Install Showterm.io in Linux

What is Showterm?

Showterm is an open source terminal record and upload application that lets you easy to record how-to in your terminal. It will record all your terminal activity in text-base and upload to showterm.io as a video and then generates a link for you to share with your team-mates or embed it in your website as an iframe. Here’s an example of Demo:

Installation of Showterm in Linux

You can install showterm tool using two different methods. The recommended way is to use ruby, if you’ve rubycorrectly installed and configured on your system, then you can install it using gem command. If ruby doesn’t installed, you can install it using following commands.

On Debian/Ubuntu/Linux Mint

# sudo apt-get install ruby rubygems
# sudo gem install showterm
Sample Output
[sudo] password for tecmint: 
Fetching: showterm-0.5.0.gem (100%)
Building native extensions.  This could take a while...
Successfully installed showterm-0.5.0
1 gem installed
Installing ri documentation for showterm-0.5.0...
Installing RDoc documentation for showterm-0.5.0...

On RHEL/CentOS/Fedora

# yum install ruby rubygems
# gem install showterm
Sample Output
Building native extensions.  This could take a while...
Successfully installed showterm-0.5.0
1 gem installed
Installing ri documentation for showterm-0.5.0...
Installing RDoc documentation for showterm-0.5.0...

If your system does not have ruby configured correctly, you can install showterm in your bin directory with the following commands.

$ curl showterm.io/showterm > ~/bin/showterm
$ chmod +x ~/bin/showterm

How to Use Showterm

The syntax to start recording is “showterm [program to run]“. If you omit the program to run and just type in “showterm“.

# showterm

It’ll start recording your shell. Once you are done recording, you can stop it by typing in either exit or “Ctrl­D“.

# exit

Once you type exit it will record and upload your actions. When finished upload, it will generate a link at the end of each recording which you can share.

showterm recording finished.
Uploading...
http://showterm.io/9d34dc53ab91185448ef8

Here is a showterm recording that shows it’s usage:

I will use two showterm recording windows so as to demonstrate how to use it. This is the main showterm recording window inside which I will start another showterm window so as to demonstrate how to use it. In other words, I will use showterm itself to demonstrate how to use showterm! Isn’t that cool?

I start the first showterm recording window and then start another recording window inside the first window by typing command “showterm“.

Now whatever I do here will be recorded in both the first and second showterm window. Typing in exit once will take us out of the second showterm window and typing in exit again will take us out of the first showterm window.

You can also change the speed at which it is played or stop it completely by appending the following to the links:

  1. #slow : To make it go slower. It actually plays the recording at real time speed.
  2. #fast : To make it go faster.It actually plays the recording at double the original speed.
  3. #stop : To stop it.

For example, you can slow the showterm recording by appending #slow to this link as shown below.

http://showterm.io/d1311caa9df1aa7cdb828#slow

Embedding with iframes

If you want to embed showterms in your website, you can embed it using the iframe tag. For example, to embed link “http://showterm.io/d1311caa9df1aa7cdb828“, you can add the following iframe code to your website.

<iframe src=”http://showterm.io/d1311caa9df1aa7cdb828” width=”640” height=”480”></iframe>

Conclusion

There’s a whole range of applications for it! Whether you are teaching a class full of students or want to teach someone about how to install an application or show them how to run a particular program on terminal, showterm is the way to go!

Also, it’s an open source application so, if you want to contribute to it, here’s the link to its source:

  1. Showterm Homepage
  2. Showterm Client on GitHub
  3. Showterm Server on GitHub

Read AlsoRecord Programs and Games Using Simple Screen Recorder

Source

Zulip – Most Productive Chat Application for Group or Team Chat

Zulip is an open source, powerful and easily extendable group or team chat application powered by Electron and React Native. It runs on every major operating system: Linux, Windows, MacOS; Android, iOS, and also has a web client.

It supports over 90 native integrations with external applications, under different categories including interactive bots, version control (Github, Codebase, Bitbucket etc.), communication, customer support, deployment, financial (Stripe), marketing, monitoring tools (Nagios and more), integration frameworks, productivity (Drop box, Google calender etc.) and so many others.

Zulip Features:

  • Supports various types of notifications.
  • Supports keyboard shortcuts.
  • Supports a multilanguage spellchecker.
  • Allows you to sign in to multiple teams.
  • Offers a RESTful API and Python bindings for integration purposes.
  • Supports a multitude of languages.
  • Supports video calls and chat history.
  • Also allows for full-text full-history search.
  • Supports invite-only conversations.
  • Supports private one-on-one or group conversations.
  • Allows you to keep track of messages that are of interest to you.
  • Shows who is currently online.
  • Supports draft messages.
  • Also supports typing notifications and much more.

How to Install Zulip Chat Application on Linux

On Debian/Ubuntu systems, you can install it from the Zulip desktop apt repository via the apt command.

First setup the zulip desktop app repository on your system and add its signing key, as follows, from a terminal.

$ sudo apt-key adv --keyserver pool.sks-keyservers.net --recv 69AD12704E71A4803DCA3A682424BE5AE9BD10D9
$ echo "deb https://dl.bintray.com/zulip/debian/ stable main" | sudo tee -a /etc/apt/sources.list.d/zulip.list

Then update your apt package sources cache and install the zulip client as shown.

$ sudo apt update
$ sudo apt install zulip

Once the installation is complete, search for zulip from your system menu and launch it, or run the zulip command from a terminal.

$ zulip

On other Linux distributions, you can install it via an AppImage. Go to the download page or use the wget command below to grab the appimage.

$ wget -c https://github.com/zulip/zulip-electron/releases/download/v1.9.0/Zulip-1.9.0-x86_64.AppImage

After downloading it, make the file executable and run it.

$ chmod a+x Zulip-x.x.x-x86_64.AppImage 
$ ./Zulip-x.x.x-x86_64.AppImage 

Note: If you use it this way, the app will not update automatically, you will need to repeat the above instructions to upgrade to newer versions.

How to Use Zulip Chat Application

When you launch zulip for the first time, you will land in the interface shown in the following screenshot, where you can add an organization. Click on Create a new organization, you will be redirected to the zulip website where you can create a new organization.

Create Zulip Organization

Create Zulip Organization

Add your email address and click on Create organization.

Add Organization Email

Add Organization Email

Next, a link to complete your signup will be sent to your email. After opening the link, register by providing your full name, password, organization name, organization URL (address you’ll use to log in to your organization) and accept terms of service. Then click on Sign Up.

You can continue to use the web client or back on the desktop app, use your organization URL to log in to your organization.

Add Organization URL

Add Organization URL

Then log into zulip with your email address and password as shown in the following screenshot.

Login into Zulip Organization

Login into Zulip Organization

Zulip Organization Chat

Zulip Organization Chat

Next, you can invite more users in your organization, and customize zulip to fit your organization’s needs, under settings.

Zulip Homepagehttps://zulipchat.com/

Zulip is a cross-platform, powerful and highly extensible group chat application. Try it out and share your experience with us via the comment form below.

Source

4 Best Open Source Bulk SMS Gateway Software

Today, SMS (Short Message Service) has become more popular, it widely used all over the world in huge amounts for various business processes such as SMS Marketing, apart from the conventional communication platform. An SMS gateway allows a computer system to send or receive SMS to or from a telecommunications network, thus to or from mobile phones of clients.

There are a number of industry focused open source SMS gateway software solutions you can use to run your bulk SMS services. If you are searching for one, then this article is meant for you, you can check out the list below.

1. Jasmin – SMS Gateway

Jasmin is a free, open-source, very powerful, easily customizable, and high-performance SMS Gateway solution, built for full in-memory execution. It is intended for environments with traffic-clogged systems to meet specific business message exchange needs.

Jasmin SMS Gateway

Jasmin SMS Gateway

It comes with several enterprise-grade features for message exchange such as a web UI for SMS management, standard and advanced message filtering, SMPP client/server, HTTP client/server, AMQP messaging, flexible in-memory billing and processing, advanced message routing/filtering, Unicode and long messages support.

It allows for high availability services through auto reconnection and re-routing procedures during the busiest hours or link failover. Jasim supports intelligent routing configurable in real-time via an API, CLI interface or a web backend, and so much more.

2. PlaySMS – SMS Gateway

PlaySMS is a free, open source, flexible and fully-featured web-based SMS management system. It can be used for services such as an SMS gateway, bulk SMS provider, personal messaging tool, enterprise and group communication system, and it can handle large amount of SMS. Notably, you can configure multiple domains on a single playSMS installation (with site branding for reseller supports).

PlaySMS - SMS Gateway

PlaySMS – SMS Gateway

It supports various ways of handling and routing SMS simply from web-based mobile portal system, with a multi-language user interface. For Linux geeks, PlaySMS can also be used to send SMS command, execute server side shell script via SMS. In addition, there is an Android app you can use, available on Google Play Store, and more.

3. Kannel – WAP and SMS Gateway

Kannel is a free, open source, very powerful and widely used popular WAP (Wireless Application Protocol) and SMS gateway solution. It is primarily developed on Linux systems, and can be ported to other Unix-like systems. It is used for SMS exchange, serving WAP Push service indications, as well as providing mobile internet access.

Kannel WAP and SMS Gateway

Kannel WAP and SMS Gateway

Kannel is designed to link HTTP based services to various SMS service centers using little known protocols, and supports most if not all GSM phones for exchanging SMS messages.

4. Kalkun – SMS Gateway and Management

Kalkun is a free, open source, pluggable, secure, and simple web-based SMS management system. It employs gammu-smsd as an SMS gateway engine to send and retrieve messages from your phone/modem. You can use the default gateway (gammu) or configure your own gateways.

Kalkun SMS Gateway and Management

Kalkun SMS Gateway and Management

It has multi-user support, allows you to setup multiple modems, has a spam filter, supports various SMS templates. Kalkun also helps you to exchange SMS between your custom applications using it’s simple API, and more.

That’s all! If you know of any other open source SMS gateway solutions missing in this list, but deserve to be here, let us know via the feedback form below, we will be grateful.

Source

Install LibreOffice 6.0.4 in RHEL/CentOS/Fedora and Debian/Ubuntu/Linux Mint

LibreOffice is an open source and much powerful personal productivity office suit for LinuxWindows & Mac, that provides feature rich functions for word document, data processing, spreadsheets, presentation, drawing, Calc, Math and much more. LibreOffice has large number of satisfied users across the globe with almost 120million downloads as of now. It supports more than 110 languages and runs on all major operating systems.

The Document Foundation team proudly announced the first major release of LibreOffice 6.0.4 on May 09, 2018, is now available for all major platforms including LinuxWindows and Mac OS.

This new update features a large number of exciting new features, performance and improvements and is targeted to all kinds of users, but especially appealing for enterprise, early adopters and power users.

There are many other changes and features included in the newest LibreOffice 6.0.4 – for a complete list of new features, see the release announcement page.

LibreOffice 6.0.4 Requirements

  1. Kernel 2.6.18 or higher version
  2. glibc2 version 2.5 or higher version
  3. gtk version 2.10.4 or higher version
  4. Minimum 256MB and recommended 512MB RAM
  5. 1.55GB available Hard disk space
  6. Desktop (Gnome or KDE)

Install LibreOffice 6.0.4 on Linux

The installation instructions provided here are for LibreOffice 6.0.4 using language US English on a 64-Bitsystem. For 32-Bit systems, there will be minor differences in directory names, but the installation process is same and hope the installation instructions provide here are not so difficult.

Step 1: Downloading LibreOffice 6.0.4

Select the package for download based on your system bit (i.e. for a 32-bit or 64-bit) using Wget command.

For RHEL/CentOS/Fedora
# cd /tmp

---------------------------- On 32-bit Systems ---------------------------- 
# wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/rpm/x86/LibreOffice_6.0.4_Linux_x86_rpm.tar.gz


---------------------------- On 64-bit Systems ---------------------------- 
# wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/rpm/x86_64/LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz
Download LibreOffice 6.0.4 on CentOS 7
[root@TecMint ~]# wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/rpm/x86_64/LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz
--2018-05-09 01:11:08--  http://download.documentfoundation.org/libreoffice/stable/6.0.4/rpm/x86_64/LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz
Resolving download.documentfoundation.org (download.documentfoundation.org)... 89.238.68.185, 2a00:1828:a012:185::1
Connecting to download.documentfoundation.org (download.documentfoundation.org)|89.238.68.185|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://ftp.gwdg.de/pub/tdf/libreoffice/stable/6.0.4/rpm/x86_64/LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz [following]
--2018-05-09 01:11:09--  https://ftp.gwdg.de/pub/tdf/libreoffice/stable/6.0.4/rpm/x86_64/LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz
Resolving ftp.gwdg.de (ftp.gwdg.de)... 134.76.12.6, 2001:638:60f:110::1:2
Connecting to ftp.gwdg.de (ftp.gwdg.de)|134.76.12.6|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 213537364 (204M) [application/octet-stream]
Saving to: ‘LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz’

100%[=================================================================================================================================>] 21,35,37,364  310KB/s   in 15m 35s

2018-02-01 01:26:46 (223 KB/s) - ‘LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz’ saved [213537364/213537364]
For Debian/Ubuntu/LinuxMint
---------------------------- On 32-bit Systems ---------------------------- 
$ wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/deb/x86/LibreOffice_6.0.4_Linux_x86_deb.tar.gz

---------------------------- On 64-bit Systems ---------------------------- 
$ wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/deb/x86_64/LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz
Download LibreOffice 6.0.4 on Ubuntu
tecmint  ~  wget http://download.documentfoundation.org/libreoffice/stable/6.0.4/deb/x86_64/LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz
--2018-05-09 11:57:23--  http://download.documentfoundation.org/libreoffice/stable/6.0.4/deb/x86_64/LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz
Resolving download.documentfoundation.org (download.documentfoundation.org)... 89.238.68.185
Connecting to download.documentfoundation.org (download.documentfoundation.org)|89.238.68.185|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://ftp.gwdg.de/pub/tdf/libreoffice/stable/6.0.4/deb/x86_64/LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz [following]
--2018-05-09 11:57:23--  https://ftp.gwdg.de/pub/tdf/libreoffice/stable/6.0.4/deb/x86_64/LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz
Resolving ftp.gwdg.de (ftp.gwdg.de)... 134.76.12.6
Connecting to ftp.gwdg.de (ftp.gwdg.de)|134.76.12.6|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 213964181 (204M) [application/octet-stream]
Saving to: ‘LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz’

LibreOffice_6.0.0_Linux_x86-64_deb.tar.gz  100%[========================================================================================>] 204.05M   319KB/s    in 15m 17s 

2018-02-01 12:12:41 (228 KB/s) - ‘LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz’ saved [213964181/213964181]

Step 2: Removing Old LibreOffice or OpenOffice Versions

If any previously installed LibreOffice or OpenOffice versions you have, remove it using following command.

# yum remove openoffice* libreoffice*			[on RedHat based Systems]

Remove Old LibreOffice 4 on CentOS

Remove Old LibreOffice 4 on CentOS

$ sudo apt-get remove openoffice* libreoffice*		[On Debian based Systems]

Remove LibreOffice 4 on Ubuntu

Remove LibreOffice 4 on Ubuntu

Step 3: Extracting LibreOffice 6.0.4 Package

After downloading the LibreOffice 6.0.4 package, use tar command to extract it under /tmp directory or in a directory of your choice.

On RHEL/CentOS/Fedora
# tar -xvf LibreOffice_6.0.4_Linux_x86_rpm.tar.gz		[On 32-Bit Systems]	
# tar -xvf LibreOffice_6.0.4_Linux_x86-64_rpm.tar.gz	        [On 64-Bit Systems]	
On Debian/Ubuntu/Linux Mint
$ tar -xvf LibreOffice_6.0.4_Linux_x86_deb.tar.gz		[On 32-Bit Systems]	
$ tar -xvf LibreOffice_6.0.4_Linux_x86-64_deb.tar.gz		[On 64-Bit Systems]	

Step 4: Installing LibreOffice 6.0.4 Package

After extracting the package, you will get a directory and under this there will be a sub-directory called RPMS. Now, run the following command to install it.

On RHEL/CentOS/Fedora
## For 32 Bit OS ##
# cd /tmp/LibreOffice_6.0.4.2_Linux_x86_rpm/RPMS/
# yum localinstall *.rpm
OR
# dnf install *.rpm    [On Fedora 23+ versions]

## For 64 Bit OS ##
# cd /tmp/LibreOffice_6.0.4.2_Linux_x86-64_rpm/RPMS/
# yum localinstall *.rpm
OR
# dnf install *.rpm    [On Fedora 23+ versions]
Installing LibreOffice 6.0.4 on CentOS 7
[root@localhost RPMS]# yum localinstall *.rpm
Dependencies Resolved

============================================================================================================================================================================
 Package                                                  Arch          Version            Repository                                                                  Size
============================================================================================================================================================================
Installing:
 libobasis6.0-base                                        x86_64        6.0.4.2-2          /libobasis6.0-base-6.0.4.2-2.x86_64                                        7.6 M
 libobasis6.0-calc                                        x86_64        6.0.4.2-2          /libobasis6.0-calc-6.0.4.2-2.x86_64                                         29 M
 libobasis6.0-core                                        x86_64        6.0.4.2-2          /libobasis6.0-core-6.0.4.2-2.x86_64                                        267 M
 libobasis6.0-draw                                        x86_64        6.0.4.2-2          /libobasis6.0-draw-6.0.4.2-2.x86_64                                         48 k
 libobasis6.0-en-US                                       x86_64        6.0.4.2-2          /libobasis6.0-en-US-6.0.4.2-2.x86_64                                       164 k
 libobasis6.0-extension-beanshell-script-provider         x86_64        6.0.4.2-2          /libobasis6.0-extension-beanshell-script-provider-6.0.4.2-2.x86_64         398 k
 libobasis6.0-extension-javascript-script-provider        x86_64        6.0.4.2-2          /libobasis6.0-extension-javascript-script-provider-6.0.4.2-2.x86_64        626 k
 libobasis6.0-extension-mediawiki-publisher               x86_64        6.0.4.2-2          /libobasis6.0-extension-mediawiki-publisher-6.0.4.2-2.x86_64               4.3 M
 libobasis6.0-extension-nlpsolver                         x86_64        6.0.4.2-2          /libobasis6.0-extension-nlpsolver-6.0.4.2-2.x86_64                         2.1 M
 libobasis6.0-extension-pdf-import                        x86_64        6.0.4.2-2          /libobasis6.0-extension-pdf-import-6.0.4.2-2.x86_64                        2.2 M
 libobasis6.0-extension-report-builder                    x86_64        6.0.4.2-2          /libobasis6.0-extension-report-builder-6.0.4.2-2.x86_64                    6.0 M
 libobasis6.0-firebird                                    x86_64        6.0.4.2-2          /libobasis6.0-firebird-6.0.4.2-2.x86_64                                     11 M
 libobasis6.0-gnome-integration                           x86_64        6.0.4.2-2          /libobasis6.0-gnome-integration-6.0.4.2-2.x86_64                           1.2 M
 libobasis6.0-graphicfilter                               x86_64        6.0.4.2-2          /libobasis6.0-graphicfilter-6.0.4.2-2.x86_64                               4.2 M
 libobasis6.0-images                                      x86_64        6.0.4.2-2          /libobasis6.0-images-6.0.4.2-2.x86_64                                       18 M
 libobasis6.0-impress                                     x86_64        6.0.4.2-2          /libobasis6.0-impress-6.0.4.2-2.x86_64                                     2.2 M
 libobasis6.0-kde-integration                             x86_64        6.0.4.2-2          /libobasis6.0-kde-integration-6.0.4.2-2.x86_64                             238 k
 libobasis6.0-librelogo                                   x86_64        6.0.4.2-2          /libobasis6.0-librelogo-6.0.4.2-2.x86_64                                   741 k
 libobasis6.0-math                                        x86_64        6.0.4.2-2          /libobasis6.0-math-6.0.4.2-2.x86_64                                        1.6 M
 libobasis6.0-ogltrans                                    x86_64        6.0.4.2-2          /libobasis6.0-ogltrans-6.0.4.2-2.x86_64                                    298 k
 libobasis6.0-onlineupdate                                x86_64        6.0.4.2-2          /libobasis6.0-onlineupdate-6.0.4.2-2.x86_64                                433 k
 libobasis6.0-ooofonts                                    x86_64        6.0.4.2-2          /libobasis6.0-ooofonts-6.0.4.2-2.x86_64                                     67 M
 libobasis6.0-ooolinguistic                               x86_64        6.0.4.2-2          /libobasis6.0-ooolinguistic-6.0.4.2-2.x86_64                               1.4 k
 libobasis6.0-postgresql-sdbc                             x86_64        6.0.4.2-2          /libobasis6.0-postgresql-sdbc-6.0.4.2-2.x86_64                             3.5 M
 libobasis6.0-python-script-provider                      x86_64        6.0.4.2-2          /libobasis6.0-python-script-provider-6.0.4.2-2.x86_64                       41 k
 libobasis6.0-pyuno                                       x86_64        6.0.4.2-2          /libobasis6.0-pyuno-6.0.4.2-2.x86_64                                        22 M
 libobasis6.0-writer                                      x86_64        6.0.4.2-2          /libobasis6.0-writer-6.0.4.2-2.x86_64                                       16 M
 libobasis6.0-xsltfilter                                  x86_64        6.0.4.2-2          /libobasis6.0-xsltfilter-6.0.4.2-2.x86_64                                  4.3 M
 libreoffice6.0                                           x86_64        6.0.4.2-2          /libreoffice6.0-6.0.4.2-2.x86_64                                           4.5 M
 libreoffice6.0-base                                      x86_64        6.0.4.2-2          /libreoffice6.0-base-6.0.4.2-2.x86_64                                       63  
 libreoffice6.0-calc                                      x86_64        6.0.4.2-2          /libreoffice6.0-calc-6.0.4.2-2.x86_64                                       63  
 libreoffice6.0-dict-en                                   x86_64        6.0.4.2-2          /libreoffice6.0-dict-en-6.0.4.2-2.x86_64                                    24 M
 libreoffice6.0-dict-es                                   x86_64        6.0.4.2-2          /libreoffice6.0-dict-es-6.0.4.2-2.x86_64                                   4.1 M
 libreoffice6.0-dict-fr                                   x86_64        6.0.4.2-2          /libreoffice6.0-dict-fr-6.0.4.2-2.x86_64                                   6.4 M
 libreoffice6.0-draw                                      x86_64        6.0.4.2-2          /libreoffice6.0-draw-6.0.4.2-2.x86_64                                       63  
 libreoffice6.0-en-US                                     x86_64        6.0.4.2-2          /libreoffice6.0-en-US-6.0.4.2-2.x86_64                                      16 k
 libreoffice6.0-freedesktop-menus                         noarch        6.0.4.2-2            /libreoffice6.0-freedesktop-menus-6.0.4.2-2.noarch                            30 M
 libreoffice6.0-impress                                   x86_64        6.0.4.2-2          /libreoffice6.0-impress-6.0.4.2-2.x86_64                                    66  
 libreoffice6.0-math                                      x86_64        6.0.4.2-2          /libreoffice6.0-math-6.0.4.2-2.x86_64                                       63  
 libreoffice6.0-ure                                       x86_64        6.0.4.2-2          /libreoffice6.0-ure-6.0.4.2-2.x86_64                                        38 M
 libreoffice6.0-writer                                    x86_64        6.0.4.2-2          /libreoffice6.0-writer-6.0.4.2-2.x86_64                                     65  

Transaction Summary
============================================================================================================================================================================
Install  41 Packages

Total size: 579 M
Installed size: 579 M
Is this ok [y/d/N]: y
On Debian/Ubuntu/Linux Mint
## For 32 Bit OS ##
$ cd /tmp/LibreOffice_6.0.4.2_Linux_x86_deb/DEBS/
$ sudo dpkg -i *.deb

## For 64 Bit OS ##
$ cd /tmp/LibreOffice_6.0.4.2_Linux_x86-64_deb/DEBS/
$ sudo dpkg -i *.deb
Installing LibreOffice 6.0.4 on Ubuntu
tecmint@TecMint /tmp/LibreOffice_6.0.4.2_Linux_x86-64_deb/DEBS $ sudo dpkg -i *.deb
Selecting previously unselected package libobasis6.0-base.
(Reading database ... 263169 files and directories currently installed.)
Preparing to unpack libobasis6.0-base_6.0.4.2-2_amd64.deb ...
Unpacking libobasis6.0-base (6.0.4.2-2) ...
Selecting previously unselected package libobasis6.0-calc.
Preparing to unpack libobasis6.0-calc_6.0.4.2-2_amd64.deb ...
Unpacking libobasis6.0-calc (6.0.4.2-2) ...
Selecting previously unselected package libobasis6.0-core.
Preparing to unpack libobasis6.0-core_6.0.4.2-2_amd64.deb ...
Unpacking libobasis6.0-core (6.0.4.2-2) ...
...

Step 5: Starting LibreOffice 6.0.4

Once the installation process completes you will have LibreOffice icons in your desktop under Applications –> Office menu or start the application by executing the following command on the terminal.

# libreoffice6.0

Step 6: Screenshot of LibreOffice 6.0.4

Please see the attached screenshot of LibreOffice 6.0.4 application under my CentOS 7.0.

LibreOffice 6.0.4 Running on CentOS 7

LibreOffice 6.0.4 Running on CentOS 7

Step 7: Installing a Language Pack

If you would like to install LibreOffice in your preferred language, you should select your language pack for installation. The installation instructions can be fount at Language Pack section.

Source

WP2Social Auto Publish Powered By : XYZScripts.com