Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: Cannot modify header information - headers already sent by (output started at /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php:783) in /home/akl1986/public_html/support/wp-includes/feed-rss2.php on line 8
Ubuntu – AKLWEB HOST LLC Support Center https://support.aklwebhost.com Tue, 30 May 2023 13:23:25 +0000 en-US hourly 1 https://wordpress.org/?v=6.4.4 Install an FTP Server With ProFTPd on Debian or Ubuntu https://support.aklwebhost.com/knowledgebase/install-an-ftp-server-with-proftpd-on-debian-or-ubuntu/ https://support.aklwebhost.com/knowledgebase/install-an-ftp-server-with-proftpd-on-debian-or-ubuntu/#respond Tue, 30 May 2023 13:23:23 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3768 In this guide, we will see how to configure an FTP server (ProFTPd) to transfer files between your PC and your server.

Prerequisites

  • A newly deployed AKLWEB HOST Debian or Ubuntu server instance.
  • Sudo user.

Installation

Update the system.

sudo apt-get update

sudo apt-get dist-upgrade

Install proftpd.

sudo apt-get install proftpd

During installation, you will be asked if you want to install in inetd or standalone mode. Choose the standalone mode.

Configuration

Open the Proftpd configuration file.

sudo nano /etc/proftpd/proftpd.conf

The file will resemble the following text.

#

# /etc/proftpd/proftpd.conf -- This is a basic ProFTPD configuration file.

# To really apply changes, reload proftpd after modifications, if

# it runs in daemon mode. It is not required in inetd/xinetd mode.

#



# Includes DSO modules

Include /etc/proftpd/modules.conf



# Set off to disable IPv6 support which is annoying on IPv4 only boxes.

UseIPv6                         on

# If set on you can experience a longer connection delay in many cases.

IdentLookups                    off



ServerName                      "Debian"

ServerType                      standalone

DeferWelcome                    off



MultilineRFC2228                on

DefaultServer                   on

ShowSymlinks                    on



TimeoutNoTransfer               600

TimeoutStalled                  600

TimeoutIdle                     1200



DisplayLogin                    welcome.msg

DisplayChdir                    .message true

ListOptions                     "-l"



DenyFilter                      \*.*/



# Use this to jail all users in their homes

# DefaultRoot                     ~



# Users require a valid shell listed in /etc/shells to login.

# Use this directive to release that constrain.

RequireValidShell               off



# Port 21 is the standard FTP port.

Port                            21

...

Main configuration directives

  • ServerName: Specifies the name of the FTP server. This name will be displayed when clients connect to the server.
  • TimeoutIdle: The time, in seconds, after which a client is automatically disconnected if it is no longer active on the FTP server.
  • DefaultRoot: Controls the default root directory assigned to a user upon login.
  • Port: The connection port to the FTP server. Almost all of the time this port is 21 and you should not have to change it unless you are blocked by a firewall.
  • PassivePorts: Restricts the range of ports from which the server will select when sent the PASV command from a client.
  • MaxInstances: The maximum number of simultaneous connections you want to allow on your FTP server.

Now, we have to activate the DefaultRoot option. to do this, find the DefaultRoot commented line and uncomment it.

DefaultRoot                     ~

The value ~ means that the user will be limited to the personal folder (e.g /home/user12).

Note: By default, someone who connects to the FTP server can access all of the server folders, so it’s recommended to enable the option DefaultRoot.

Change the ServerName.

ServerName : the name of your FTP server

