How To Install KDE Plasma on Ubuntu 17.10

Install KDE Plasma on Ubuntu 17

Plasma is the KDE workspace. Actually it is a technology that can adapt to many types of devices. Currently there are two varieties of Plasma: The Plasma Desktop environment which is the focus of the majority of our pages and Plasma Mobile, the new cool environment for pads and smartphones.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation KDE Plasma desktop environment on an Ubuntu Ubuntu 17.10 Artful Aardvark server.

Install KDE Plasma on Ubuntu 17.10 Artful Aardvark

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing KDE Plasma on Ubuntu 17.10.

First, you need to add backports PPA to your Continue reading “How To Install KDE Plasma on Ubuntu 17.10”

How To Install GoAccess on Ubuntu 16.04 LTS

How To Install GoAccess on Ubuntu 16.04 LTS

GoAccess was designed to be a fast, terminal-based log analyzer. Its core idea is to quickly analyze and view web server statistics in real time without needing to use your browser (great if you want to do a quick analysis of your access log via SSH, or if you simply love working in the terminal).

Key Features — See Full List

  • Fast, real-time, millisecond/second updates, written in C
  • Only ncurses as a dependency
  • Nearly all web log formats (Apache, Nginx, Amazon S3, Elastic Load Balancing, CloudFront, etc)
  • Simply set the log format and run it against your log
  • Beautiful terminal and bootstrap dashboards (Tailor GoAccess to suit your own color taste/schemes)
  • and of course, Valgrind tested.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation GoAccess real time web log analyzer on a Ubuntu 16.04 (Xenial Xerus) server.

Install GoAccess on Ubuntu 16.04 LTS

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing dependency packages.

Install the ncurses and gcc, run following command:

apt-get install libncursesw5-dev libglib2.0-dev libgeoip-dev libtokyocabinet-dev

Step 2. Installing GoAccess.

Run the following command to install GoAccess software:

wget http://tar.goaccess.io/goaccess-1.2.tar.gz
tar xvzf goaccess-1.2.tar.gz
cd goaccess-1.2
./configure --enable-utf8 --enable-geoip=legacy
make && make install

Create a soft link of goaccess in the /usr/bin directory by running:

ln -s /usr/local/bin/goaccess /usr/bin/goaccess

Step 3. Using GoAccess.

First, install Apache as our web server:

apt-get install apache2

After the installation process is finished, execute the following commands to start your Apache service:

systemctl start apache2
systemctl enable apache2

Allow the required HTTP port through the system firewall:

firewall-cmd --add-service=http --permanent
firewall-cmd --reload

For example, using the following command will create an analyzed HTML file from the Apache access log and place it in Apache’s default document root:

goaccess /var/log/apache2/access.log --log-format=COMBINED -a -o /var/www/html/report.html

Now you can open your browser, Enter your IP address or your Domain name and add “/report.html” in the end to see your HTML output:

goaccess dashboard
Congratulation’s! You have successfully installed GoAccess. Thanks for using this tutorial for installing GoAccess real time web log analyzer on Ubuntu 16.04 LTS (Xenial Xerus) system. For additional help or useful information, we recommend you to check the official GoAccess web site.

How to Speed Up WordPress Using Redis Caching

How to Speed Up WordPress Using Redis Caching

WordPress is software designed for everyone, emphasizing accessibility, performance, security, and ease of use. WP believe great software should work with minimum set up, so you can focus on sharing your story, product, or services freely. The basic WordPress software is simple and predictable so you can easily get started. It also offers powerful features for growth and success.

But in non-geek speak, it’s probably the easiest and most powerful blogging and website content management system (or CMS) in existence today.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation WordPress content management systems on a Ubuntu 16.04 server.

Speed Up WordPress Using Redis Caching

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing WordPress

If you do not have WordPress installed, you can follow WP Installation guide here.

Step 3. Installing Redis.

