Posted on

How-to: Install Varnish and Nginx on Arm Servers

With the release of the Raspberry Pi 3 Model B, we read that Mythic Beasts was hosting a portion of the traffic going to the RaspberryPi.org site on an actual Pi 3! Pretty neat! We took a closer look and realized there wasn’t too much magic going on here, so we decided to write a quick how-to on setting up Varnish to cache content and speed up rendering and delivery of dynamic web pages. Since our little Arm servers are (obviously) not the most powerful platforms around, this can dramatically increase the performance and responsiveness of web servers running on Arm.

This guide will detail how to setup Varnish and Nginx on a Debian 8 “Jessie” Server running on Arm.

First and foremost, we need to perform the actual installation of the software, then we can configure it. We simply run:

sudo apt-get install nginx varnish.

Now, we need to make some changes to setup the environment properly.

The first file we need to take a look at is the Nginx configuration file which should be located at /etc/nginx/sites-available/default

Specifically, we need to move Nginx off of port 80 so that Varnish will be able to take over port 80 traffic. For this example, we will place Nginx on port 8080 instead, so, we update the file to reflect the following:

server
listen 8080; {
root /usr/share/nginx/html;
index index.html index.htm;

# Make site accessible from http://localhost/
server_name localhost.localdomain;

(We are not using a fully qualified hostname in this example, so later on we will go update our hosts file to reflect this.)

Next, we can configure Varnish to go look for Nginx on port 8080, by editing the Varnish config file located at /usr/local/etc/varnish/default.vcl and editing the ‘backend’ section. Here is a simple example: (Note – This one has some common WordPress login pages excluded from being cached)

vcl 4.0;
# Based on: https://github.com/mattiasgeniar/varnish-4.0-configuration-templates/blob/master/default.vcl

import std;
import directors;

backend default {
.host = “127.0.0.1”;
.port = “8080”;
}

sub vcl_recv {
# Do not cache following pages (edit as needed for your configuration).
if (!( req.url ~ “wp-(login|admin|comments-post)” )) {
return (pass);
}

# Drop the cookies for everything else
unset req.http.cookie;

# Try a cache-lookup
return (hash);
}

sub vcl_backend_response {
# Below will cache the page for one week.(1s = 1 sec, 1d = 1 day)
set beresp.ttl = 1w;
}

Once Varnish knows where to look for Nginx, we can now set Varnish to take over port 80 that we previously freed up. To do this, we need to modify the Varnish start file, which in this case is located at /etc/systemd/system/varnish.service because we are using Debian. If you are on another distro, this location may vary. We need to change the ‘-a’ flag from -a :6081 to -a :80, then save and close the file.

The last change we need to make is to our hosts file, to ensure that the local network is interpreted correctly. We need to edit the /etc/hosts file, and add a line that translates 127.0.0.1 to localhost and localhost.localdomain:

127.0.0.1 localhost localhost.localdomain

At this point, we could technically restart the Nginx and Varnish services to read in these changes, but a reboot is probably a good idea as well if you can afford it.

Once the server comes back up, you should now have Varnish running on port 80 caching content from your Nginx web server. One way to test this is to go to http://www.isvarnishworking.com, and put in your IP address (keep in mind, you need a public facing IP for this). If everything is working, you should see a message like this:

varnish-nginx-on-arm-server

Additionally, you can run ‘sudo varnishstat’ to see a detailed breakdown of how much caching is being done by Varnish.

So, thanks go to Raspberry Pi for inspiring us to attempt to duplicate their work. Hopefully this helps you install Varnish and Nginx on Arm, and speed up web page rendering on your Pi’s or other small Arm-based devices!

Posted on

ARM Server Linux Update, March 2016

It has been a few months since our last ARM Server update, and as usual, a lot has changed in just a short time!

The biggest and most important news is the launch of the Raspberry Pi 3, freshly upgraded to a quad-core 64-bit ARM processor from Broadcom, whereas all previous Raspberry Pi’s have been based on 32-bit processors. With 8 million units sold, the Raspberry Pi is by far the most popular ARM single board computer, so the move to a 64-bit processor will potentially add millions of units to the 64-bit ARM ecosystem.

In January, the AMD Opteron A1100 officially launched, which is also a 64-bit model. It is available in 3 different SKU’s with varying core count and speeds, and AMD is arguably the biggest name to launch an ARM Server SOC thus far.

The LeMaker Cello is a new board based on the 96Boards Enterprise Edition specification, utilizing one of the AMD Opteron processors. It has gigabit ethernet, DDR3 memory, SATA, and USB 3.0, so connectivity and data throughput should be excellent.

Finally, as part of the latest 96Boards Reference Software Platform, both Debian and CentOS are now supported for install, and a single 4.4 Kernel run the DragonBoard, HiKey, and HuskyBoard.

So there you have it. Just a few short months, and lots of change has happened in the ARM Server ecosystem (as usual)!

Posted on

ARM Linux Update, December 2015

Since our last update, quite a bit has happened in the Linux on ARM and ARM Server ecosystem. First and foremost, the price point for running a Linux ARM machine has reached a new low, only $5 USD! At the end of November, the Raspberry Pi Foundation released a new board known as the Raspberry Pi Zero, with a 1ghz ARM processor and 512mb of RAM running Raspbian (based on Debian Linux), at an incredible $5 price point. So, while it is not the exactly the fastest ARM PC around, it is still an amazing achievement and value for the $5 cost.

Previous low price leader CHIP from NextThingCo ($9 USD) began shipping to the early Kickstarter backers, though the bulk shipments won’t happen until next year. Following close behind at the $15 price point is the Orange Pi PC, running a quad-core Allwinner H3 with support for Debian, Fedora, Ubuntu, ArchLinux and more.

Another very interesting option is the new PINE64 board currently being funded on Kickstarter. This project promises to deliver Allwinner A64 processors, with 1gb or 2gb of RAM, also starting at $15. This will be the low cost leader for a 64-bit ARM processor board, coming in significantly cheaper than the $75 Qualcomm Dragonboard (although the Dragonboard is still the leader among *currently* shipping boards). According to the project, they are planning support for Ubuntu and Android.

On the server side, SoftIron has showed off their Overdrive 3000 server, based on the AMD Opteron A1100 processor. The Opteron A1100 is a 64-bit, 8-core, ARM Cortex-A57 design, and the Overdrive 3000 adds 16gb RAM, a 1TB hard drive, and 2 10gig Ethernet ports. The server is optimized for cloud, storage, and web based work, while reducing power consumption and TCO in the datacenter.

Looking back, 2015 saw a ton of progress in the ARM Linux ecosystem, and 2016 is shaping up to be just as exciting!

Posted on

Further Developments in the ARM Server Industry

This month, several new ARM Server industry announcements have made headlines, advancing the ecosystem yet again.

First and foremost, Qualcomm announced an enterprise-grade 24-core processor based on the ARMv8-A instruction set, geared towards data centers running Infrastructure as a Service, Platform as a Service, big data, and machine learning workloads.

Second, at the Amazon AWS re:Invent conference, Amazon revealed a new Internet of Things (IoT) service.  The service is geared towards communicating with and powering wearables, sensors, and other small devices listening and measuring the environment around them.  To coincide with the launch, a handful of certified devices and sensors were announced as well.  One of those devices is the Qualcomm Dragonboard, a 96Boards compliant 64-bit ARM single board computer.  While this may not seem like a big deal at first glance, it actually dramatically increases the number of 64-bit ARM Linux devices out in the wild.  The size, scale, and marketing efforts of the Amazon AWS platform will serve to increase adoption and increase the user base.

Finally, the Linaro Connect bi-annual meeting was held in San Francisco, where ARM, Linaro, and many of the industry and ecosystem partners got together to discuss all things Linux on ARM.  As usual, one day of the conference was entirely devoted to the Server ecosystem, with talks and discussions specifically focused on enterprise applications and hardware.  Many, many resources were made available for everyone to review here:  http://connect.linaro.org/sfo15/

Of course, to get familiar with 64-bit Linux on ARM, be sure to check out our 96Boards HiKey server running Debian 8 Jessie!

Posted on

Update: Latest Progress in the ARM Server Industry

Its no secret that at miniNodes, we are ARM fans.  We believe that the future of the datacenter is one where efficiency, density, reduced power consumption, and scalability are the primary design factors.  ARM processors are well positioned to meet that demand, and ARM has committed to making a strategic investment in this market.  However, change does not happen overnight.

Instead, ARM is taking slow, but very deliberate steps to ensure that the hardware and software ecosystem are optimized and mature, to increase their chances of success.  Let’s recap some of those latest efforts:

Red Hat Enterprise Linux Server for ARM Development Preview 7.1 – Red Hat has been working hard on adding support for 64-bit ARM architecture to their popular Linux distribution, and is getting closer to reaching a beta state.  For now however, you do need to be a part of their Early Access Program.

Linaro / 96Boards Project –  This project is focused on driving down the cost of 64-bit ARM hardware and making it more readily available to developers.  Two boards are now shipping, the Dragonboard 410c with a quad-core Qualcomm Snapdragon 410 processor, and the HiKey board powered by an octa-core HiSilicon Kirin 620 processor.   The upcoming “Enterprise Edition” specification is expected to launch in the near future, as well.

CentOS – The CentOS team is hard at work building an ARM version of their Linux distro as well, and have some Google Summer of Code projects devoted to the effort.

Gigabyte – Last month at Computex, Gigabyte showed off a new server motherboard based on the AppliedMicro XGene1 ARM processor, as well as a cold storage server powered by an ARM processor.

So, as you can see, the ARM Server ecosystem is still rapidly evolving, but not with reckless abandon.  Instead, deliberate and measured steps are being taken to ensure a successful entrance in to the datacenter and server industry.

Posted on

How to Install Confluence on an Ubuntu ARM Server

Following up on our previous article, which covered How to Install JIRA on an ARM Server, we’ll now take a look at how to install Atlassian Confluence on an ARM Server as well.

As mentioned in our previous article, when we set out to use Confluence and JIRA for some development work, we noticed there was a lack of information on the topic and no real authoritative guide on how to install and run Confluence or JIRA on ARM platforms. So, we decided to piece together what we learned in the hopes that it will help someone else.

As Confluence is architecturally similar to JIRA, much of the documentation from our prior article is replicated here with just a few minor edits, but we will go through the entire exercise anyways for the sake of clarity.

First, lets discuss the specific environment this guide addresses. This tutorial is for installing Confluence on Ubuntu 14.04 LTS running on ARM architecture processors. It may also work on similar Linux distros such as Raspbian for the Raspberry Pi, Debian, etc, but we only tested and built on Ubuntu Server 14.04 LTS, so your mileage may vary on the others.

Before we get in to the details, here is a quick overview of what we will accomplish in this guide:

1. Add Oracle Java repository
2. Install Oracle Java SDK
3. Download and configure Confluence
4. Run Confluence!

Let’s get started.

First, we need to ensure we have a few software utilities installed that will help us add some software repositories in the next step.

sudo apt-get install python-software-properties software-properties-common

This is going to give us access to the ‘add-apt-repository’ command, which we’ll make use of now:

sudo add-apt-repository ppa:webupd8team/java

sudo apt-get update

This will pull in a new repository that contains the Oracle Java SDK. We need to use the Oracle Java runtime environment, as opposed to the OpenJDK packages that are in the default Ubuntu repos.

sudo apt-get install oracle-java7-installer

The JAVA_HOME variable should be set for you during installation, but just to be certain we are going to install one more utility, which will allow us to also choose which Java to run if more than one are present on your system.

sudo apt-get install oracle-java7-set-default

Once it finishes installing, we run it with:

sudo update-alternatives --config java

And then choose your Oracle Java installation from the numerical options. It will look similar to this:

There are 2 choices for the alternative java (providing /usr/bin/java).

Selection Path Priority Status
————————————————————
* 0 /usr/lib/jvm/java-7-oracle/jre/bin/java 1062 auto mode
1 /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java 1061 manual mode
2 /usr/lib/jvm/java-7-oracle/jre/bin/java 1062 manual mode

Press enter to keep the current choice[*], or type selection number:

Select the one that references your new Oracle Java installation, if it is not already selected.

Once complete, you can test everything is working by running:

java -version

It should give you back information on the installed Java version, and should be similar to this:

java version "1.7.0_60"
Java(TM) SE Runtime Environment (build 1.7.0_60-b19)
Java HotSpot(TM) Client VM (build 24.60-b09, mixed mode)

Now that Java is installed and configured, it is time to download and setup Confluence. Atlassian only provides a binary for installing Confluence on 32-bit and 64-bit x86 platforms, so we cannot use their automated installation scripts. To run Confluence on ARM, we need to use the Archive File option provided by Atlassian. Further reading on the topic can be found here: Installing Confluence on Linux from Archive File (https://confluence.atlassian.com/display/DOC/Installing+Confluence+on+Linux+from+Archive+File). To download the archive, go to https://www.atlassian.com/software/confluence/download and click on Linux. You will see one labeled “Confluence 5.7.3 Server – Standalone (TAR.GZ Archive)” We can see that it is a link to https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-5.7.3.tar.gz (at the time of this writing). That is the file we are interested in.

On your server, navigate to the folder you want to download this file to, and then start the download.

sudo wget https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-5.7.3.tar.gz

Once the download has finished, we need to extract it.

sudo tar -xvzf atlassian-confluence-5.7.3.tar.gz

This will extract the contents of the archive in to a subdirectory. Next, we are going to need to declare a path for the variable ‘confluence.home’, so lets first make a directory to point the variable at.

sudo mkdir /var/confluence

Now we can set the property in the ‘atlassian-confluence-5.7.3/WEB-INF/classes/confluence-init.properties’ file.

sudo nano atlassian-confluence-5.7.3/WEB-INF/classes/confluence-init.properties

Uncomment the line to define ‘confluence.home’ and add /var/confluence/ Save and exit.

At this point, Confluence has what it needs and is able to run, so we can start it with:

cd bin
./start-confluence.sh

Confluence can take up to 10 minutes or more to start, depending on your ARM processor’s core and speed, as well as your filesystem location and speed. Once it’s fully loaded and operational, you can access Confluence by browsing to http://your-ip-address:8080 and going through the steps to finalize setup.

Remember, installing Confluence like this was only tested on an Ubuntu 14.04 LTS ARM Server, but these steps should be roughly the same for installing Confluence on a Raspberry Pi running Raspian, or a Debian ARM server.

Enjoy!

Posted on

How to Install JIRA on an Ubuntu ARM Server

We recently began testing Atlassian JIRA and Confluence for some internal development work, and we noticed there was a lack of documentation on the steps necessary to install and run JIRA on ARM Servers. There are fragmented pieces of information scattered about the web, but not a complete installation guide specifically designed for running JIRA on ARM. Hopefully this walkthrough will help clear up any confusion on the topic, and help you install JIRA successfully.

First, lets discuss the specific environment this guide addresses. This tutorial is for installing JIRA on Ubuntu 14.04 LTS running on ARM architecture processors. It may also work on similar Linux distros such as Raspbian for the Raspberry Pi, Debian, etc, but we only tested and built on Ubuntu Server 14.04 LTS, so your mileage may vary on the others.

Before we get in to the details, here is a quick overview of what we will accomplish in this guide:

1. Add Oracle Java repository
2. Install Oracle Java SDK
3. Download and configure JIRA
4. Run JIRA!

Let’s get started.

First, we need to ensure we have a few software utilities installed that will help us add some software repositories in the next step.

sudo apt-get install python-software-properties software-properties-common

This is going to give us access to the ‘add-apt-repository’ command, which we’ll make use of now:

sudo add-apt-repository ppa:webupd8team/java

sudo apt-get update

This will pull in a new repository that contains the Oracle Java SDK. We need to use the Oracle Java runtime environment, as opposed to the OpenJDK packages that are in the default Ubuntu repos.

sudo apt-get install oracle-java7-installer

The JAVA_HOME variable should be set for you during installation, but just to be certain we are going to install one more utility, which will allow us to also choose which Java to run if more than one are present on your system.

sudo apt-get install oracle-java7-set-default

Once it finishes installing, we run it with:

sudo update-alternatives --config java

And then choose your Oracle Java installation from the numerical options. It will look similar to this:

There are 2 choices for the alternative java (providing /usr/bin/java).

Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/lib/jvm/java-7-oracle/jre/bin/java 1062 auto mode
1 /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java 1061 manual mode
2 /usr/lib/jvm/java-7-oracle/jre/bin/java 1062 manual mode

Press enter to keep the current choice[*], or type selection number:

Select the one that references your new Oracle Java installation, if it is not already selected.

Once complete, you can test everything is working by running:

java -version

It should give you back information on the installed Java version, and should be similar to this:

java version "1.7.0_60"
Java(TM) SE Runtime Environment (build 1.7.0_60-b19)
Java HotSpot(TM) Client VM (build 24.60-b09, mixed mode)

Now that Java is installed and configured, it is time to download and setup JIRA. Atlassian only provides a binary for installing JIRA on 32-bit and 64-bit x86 platforms, so we cannot use their automated installation scripts. To run JIRA on ARM, we need to use the Archive File option provided by Atlassian. Further reading on the topic can be found here: Installing JIRA from an Archive File on Windows, Linux or Solaris. To find the archive, browse to https://www.atlassian.com/software/jira/download and click on “All JIRA download options”. You will see one labeled “JIRA 6.4.2 (TAR.GZ Archive)” We can see that it is a link to https://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-6.4.2.tar.gz (at the time of this writing). That is the file we are interested in.

On your server, navigate to the folder you want to download this file to, and then start the download.

sudo wget https://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-6.4.2.tar.gz

Once the download has finished, we need to extract it.

sudo tar -xvzf atlassian-jira-6.4.2.tar.gz

This will extract the contents of the archive in to a subdirectory. Next, we are going to need to declare a path for the variable ‘jira.home’, so lets first make a directory to point the variable at.

sudo mkdir /var/jira

Now we can set the property in the ‘atlassian-jira/WEB-INF/classes/jira-application.properties’ file.

sudo nano atlassian-jira/WEB-INF/classes/jira-application.properties

Uncomment the line to define ‘jira.home’ and add ‘/var/jira’ (without the quotes). Save and exit.

At this point, JIRA has what it needs and is able to run, so we can start it with:

cd bin
./start-jira.sh

JIRA can take up to 10 minutes or more to start, depending on your ARM processor’s core and speed, as well as your filesystem location and speed. Once it’s fully loaded and operational, you can access JIRA by browsing to http://your-ip-address:8080 and going through the steps to finalize setup.

Remember, installing JIRA like this was only tested on an Ubuntu 14.04 LTS ARM Server, but these steps should be roughly the same for installing JIRA on a Raspberry Pi running Raspian, or a Debian ARM server.

Enjoy!

Posted on

miniNodes.com Launches First Hosted 64-Bit ARM Server

Phoenix, AZ — Cloud hosting provider miniNodes.com, a pioneer in the ARM server hosting industry, is proud to announce the immediate availability of the world’s first hosted 64-bit ARM server. The new 64-bit ARM miniNode is the first publicly available hosted Linux server to use a processor based on the ARMv8 architecture.

While the transition from 32-bit to 64-bit CPU’s is already underway in the smartphone market, the server market has been slower to evolve. This has been due to the limited availability and prohibitively expensive early samples of 64-bit ARM hardware. However, the new 64-bit ARM miniNode eliminates the barriers to entry and dramatically reduces the cost for companies to begin testing software, porting applications, and building new technologies that leverage the benefits of the ARMv8 architecture. The 64-bit ARM miniNode is based on the HiSilicon Kirin 6220 processor, which has 8 ARM Cortex-A53 cores, coupled with 1gb of RAM and 20gb of storage. Linux support includes Debian 8.0 “Jessie” at launch, with other Linux distributions expected to become available in the future.

Although ARM processors already power the vast majority of smartphones, tablets, and media players, as well as some laptops, the biggest market segment poised for growth is the server and datacenter industry. ARM’s low power, high efficiency CPU designs can result in significant energy savings for web-scale datacenter operators, where energy and cooling are the largest costs. Companies can make sure their applications and code are ready to take advantage of these next-generation datacenters by using the new miniNode 64-bit ARM server to achieve compatibility today.

More information about the miniNode 64-bit ARM server can be found on our website, https://www.mininodes.com/product/64-bit-arm-mininode/

More information on ARM Holdings can be located on their website, http://www.arm.com

Posted on

64-bit ARM Servers Now Available!

miniNodes is proud to announce that we have a small number of 64-bit ARM servers built and available for purchase, making us the first provider in the industry to offer this product.  Check them out here:  https://www.mininodes.com/product/64-bit-arm-mininode/

These 64-bit ARM servers are perfect for early adopters to test code and port applications, as well as verify functionality of their programs and squash bugs.  These nodes were built using the 96boards.org HiKey board, so these are 8-core HiSilicon 6220 (ARM Cortex A53) processors with 1gb of RAM and 4gb of eMMC, running pre-release Debian 8.0 “Jessie”, on a Linux 3.18 kernel.  The hardware offers great performance and the software is rapidly evolving.

Keep in mind this is an alpha product, so there are a few Known Issues to be aware of:

  • Reboots are not working yet.  To reboot your node, simply open up a Ticket and let us know you need a reboot.  We’ll power cycle the board.
  • These nodes are behind a firewall and NAT’ed to keep them protected.  SSH access and the standard required ports are open, but not much else.

Until now, it has been prohibitively expensive to acquire, deploy, and run 64-bit ARM servers locally to build and test code designed for the architecture.  However, miniNodes is helping to drive early adoption by providing an alternate, and much more cost effective way to gain access to the platform.

Special thanks for all of the engineering work goes to the Linaro organization, as they have done the bulk of the work in bringing up this hardware and software.