Find and uncomment the following lines (removing the # at the beginning of each line) to allow anonymous connections to your server.

# A basic anonymous configuration, no upload directories.



 <Anonymous ~ftp>

   User                         ftp

   Group                        nogroup

   # We want clients to be able to login with "anonymous" as well as "ftp"

   UserAlias                    anonymous ftp

   # Cosmetic changes, all files belongs to ftp user

   DirFakeUser  on ftp

   DirFakeGroup on ftp



   RequireValidShell            off



   # Limit the maximum number of anonymous logins

   MaxClients                   10



   # We want 'welcome.msg' displayed at login, and '.message' displayed

   # in each newly chdired directory.

   DisplayLogin                 welcome.msg

   DisplayFirstChdir            .message



   # Limit WRITE everywhere in the anonymous chroot

   <Directory *>

     <Limit WRITE>

       DenyAll

     </Limit>

   </Directory>

 </Anonymous>

Note: If you enable anonymous connections on your FTP server, any user can connect to it. They will have access to the /home/ftp directory and will be able to read and download files, but not modify or add files.

You can forbid the root user from accessing FTP by adding the following line.

RootLogin off

After the configuration has been changed, restart the server.

sudo service proftpd restart

Note: If an error line is displayed as “unable to resolve host”, be aware that it does not matter and you can ignore it.

Add an FTP user

Add a user, for example, “myuser“.

useradd --shell /bin/false myuser

Create the home directory of our user “myuser“.

mkdir /home/myuser

Change the ownership of that directory to the user and group “myuser“.

chown myuser:myuser /home/myuser/

Set a password for the user “myuser“.

passwd myuser
]]>
https://support.aklwebhost.com/knowledgebase/install-an-ftp-server-with-proftpd-on-debian-or-ubuntu/feed/ 0
Install Ruby with RVM on Ubuntu 18.04 and 19.10 https://support.aklwebhost.com/knowledgebase/install-ruby-with-rvm-on-ubuntu-18-04-and-19-10/ https://support.aklwebhost.com/knowledgebase/install-ruby-with-rvm-on-ubuntu-18-04-and-19-10/#respond Tue, 30 May 2023 13:20:07 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3764 Introduction

This tutorial explains how to install Ruby, using RVM, on Ubuntu 18.04 and Ubuntu 19.10. Ruby is a popular development language. RVM manages multiple Ruby environments and allows you to switch between them.

Requirements

  • A AKLWEB HOST instance running Ubuntu 18.04 or 19.10.

RVM Installation

Install GPG

$ sudo apt install gnupg

Import RVM Signing Key

Import the RVM code-signing keys. The command below is an example, please verify the keys at https://rvm.io/rvm/security.

$ gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB

Step 2: Download and install RVM

Go to the /tmp folder

$ cd /tmp

Download a stable version of the RVM script.

$ sudo apt-get update && apt-get install curl && curl -sSL https://get.rvm.io | bash -s stable

Add your user account to the rvm group.

$ sudo usermod -a -G rvm username

Log out of your terminal, then log back in again. Group memberships are only evaluated at login time.

Check the RVM version.

$ rvm -v

rvm 1.29.9 (latest) by Michal Papis, Piotr Kuczynski, Wayne E. Seguin [https://rvm.io]

Manage your Ruby Environment

Example: List the known Ruby versions

$ rvm list known

Example: Install a specific version of Ruby.

$ rvm install ruby-2.7.0

$ rvm --default use ruby-2.7.0

Example: Remove a specific version of Ruby.

$ rvm remove ruby-2.7.0

Example: Check the Ruby versions installed with RVM.

$ rvm list

Example: Check the Ruby version.

$ ruby -v

Example: Remove a specific version of Ruby.

$ rvm remove ruby-2.7.0

Uninstall RVM

  1. Remove RVM with:$ sudo rvm implode $ sudo rm -rf ~/.rvm $ sudo rm -rf /etc/rvmrc $ sudo rm -rf ~/.rvmrc $ sudo groupdel rvm
  2. Delete RVM source lines from all .bashrc.bash_profile.profile, and .zshrc files.
  3. Reboot

Conclusion

RVM is a simple way to manage multiple Ruby environments. For more information, see the RVM homepage.

]]>
https://support.aklwebhost.com/knowledgebase/install-ruby-with-rvm-on-ubuntu-18-04-and-19-10/feed/ 0
Install Apache Maven on Ubuntu 18.04 https://support.aklwebhost.com/knowledgebase/install-apache-maven-on-ubuntu-18-04/ https://support.aklwebhost.com/knowledgebase/install-apache-maven-on-ubuntu-18-04/#respond Tue, 30 May 2023 13:07:02 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3752 Introduction

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

In this tutorial, you will learn how to install Apache Maven on Ubuntu 18.04.

Prerequisites

  • A newly deployed AKLWEB HOST Ubuntu 18.04 server.
  • A non-root user with sudo privileges created on your server.