In order to use Redis with WordPress, two packages need to be installed: redis-server and php-redis. The redis-server package provides Redis itself, while the php-redis package provides a PHP extension for PHP applications like WordPress to communicate with Redis:

apt-get install redis-server
apt-get install php-redis

Start and enable Redis on system boot:

systemctl start redis.service
systemctl enable redis.service

Step 4. Install Redis Caching Plugin in WordPress.

After installing Redis and the PHP Redis client extension, log in to your WordPress Dashboard and select Add New from the Plugins menu.

Then, search for “Redis Object Cache” and click Install Now on the matching result.

redis-object-cache
Next, navigate to Settins > Redis and click on Enable Object Cache to enable the object caching in WordPress. The default configuration should work out of the box sonce the default Redis listening address is 127.0.0.1 and the default listening port is 6379.

Step 5. Verify WordPress caching.

To check whether the WordPress caching works OK with Redis you can connect to your server via SSH and run the following command:

redis-cli monitor

When you run this command, you will see the real-time output of Redis serving cached queries. If you don’t see anything, visit your website and reload a page.

Congratulation’s! You have successfully installed WordPress with Redis Caching.

How To Install Apache Maven on Ubuntu 16.04 LTS

Install Apache Maven on Ubuntu 16

Apache Maven is a free and open source project management tool used for Java projects. You can easily handle a project’s build, reporting, and Documentation from a central piece of advice using Apache Maven. Apache Maven provides a complete framework to automate the job’s Build infrastructure.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Apache Maven open source data visualization and monitoring suite on a Ubuntu 16.04 (Xenial Xerus) server.

Install Apache Maven on Ubuntu 16.04 LTS

Step 1. First make sure that all your system packages are up-to-date by running these following apt-get commands in the terminal.

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing Java.

Apache Maven requires Java to be installed on your server. By default, Java is not available in Ubuntu’s repository. Add the Oracle Java PPA to Apt with the following command:

add-apt-repository ppa:webupd8team/java
apt-get update -y
apt-get install oracle-java8-installer

Verify the Java version by running the following command:

java -version

Step 3. Installing Apache Maven.

First thing to do is to go to Apache Maven’s download page and download the latest stable version of Apache Maven, At the moment of writing this article it is version 3.5.2:

wget http://www-eu.apache.org/dist/maven/maven-3/3.5.2/binaries/apache-maven-3.5.2-bin.tar.gz

Now extract downloaded archive using following command:

tar xzf apache-maven-3.5.2-bin.tar.gz
ln -s apache-maven-3.5.2 apache-maven

Step 4. Setup Environment Variables.

Now set the environments variables by creating new file /etc/profile.d/maven.sh:

nano /etc/profile.d/apache-maven.sh

Add following content:

export JAVA_HOME=/usr/lib/jvm/java-8-oracle
export M2_HOME=/usr/local/apache-maven
export MAVEN_HOME=/usr/local/apache-maven
export PATH=${M2_HOME}/bin:${PATH}

Now load the environment variables in current shell using following command:

source /etc/profile.d/apache-maven.sh

Step 5. Verify Installation.
Once everything has been successfully configured, check the version of the Apache Maven:

### mvn -version

Apache Maven 3.5.2 (138edd61fd100ec658bfa2d307c43b76940a5d7d; 2017-10-18T13:28:13+05:30)
Maven home: /usr/local/apache-maven
Java version: 1.8.0_144, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-oracle/jre
Default locale: en_IN, platform encoding: UTF-8
OS name: "linux", version: "4.4.0-46-generic", arch: "amd64", family: "unix"

Congratulation’s! You have successfully installed Apache Maven. Thanks for using this tutorial for installing Apache Maven on Ubuntu 16.04 LTS (Xenial Xerus) system. For additional help or useful information, we recommend you to check the official Apache Maven web site.

How To Install Grafana on Ubuntu 16.04 LTS

Install Grafana on Ubuntu 16