Update your server

First, update your system to the latest stable version:

sudo apt-get update -y

sudo apt-get upgrade -y

Install Java

Maven 3.3 or greater requires JDK 1.7 or above to be installed. We will install OpenJDK, which is the default Java development and runtime in Ubuntu 18.04.

Install OpenJDK:

sudo apt-get install -y default-jdk

Verify the Java version:

java -version

The output will be similar to the following:

openjdk version "10.0.2" 2018-07-17

OpenJDK Runtime Environment (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.3)

OpenJDK 64-Bit Server VM (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.3, mixed mode)

Install Apache Maven

First, change your working directory to the /opt/ directory:

cd /opt/

You can download the latest stable version of Apache Maven from the official website:

sudo wget https://www-us.apache.org/dist/maven/maven-3/3.6.0/binaries/apache-maven-3.6.0-bin.tar.gz

Once the download has completed, extract the downloaded archive:

sudo tar -xvzf apache-maven-3.6.0-bin.tar.gz

Next, rename the extracted directory:

sudo mv apache-maven-3.6.0 maven 

Setup environment variables

Next, you will need to setup the environment variables such as M2_HOMEJAVA_HOME and PATH. You can do this by creating a mavenenv.sh file inside of the /etc/profile.d/ directory:

sudo vi /etc/profile.d/mavenenv.sh

Add the following lines:

export JAVA_HOME=/usr/lib/jvm/default-java

export M2_HOME=/opt/maven

export PATH=${M2_HOME}/bin:${PATH}

Save and close the file, and make it executable:

sudo chmod +x /etc/profile.d/mavenenv.sh

Now you can load the environment variables:

source /etc/profile.d/mavenenv.sh

Verify installation

Once everything has been successfully configured, check the version of Apache Maven:

mvn --version

You will see a similar output to the following:

Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3; 2018-10-24T18:41:47Z)

Maven home: /opt/maven

Java version: 10.0.2, vendor: Oracle Corporation, runtime: /usr/lib/jvm/java-11-openjdk-amd64

Default locale: en_US, platform encoding: UTF-8

OS name: "linux", version: "4.15.0-36-generic", arch: "amd64", family: "unix"

Congratulations, you have successfully installed Apache Maven on your Ubuntu 18.04 server. To get started using Maven, visit the official Apache Maven documentation.

]]>
https://support.aklwebhost.com/knowledgebase/install-apache-maven-on-ubuntu-18-04/feed/ 0
How to Install Mosquitto MQTT Broker/Server on Ubuntu 16.04 https://support.aklwebhost.com/knowledgebase/how-to-install-mosquitto-mqtt-broker-server-on-ubuntu-16-04/ https://support.aklwebhost.com/knowledgebase/how-to-install-mosquitto-mqtt-broker-server-on-ubuntu-16-04/#respond Tue, 30 May 2023 13:05:03 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3750 MQTT is a publish/subscribe model based, “lightweight” messaging protocol over TCP/IP for communication between “Internet of Things” devices such as ESP8266, Raspberry Pi, etc. It is very popular with low resources and battery powered applications such as home automation, security alarm systems and battery-powered sensor networks.

Mosquitto is an open source message broker (or server) that implements MQTT protocols. With its good community support, documentation, and ease of installation it has become one of the most popular MQTT brokers.

Prerequisites

  • An Ubuntu 16.04 server with root access
  • Open port TCP:1883 on firewall

Step One: Install Mosquitto Broker

Update Ubuntu’s package list and install the latest Mosquitto Broker available from it

sudo apt-get update

sudo apt-get install mosquitto

The Mosquitto service will start after installation.

Step Two: Install the Clients and Test

Install MQTT clients

sudo apt-get install mosquitto-clients

Mosquitto clients help us easily test MQTT through a command line utility. We will use two command windows, one to subscribe to a topic named "test" and one to publish a message to it.

Topics are labels used by the broker to filter messages for each connected client. A client program subscribed to a topic "Home1/BedroomTemp" will only listen to messages published to the same topic by other clients.

Subscribe to topic "test"

mosquitto_sub -t "test"

Mosquito_sub is a subscribe client we installed in the previous command. Here we are specifying “-t” followed by a topic name.

Publish a message to topic "test"

Login to the terminal as a second instance and publish a message to the "test" topic.

mosquitto_pub -m "message from mosquitto_pub client" -t "test"

Here the additional parameter “–m” is followed by the message we want to publish. Hit “Enter” and you should see a message from mosquitto_pub client displayed in other terminal where mosquito_sub client is running.

Step Three: Secure with a Password

Mosquitto comes with a password file generating utility called mosquitto_passwd.

sudo mosquitto_passwd -c /etc/mosquitto/passwd dave

Password: password

Create a configuration file for Mosquitto pointing to the password file we have just created.

sudo nano /etc/mosquitto/conf.d/default.conf

This will open an empty file. Paste the following into it.

allow_anonymous false

password_file /etc/mosquitto/passwd

Save and exit the text editor with “Ctrl+O“, “Enter” and “Ctrl+X“.

Now restart Mosquitto server and test our changes.

sudo systemctl restart mosquitto

In the subscribe client window, press “Ctrl+C” to exit the subscribe client and restart it with following command.

mosquitto_sub -t "test" -u "dave" -P "password"

Note the capital -P here.

In the publish client window, try to publish a message without a password.

mosquitto_pub -t "test" -m "message from mosquitto_pub client"

The message will be rejected with following error message.

Connection Refused: not authorised.

Error: The connection was refused.

Now publish a message with the username and password.

mosquitto_pub -t "test" -m "message from mosquitto_pub client" -u "dave" -P "password"

Hit “Enter” and you will see the message in subscribe client window, as in Step Two.

Conclusion

We have now set up a password protected MQTT server. You can use the Public IP of your Ubuntu server as an MQTT broker for your projects.

]]>
https://support.aklwebhost.com/knowledgebase/how-to-install-mosquitto-mqtt-broker-server-on-ubuntu-16-04/feed/ 0
How to Install and Configure PHP 7.2 on Ubuntu 18.04 https://support.aklwebhost.com/knowledgebase/how-to-install-and-configure-php-7-2-on-ubuntu-18-04/ https://support.aklwebhost.com/knowledgebase/how-to-install-and-configure-php-7-2-on-ubuntu-18-04/#respond Tue, 30 May 2023 12:38:06 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3748 PHP and related packages are the most commonly used components when deploying a web server. In this article, we will learn how to setup PHP 7.2 on Ubuntu 18.04 LTS.

Prerequisites

  • An up-to-date Ubuntu 18.04 server instance.
  • A sudo user.

Update Ubuntu 18.04

First, update the list of packages:

sudo apt-get update -y

Next, install the updates:

sudo apt-get upgrade -y

Create your sudo user

Ubuntu ships with sudo installed, so the first step will be to simply add a new user:

adduser <username>

You will be asked to set information about this user:

Enter the new value, or press ENTER for the default

Full Name []: Test User

Room Number []: 01

Work Phone []: 5555555

Home Phone []: 5555555

Other []:

You can fill these fields in, or press ENTER to leave them default. After this press Y and then ENTER to verify that the information is correct.

Next, add the new user to the sudo group:

usermod -aG sudo <username>

You can now log out, and log back in as your new user. To test that the user was added correctly, use the following command once you have logged back in as the new user:

ls -la /root

You will receive the following notice:

ls: cannot open directory '/root': Permission denied

When you append the previous command with sudo, you will be asked for your password and receive a list of the /root directory:

sudo ls -la /root

You can now move onto updating Ubuntu.

Install a webserver

You can use Apache or Nginx as your webserver.

To install and start Apache:

sudo apt-get install apache2 -y

sudo systemctl start apache2.service

To install and start Nginx:

sudo apt-get install nginx -y

sudo systemctl start nginx.service

Install PHP 7.2

PHP 7.2 is included in the default Ubuntu repository for 18.04. You can list each of the available PHP 7.2 packages with the following command:

apt-cache pkgnames | grep php7.2

Next, install the packages that your application requires:

sudo apt-get install php -y

sudo apt-get install php-{bcmath,bz2,intl,gd,mbstring,mysql,zip,fpm} -y