Grafana is an open source data visualization and tracking suite. It offers support for Graphite, Elasticsearch, Included, Prometheus, and a lot more databases. The application gives a beautiful dashboard and metric analytics, with capability to control and create your own dashboard to your own apps or infrastructure performance monitoring.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Grafana open source data visualization and monitoring suite on a Ubuntu 16.04 (Xenial Xerus) server.

Install Grafana on Ubuntu 16.04 LTS

Step 1. First make sure that all your system packages are up-to-date by running these following apt-get commands in the terminal.

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing Grafana.

First, Add new Grafana repository to the ‘sources.list.d’ directory and then add the repository gpg key using the following commands:

echo 'deb https://packagecloud.io/grafana/stable/debian/ jessie main' > /etc/apt/sources.list.d/grafana.list
curl https://packagecloud.io/gpg.key | sudo apt-key add -

Run the following command to install Grafana software:

apt-get update
apt-get install grafana

After the installation process is finished, execute the following commands to start your Grafana service:

systemctl daemon-reload
systemctl start grafana-server
systemctl enable grafana-server

Step 3. Accessing Grafana.

Grafana will be available on HTTP port 3000 by default. Open your favorite browser and navigate to http://mydomain.com:3000 and complete the required the steps to finish the installation. If you are using a firewall, please open port 3000 to enable access to the control panel.

Congratulation’s! You have successfully installed Grafana. Thanks for using this tutorial for installing Grafana analytics and monitoring on Ubuntu 16.04 LTS (Xenial Xerus) system. For additional help or useful information, we recommend you to check the official Grafana web site.

How To Install Redmine on Ubuntu 16.04 LTS

Install Redmine on Ubuntu 16

Redmine is a project management web app that allows users to manage projects flexibly while offering robust monitoring tools and a broad library of plug-ins. This free and open source solution offers a substitute for paid job management tools and contains support for wikis, forums, calendars, and information visualization programs.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Redmine project management web app on a Ubuntu 16.04 (Xenial Xerus) server.

Install Redmine on Ubuntu 16.04 LTS

Step 1. First make sure that all your system packages are up-to-date by running these following apt-get commands in the terminal.

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing MySQL server.

MySQL needs to be configured so that Redmine can store data, so we will install MySQL server:

apt-get install mysql-server mysql-client

By default, MySQL is not hardened. You can secure MySQL using the mysql_secure_installation script. You should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MySQL.

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MySQL console and create a database for the Redmine. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MySQL root password and hit Enter. Once you are logged in to your database server you need to create a database for Redmine installation:

CREATE DATABASE redmin
GRANT ALL PRIVILEGES ON redmine.* TO 'redmine'@'localhost' IDENTIFIED BY 'PASSWORD';
FLUSH PRIVILEGES;
\q

Step 3. Installing Ruby and Ruby Version Manager (RVM).

Install the latest version of Ruby with the following command:

gpg --keyserver hkp://keys.gnupg.net --recv-keys D39DC0E3
curl -L https://get.rvm.io | bash -s stable --ruby=2.4.1

Run the following commands to load RVM:

source /usr/local/rvm/scripts/rvm
echo '[[ -s "/usr/local/rvm/scripts/rvm" ]] && source "/usr/local/rvm/scripts/rvm"' >> ~/.bashrc

Step 4. Installing Passenger and Nginx.

Passenger is an application server that runs your web application then communicates with the web server. We will install it and integrate it with Nginx:

gem install passenger --no-ri --no-rdoc
passenger-install-nginx-module

You will be prompted to select a language that will be supported, select Ruby. On the next step select the ‘Yes: download, compile and install Nginx for me. (recommended)’ option.

Next, open the Nginx configuration file:

nano /opt/nginx/conf/nginx.conf

Add following content:

server {
 listen 80;
 server_name yourdomain.com;

root /var/www/html/redmine/public;
 passenger_enabled on;
 client_max_body_size 10m; # Max attachemnt size

# redirect server error pages to the static page /50x.html
 #
 error_page 500 502 503 504 /50x.html;
 location = /50x.html {
 root html;
 }
 }

Restart the web server for the changes to take effect:

systemctl restart nginx
systemctl enable nginx

Step 5. Installing Redmine.

First, download the latest version of Redmine, at the moment of writing this article it is version 3.4:

cd /var/www/html
svn co http://svn.redmine.org/redmine/branches/3.4-stable redmine

Next, change the current working directory and the example configuration files:

cd redmine
cp config/configuration.yml.example config/configuration.yml
cp config/database.yml.example config/database.yml

Make the following changes to the database.yml file:

nano config/database.yml

Add following content:
production:

 adapter: mysql2
 database: redmine
 host: localhost
 username: redmine
 password: PASSWORD
 encoding: utf8

Install the Ruby dependencies and migrate the database:

gem install bundler --no-ri --no-rdoc
bundle install
bundle exec rake db:migrate
bundle exec rake redmine:plugins

Generate the secret token using the following command:

bundle exec rake generate_secret_token
RAILS_ENV=production bundle exec rake db:migrate
RAILS_ENV=production bundle exec rake redmine:load_default_data

Finally, Restart the web server for the changes to take effect:

systemctl restart nginx

Step 6. Accessing Redmine.

Redmine will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://mydomain.com and complete the required the steps to finish the installation using the default credentials (admin/admin). If you are using a firewall, please open port 80 to enable access to the control panel.

Congratulation’s! You have successfully installed Redmine. Thanks for using this tutorial for installing Redmine project management web app on Ubuntu 16.04 LTS (Xenial Xerus) system. For additional help or useful information, we recommend you to check the official Redmine web site.

How To Install Vector Monitoring on Ubuntu 16.04 LTS

Install Vector Monitoring on Ubuntu 16

A vector is an open source on-host performance monitoring framework which exposes hand chosen high resolution program and program metrics to every engineer’s browser. Possessing the correct metrics available on-demand and in a top resolution is key to know how a system behaves and correctly troubleshoot performance problems.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Vector Monitoring framework on a Ubuntu 16.04 (Xenial Xerus) server.

Install Vector Monitoring on Ubuntu 16.04 LTS

Step 1. First make sure that all your system packages are up-to-date by running these following apt-get commands in the terminal.

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing Performance Co-Pilot (PCP).

Before installing Vector you will first have to install Performance Co-Pilot (PCP). It’s an open source toolkit designed for monitoring and managing system-level performance:

echo "deb https://dl.bintray.com/netflixoss/ubuntu {codename} main" | sudo tee -a /etc/apt/sources.list

Install PCP using following command:

apt-get update
apt-get install pcp pcp-webapi

Once installed, restart PCP daemons and setup start on boot:

systemctl enable pmcd.service
systemctl enable pmwebd.service
systemctl enable pmlogger.service

Step 3. Installing Vector Monitoring Framework
First, download Vector archive from netflix oss repository, at the time of this writing the latest version of Vector is 1.0.3:

wget https://bintray.com/artifact/download/netflixoss/downloads/1.0.3/vector.tar.gz

Create a directory to extract vector, we need to create this since vector build is not placed in a directory:

mdkir vector
tar xzf vector.tar.gz -C vector

Step 4. Accessing Vector Monitoring.

Vector Monitoring Framework will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/vector or http://server-ip/vector and complete the required the steps to finish the installation.

vector-monitoring

Enter hostname or ip address of the server that you want to monitor. If you change pmwebd port you need to specify hostname:port or ipaddress:port. The performance graphs will start showing the current condition of your system.

Congratulation’s! You have successfully installed Vector. Thanks for using this tutorial for installing Vector Monitoring framework on Ubuntu 16.04 LTS (Xenial Xerus) system. For additional help or useful information, we recommend you to check the official Vector Monitoring web site.