Finally, restart your webserver to allow PHP to run.

For Apache, use the following:

systemctl restart apache2.service

Alternatively, use the following for Nginx:

systemctl restart nginx.service

Confirm the PHP version:

php -v

The output will resemble the following:

PHP 7.2.10-0ubuntu0.18.04.1 (cli) (built: Sep 13 2018 13:45:02) ( NTS )

Copyright (c) 1997-2018 The PHP Group

Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies

    with Zend OPcache v7.2.10-0ubuntu0.18.04.1, Copyright (c) 1999-2018, by Zend Technologies

The main config file of PHP 7.2 will be saved as /etc/php/7.2/fpm/php.ini. You can use the vi text editor to modify relevant settings in that file:

sudo vi /etc/php/7.2/fpm/php.ini

Note: Remember to restart Apache or Nginx if you make any changes to that file or any other PHP config files.

You have successfully set up PHP 7.2 on Ubuntu 18.04 to work with either Nginx or Apache. You are now ready to customize your configurations and deploy your apps.

]]>
https://support.aklwebhost.com/knowledgebase/how-to-install-and-configure-php-7-2-on-ubuntu-18-04/feed/ 0
Install Icecast on Ubuntu 18.04 https://support.aklwebhost.com/knowledgebase/install-icecast-on-ubuntu-18-04/ https://support.aklwebhost.com/knowledgebase/install-icecast-on-ubuntu-18-04/#respond Tue, 30 May 2023 12:17:41 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3746 Introduction

Icecast is a popular and flexible solution for streaming audio used primarily for Internet radio stations. It supports Ogg, MP3, Opus and WebM streaming formats over HTTP, SHOUTcast, AAC and NSV. It has been in active development for 20 years and it is popular for its reliability, simplicity and adherence to open standards. It is released as free software under the GNU GPLv2 license.

Installation

Update the APT package list:

sudo apt-get update

Install Icecast:

sudo apt-get install icecast2

Configure Icecast

Right after installing the package an automated configuration window will open. Select Yes to configure Icecast, and follow the prompts.

Icecast can be further configured editing the XML configuration file /etc/icecast2/icecast.xml. The following is an example of how to change the port.

The port can be modified by editing the <port> tag. It is set to 8000 by default:

<port>DESIRED_PORT_NUMBER</port>

Save and exit the file.

Note: To apply the configuration changes you need to restart Icecast.

Further documentation about Icecast config files can be found here.

Binding privileged ports

If you want to run Icecast Server over privileged ports like HTTP (80) and HTTPS (443) you need to do some extra configuration.

Open the config file:

sudo vi /etc/icecast2/icecast.xml

Find the <security> section. Uncomment the <changeowner> section inside and make the following changes:

<security>

    <chroot>0</chroot>

    <changeowner>

        <user>icecast2</user>

        <group>icecast</group>

    </changeowner>

</security>

We also need to tell the operating system to launch Icecast as root.

Open the service file:

sudo vi /etc/default/icecast2

Modify the USERID and GROUPID options so they match the following:

USERID=root

GROUPID=root

Start, restart and stop Icecast

To start the Icecast Server:

sudo systemctl start icecast2

To restart and reload configuration changes:

sudo systemctl restart icecast2

To stop Icecast:

sudo systemctl stop icecast2

Admin panel

Icecast comes with a web interface that serves the audio streams as files. It includes an admin section which lets you see basic information and statistics. You can access it by navigating your web browser to your server address or domain and the port, http://ADDRESS:PORT or http://example.com:PORT.

Streaming with a Source Client

Once the Icecast Server is setup you can use any of the compatible Icecast Clients, (also known as Source Clients), to transmit audio to the Icecast Server and to all the listeners. Usually the Source Client is installed remotely in the location where the audio is going to be transmitted but can be installed together with the Server if needed. There are a variety of options from free and open source applications like mixxx for DJs, IceS for complex automated setups and BUTT for simple microphone sharing; as well as many closed source solutions. A list of free and open source Source Clients can be found at Icecast’s app list

Conclusion

The scope of what Icecast is capable of doing is far beyond this basic setup. Visit the Icecast documentation to explore all the features that it offers, such as: stream relaying, advanced authentication, transcoding, public radio listings and more.

]]>
https://support.aklwebhost.com/knowledgebase/install-icecast-on-ubuntu-18-04/feed/ 0
Install Jitsi Meet on Ubuntu 18.04 LTS https://support.aklwebhost.com/knowledgebase/install-jitsi-meet-on-ubuntu-18-04-lts/ https://support.aklwebhost.com/knowledgebase/install-jitsi-meet-on-ubuntu-18-04-lts/#respond Tue, 30 May 2023 11:10:56 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3735 Jitsi Meet is a free and open-source video conferencing service solution packed with various premium features, such as superior sound quality, high-grade encryption and privacy, and universal multi-platform availability. With the help of Jitsi Meet, you can easily set up a stunning video conferencing service of your own.

Installation

This tutorial explains how to install a video conferencing service on an Ubuntu 18.04 LTS server instance using Jitsi Meet.

Prerequisites

  • A fresh AKLWEB HOST Ubuntu 18.04 LTS x64 server instance with an IPv4 address xxx.xxx.xxx.xxx.
  • sudo user.
  • A domain jitsimeet.example.com pointed to the server instance mentioned above.

Note: When deploying on your server instance, be sure to replace all example values with your actual ones.

1. Set up a Swap Partition

For a machine with 2GB of memory, it’s recommended to set up a 2GB (2048M) swap partition to improve system performance.

sudo dd if=/dev/zero of=/swapfile count=2048 bs=1M

sudo chmod 600 /swapfile

sudo mkswap /swapfile

sudo swapon /swapfile

echo '/swapfile   none    swap    sw    0   0' | sudo tee -a /etc/fstab

free -m

Note: If you are using a different server size, the swap partition size may vary.

2. Set up the Domain Name

You need to correctly set up a hostname and an FQDN for the machine before you can enable HTTPS security by deploying a Let’s Encrypt HTTPS certificate.

The following commands will set up a hostname, jitsimeet, and an FQDN, jitsimeet.example.com, for the machine:

sudo hostnamectl set-hostname jitsimeet

sudo sed -i 's/^127.0.1.1.*$/127.0.1.1 jitsimeet.example.com jitsimeet/g' /etc/hosts

Confirm the results:

hostname

hostname -f

3. Set the Firewall Rules

As required by Jitsi Meet, you need to allow OpenSSHHTTP, and HTTPS traffic, along with inbound UDP traffic on port 10000 through port 20000:

sudo ufw allow OpenSSH

sudo ufw allow http

sudo ufw allow https

sudo ufw allow in 10000:20000/udp

sudo ufw enable

When you see the prompt Command may disrupt existing ssh connections. Proceed with operation (y|n)?, input y and then press ENTER.

4. Update the System

For security and performance purposes, its necessary to update the Ubuntu 18.04 LTS system to the latest status:

sudo apt update

sudo apt upgrade -y && sudo shutdown -r now

You may be informed that the currently installed version of the grub configuration file has been locally modified during the upgrade. Since we are not responsible for the modification, use the UP arrow to highlight the install the package maintainer's version option, and then press ENTER.

After the system reboot, log back in as the same sudo user to move on.

5. Install Required Packages

Jitsi Meet requires Java Runtime Environment and GNU Privacy Guard.

sudo apt install -y gnupg

sudo apt install -y openjdk-8-jre-headless

After OpenJDK JRE 8 installed, use the following command to verify the result:

java -version

The output will be similar to the following:

openjdk version "1.8.0_171"

OpenJDK Runtime Environment (build 1.8.0_171-8u171-b11-0ubuntu0.18.04.1-b11)

OpenJDK 64-Bit Server VM (build 25.171-b11, mixed mode)

In addition, you can setup the JAVA_HOME environment variable as follows:

echo "JAVA_HOME=$(readlink -f /usr/bin/java | sed "s:bin/java::")" | sudo tee -a /etc/profile

source /etc/profile

6. Install Nginx

To better serve Jitsi Meet, you can install an Nginx web server before actually installing Jitsi Meet:

sudo apt install -y nginx

sudo systemctl start nginx.service

sudo systemctl enable nginx.service

You don’t need to manually configure Nginx because the Jitsi Meet installer will deal with this job for you later.

Note: If Nginx or Apache is not in place, the Jitsi Meet installer will automatically install Jetty along with the Jitsi Meet program.

7. Install Jitsi Meet

On a modern Ubuntu or Debian system, you can easily install Jitsi Meet using the official Jitsi deb repo.

First setup the Jitsi repository on your system:

cd

wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | sudo apt-key add -

sudo sh -c "echo 'deb https://download.jitsi.org stable/' > /etc/apt/sources.list.d/jitsi-stable.list"

sudo apt update -y

Then install the full suite of Jitsi Meet:

sudo apt install -y jitsi-meet

During the installation, when you are asked to provide the hostname of the current installation, type in the FQDN jitsimeet.example.com you set up earlier and then press ENTER.

When you are asked about the SSL certificate, highlight the Generate a new self-signed certificate (You will later get a chance to obtain a Let's Encrypt certificate) option and then press ENTER.

After Jitsi Meet is successfully installed, use the following script to apply for a Let’s Encrypt SSL certificate:

sudo /usr/share/jitsi-meet/scripts/install-letsencrypt-cert.sh

During the process, input your email admin@example.com as prompted and then press ENTER. This script will automatically handle any tasks related to the Let’s Encrypt SSL certificate.

Finally, point your favorite web browser to http://jitsimeet.example.com or https://jitsimeet.example.com to access your Jitsi Meet Video conferencing service. Feel free to explore the interface. Clicking the GO button will immediately create a Video conferencing channel for you.

]]>
https://support.aklwebhost.com/knowledgebase/install-jitsi-meet-on-ubuntu-18-04-lts/feed/ 0
Installing Rust on Ubuntu 14.04 https://support.aklwebhost.com/knowledgebase/installing-rust-on-ubuntu-14-04/ https://support.aklwebhost.com/knowledgebase/installing-rust-on-ubuntu-14-04/#respond Sat, 18 Jan 2020 21:42:25 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3041 Rust, commonly known as Rust-Lang, is a system programming language that is developed by Mozilla and backed by LLVM. Rust is known for preventing program crashes, memory leaks, and data races before it is compiled into binary, thus creating a highly-productive and stable programming environment. More recently, Rust has released a stable version 1.0.0, which means that less code updates will be required for developers. This article will show you how to install Rust onto Ubuntu 14.04 x64.

System Update

To make sure that all of Rust’s dependencies are up-to-date, run the following commands.

apt-get update
apt-get dist-upgrade -y
apt-get install curl

Install Rust

Installing Rust is a simple process. Run the following command to launch their installation script.

curl -sSf https://static.rust-lang.org/rustup.sh | sh

When the script finishes, Rust will be installed.

Verifying Rust

To verify that Rust was successfully installed, run rustc -V. You will see output similar to:

rustc 1.0.0 (a59de37e9 2015-05-13) (built 2015-05-14)

Using Rust

To use Rust, create a file called main.rs and populate it with the following lines of code:

fn main() {
    println!("You have successfully installed rust!");
}

Now run rustc main.rs. You will see an executable file called main in the same directory. Execute it by running ./main. The text “You have successfully installed Rust!” will appear on your screen.

]]>
https://support.aklwebhost.com/knowledgebase/installing-rust-on-ubuntu-14-04/feed/ 0
Using Tango on Ubuntu 14.04 https://support.aklwebhost.com/knowledgebase/using-tango-on-ubuntu-14-04/ https://support.aklwebhost.com/knowledgebase/using-tango-on-ubuntu-14-04/#respond Sat, 18 Jan 2020 21:40:12 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3039 Tango is a micro and pluggable web framework built with Golang. It has powerful routing and flexible route combinations, dependency injection embedded, and allows direct integration with existing services. This article will show you how to install and use Tango on Ubuntu 14.04.

If you do not have Golang installed, install Golang using the directions in this article. This may also work on other distros but results will vary.

Install Dependencies

You can skip this step if you have already installed the version controls. Golang will require you to install gitbzr, and/or mercurial. This may be needed if you are downloading libraries from a version control system that is using one of those protocols.

apt-get update
apt-get dist-upgrade -y
apt-get install git bzr mercurial -y

Once everything is installed, you can proceed to the next step.

Install Tango

To install Tango, run the following command:

go get github.com/lunny/tango

If everything went well, you can proceed to the next step. If there was an error, verify your GOPATH by running go env and checking its path. If your project is outside of the GOPATH, and you get a warning about it, you can safely ignore it.

Using Tango

To use Tango, create a file called server.go and populate it with the following lines of code:

package main

import (
  "github.com/lunny/tango"
)

func main() {
t := tango.Classic()
    t.Get("/", func() string {
    return "Hello from AKLWEB HOST Server!"
    })
t.Run()
}

Afterwards, run go run server.go.

Switch over to your web browser and type http://[SERVER_IP]:8000/. Replace [SERVER_IP] with the IP address of your VPS.

If your installation was successful, you will see “Hello from AKLWEB HOST Server!” in your browser.

]]>
https://support.aklwebhost.com/knowledgebase/using-tango-on-ubuntu-14-04/feed/ 0
Setup Spigot on Ubuntu https://support.aklwebhost.com/knowledgebase/setup-spigot-on-ubuntu/ https://support.aklwebhost.com/knowledgebase/setup-spigot-on-ubuntu/#respond Sat, 18 Jan 2020 21:39:27 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=3037 Spigot is a modification of the Minecraft server software, CraftBukkit. Spigot optimizes server resource usage, ensuring your players have the best experience and is also backwards compatible with most CraftBukkit modifications, allowing you to make your server unique. In this guide, we will setup Spigot on Ubuntu Server.

Setting up Ubuntu Server

It is recommended to run all commands as a user with sudo privileges that is not root.

Start by ensuring that your server is up to date.

sudo apt-get update && sudo apt-get upgrade -y

Install the needed packages.

sudo apt-get install git openjdk-7-jre tar -y

Create a swap file

Allocate the desired amount of memory. Replace 1G accordingly.

sudo fallocate -l 1G /swapfile

Secure the permissions of your new swap file.

sudo chmod 600 /swapfile

Allocate the swap space.

sudo mkswap /swapfile

Turn on swap.

sudo swapon /swapfile

Make your swap file permanent. Add the line below to the bottom of the fstab file.

sudo nano /etc/fstab

/swapfile   none    swap    sw    0   0

Download and use BuildTools

Ensure you are in the home directory of the user used for installing Spigot.

cd ~

Create a folder for BuildTools.

mkdir build
cd build

Download BuildTools.jar Look for updates on their Jenkins page.

wget -O BuildTools.jar  https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar

Configure git.

git config --global --unset core.autocrlf

Run BuildTools.jar.

java -jar BuildTools.jar

Make note of the name of your spigot.jar file. For example, spigot-1.8.3.jar.

ls

Make a directory for your server.

cd ~
mkdir server
cd server

Move your spigot.jar into your server directory. Replace spigotname.jar with the name of your file.

mv ~/build/spigotname.jar ~/server/spigot.jar

Starting your server

Create a start up script for your server.

nano start.sh

Make start.sh match the following, replacing -Xmx1024M with the amount of RAM installed on your server.

#!/bin/sh

java -Xms512M -Xmx1024M -XX:MaxPermSize=128M -jar spigot.jar

Make start.sh executable.

chmod +x start.sh

Start your server.

./start.sh

Optional: Run your server in the background

Install screen.

sudo apt-get install screen -y

Open an instance of screen.

screen -S "Spigot Server"

Start your server script.

~/server/start.sh 

Troubleshooting

Accept EULA.

If you are asked to confirm eula.txt, change eula to true.

nano eula.txt

BuildTools.jar wont run?

You need more RAM on your server or a larger swap file.

start.sh can’t run the file command on your jar file?

Check to ensure everything is typed exactly the same, Linux IS case sensitive.

Want to download a specific Minecraft version?

java -jar BuildTools.jar --rev 1.8.4

Replace 1.8.4 with the version of your choice.

]]>
https://support.aklwebhost.com/knowledgebase/setup-spigot-on-ubuntu/feed/ 0