Jade Dungeon

Gen8

Debian

Installing Debian on HP DL360e Gen 8

Recently purchased an HP DL360e Gen 8 1U server. I was expecting the installation to be pretty simple, but it was a bit of a struggle because of the lack of a free software driver for the embedded RAID controller, an HP B320i

The HP DL360e Gen8 is listed as being supported for RedHat 6 and Ubuntu 12.04 here http://h17007.www1.hp.com/us/en/enterprise/servers/supportmatrix/redhat_linux.aspx

If you follow through the small print it does mention the B320i requiring a closed source driver from HP, so I'm annoyed with myself for not noticing that initially, but I thought this kind of nonsense was so last decade. I really feel cheated by vendors when they make these things so hard, and would prefer not to use them, but this organisation is an HP shop so not a lot of choice there.

Redhat provide some information on this also https://access.redhat.com/site/articles/118133 where they list some bad issues with the closed driver and ways to use Free software.

The BIOS with the shipped machine did not have the option to disable the B320i controller though. The resolution was to downgrade the BIOS to the older version from 04/04/2012 from.

http://ftp.hp.com/pub/softlib2/software1/cd/p1040529012/v71197/firmware-10.10-0.zip unpacks to a bootable DVD image, that can be used to run HP Smart Update Manager, and update BIOS and other firmwares.

After the downgrade, there became a bios option to disable the B320i embedded controller, and the drives just present themselves as connected via an HP SAS HBA. Debian detects them and they can be assembled into an array using the Debian installer and standard mdadm tools. I prefer that anyway, as I get better information about the RAID state and email alerts of failures etc, without having to install any additional HP software.

Setting up a Linux home server: Using the HP ProLiant MicroServer Gen8 G1610T

Posted on March 24, 2015 by Josh Stark

In recent years it has become increasingly popular to own your own home server. Whether it’s for personal private data backup, home automation or media storage more and more people are looking into solutions that fit their own personal needs. This guide will cover step-by-step how to go from nothing to a fully functional media and data backup server.

Overview

「Why do we want a media server?」 might be the question your wife asks. 「How dare you」 might be your response. Depending on the strength of your marriage you may or may not want to proceed with this guide. I warn you, once you get into this Linux stuff there’s no going back.

In order to answer your other half’s question you might say 「One of the more popular uses for a home server is to store digital media such as music, photos and video. A media server, allows the streaming of this media throughout our lovely home」. The idea is then that your good lady see’s the light and gives the necessary financial approval to proceed!

The advent of the Raspberry Pi has seen a massive surge in ‘normal’ people taking up tinkering and playing around with Linux. This is great. One of the great advantages of using a small home server (pre-built or custom made) is that they are a lot more suited to the tasks of being either always-on as well as running automated tasks. Finding one with a low power overhead and small form-factor means you can have it running 24/7 without worry.

Keeping that in mind, choosing the right server for your own personal needs is important. There are many different ways to go about setting one up: build your own; buy a ready-made barebones server; or get a NAS (if media storage is your game).

Step 1: The Server

Because this is a beginner’s guide, I’ll be using the HP ProLiant MicroServer Gen8 G1610T as my server of choice. This particular micro server is an excellent starting point due to its cheaper price and decent processing power. It has a low energy footprint with its 150W PSU, mild processing power with an Intel Celeron 2.3GHz Dual Core processor, and 2GB UDIMM ECC RAM as standard. Modest specifications but enough to get you started. It’s also very easy to switch out the Celeron and replace it with a more powerful Xeon should you wish too, and its RAM is extendable to 16GB. On the back, you’ll find 2x USB 2.0 and 2x USB 3.0 ports, 2x gigabit ethernet ports and an iLO port.

Step 2: Storage

The amount of storage you require is directly affected by your use of a home server. With the exception of buying the server itself, buying the storage for it can often be the largest expense in the build. Knowing which type of hard drive and how much storage you actually need is important to consider. For example: if your usage is media storage and file serving, you will likely want a robust hard drive that is designed for quick read access, with relatively infrequent writes. If your requirement is a little more heavyweight (perhaps you’re starting a home business) and you want to use your server for everything from data backup to web serving, you’ll want a drive that is designed for such heavy use.

Keeping that in mind and sticking to the theme of building a home media server, I would highly recommend Western Digital Caviar Green hard drives. They have been specifically designed for moderate desktop use but these are perfect candidates for long-term media storage within a server. However, if you’re more interested in a heavily networked server with RAID (not specifically talked about in this article), then Western Digital Red hard drives may be more suited. Unlike WD Greens, WD Reds are specifically tailored to RAIDed systems due to the way they handle sector reallocations. Hard drive brand / type is a bit like religion and no one brand is ever the ‘right’ choice but some are more right than others. A useful resource is this study conducted by Backblaze to determine long term drive reliability.

The Gen8 itself is compatible (based on specification sheets) with at most 12TB of storage (3TB per bay). (Ed. There is no logical reason why a larger drive would not work though).

Installing the operating system boot disk

This setup makes use of the empty ODD bay for the OS drive. Separating the OS from the storage allows you to switch out data drives at a later date without worrying about compromising any data that might be shared on the OS drive.

To install the OS HDD, you’ll need an adapter that allows usage of the top bay. You’ll need :

connect it to the motherboard. This particular adapter doesn’t have a faceplate, so in light of this, you could snap off the clips on the original faceplate, sand down the back, and glue it on to the front. Having done this myself, it does work rather well.

imgs

Step 3: Choosing the right drive controller

By default, the Gen8 has its Smart Array B120i RAID controller enabled . This particular guide does not go through a RAID option (purely a personal preference from my part) so you’ll need to switch the primary controller from this to the AHCI Controller in the BIOS.

To do this, boot up the server (with or without the disks already installed — it doesn’t really matter at this point):

F9 -> System Options -> SATA Controller Options -> Embedded SATA Configuration, then select Enable SATA AHCI Support. Hit ESC until the option to F10 and Save is displayed.

imgs

imgs

imgs

Now the server’s AHCI controller has been enabled, allowing individual access to each drive.

Step 4: Installing the OS

Whether you’re coming from a Windows or a Linux background, I’d highly suggest using a Linux-based operating system on your server. Linux is very well suited to server architecture due to its low overhead and virtualisation support.

Ubuntu Server is a very good starting point thanks to the widely available documentation and community support. If you wish to use another distribution, that’s absolutely fine (Arch Linux is another favoured distribution around these parts) but this article will be assuming the base operating system is Ubuntu.

I recommend Ubuntu Server LTS (14.04.2 at the time of writing) due to its extended support by Canonical, as well as its lightweight overhead and preinstalled packages. The Server variant of Ubuntu is perfectly suited to this situation as there is no GUI preinstalled, keeping things nice and clean. Should you wish to install a desktop environment (GUI) something like the MATE desktop is a good choice.

The installer is relatively simple — asking you for default login credentials, a device[host] name and which drive to install the OS onto. Make sure you select the HDD in SCSI5. I’d also recommend selecting the OpenSSH option during installation as I find it much easier to work on a headless server (display via VGA isn’t overly pleasant). Do not install the data disks before this step if you value your data!!

Selecting the right boot disk

By default, when any number of disks have been installed into the Gen8, the AHCI controller automatically boots into the disk in Bay #1 . Unfortunately, this is a limitation with the stock BIOS provided with the Gen8 and there is currently no direct workaround to this problem. Ubuntu Server’s main installer allows you to install the GRUB to another disk, more on that in a minute.

The AHCI controller favours USB boot disks over the primary drive, and as such, we can use this fact to install GRUB on an internal USB stick and use that as the boot disk instead. When the option is made available to you in the installer, select the USB stick as the disk to install GRUB to. At this point, depending on how Ubuntu decided to see each disk, it is likely that the USB stick is under /dev/sdf, however this can vary between boots.

imgs

If you skipped this step during the installation of Ubuntu and you need to fix the GRUB to boot from the USB stick, follow this guide (written by IronicBadger).

Fix grub when installed to the wrong drive on Ubuntu

Install grub to the wrong drive by mistake during install? Easily fix this by first finding your boot drive.

sudo fdisk -l

Mine was /dev/sdc

Sudo grub-install /dev/sdc
sudo update-grub

Installing the data disks

Adding the HDDs to each of the bays is relatively trivial. The Gen8 model’s 4 bays are split — Bays 1 and 2 SATA3 6Gbps, while Bays 3 and 4 are SATA2 3Gbps. Generally, you’re not going to notice these kinds of speed differences if your primary use is streaming. It is important to note that the hard drives must face to the right when being inserted (see picture below).

imgs

Step 5: Post-install disk management

Assuming the disks in each bay are all brand new and contain unallocated space (i.e. no partitions), you’ll need to create a primary partition on each.

The first option is to use a LiveCD (Ubuntu Desktop or GParted) to run GParted and format each disk.

The second option is to use the parted command line tool. This is the option I used as I needed to update the partition table to gpt (guid partition table) on each drive (by default they had a dos partition table). The DOS partition table doesn’t support drives larger than 2TB, therefore GPT must be used.

Format your disks with parted

First, identify the disks you need to format:

sudo fdisk -l

This will list all disks on the system. The OS drive should be under /dev/sdf , so take note. At this point, you should see /dev/sda, /dev/sdb etc all as unallocated drives. These are the drives you need to format.

Update the partition table to gpt and create a primary partition (whole disk):

parted /dev/sda
(parted) mklabel gpt
(parted) mkpart primary xfs 0 ­-0
(parted) quit

This should have now formatted the drive and created a primary XFS partition that stretches the entire size of the disk. Note: you don’t have to use XFS as the filesystem — ext4 is also a good, widely used and supported choice.

Repeat this step for all drives that require formatting.

Mounting the disks

Now that the disks have been correctly formatted, you need to add records for each of them into the fstab. This will ensure that they are always mounted from and to the same place whenever the server is restarted. The best way to do this is to use each disk’s ID as a source for the mount. This is safer than using their /dev/sd* location as sometimes Ubuntu will register the disk to a different location on the next boot (this doesn’t always happen but it could).

List the drives you want to mount:

ls -la /dev/disk/by-id/
total 0
drwxr-xr-x 2 root root 560 Feb 22 12:10 .
drwxr-xr-x 7 root root 140 Feb 22 12:10 ..
lrwxrwxrwx 1 root root 9 Feb 22 13:18 ata-SAMSUNG_HM250JI_S15YJD9Q825007 -> ../../sdf
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-SAMSUNG_HM250JI_S15YJD9Q825007-part1 -> ../../sdf1
lrwxrwxrwx 1 root root 10 Feb 22 13:18 ata-SAMSUNG_HM250JI_S15YJD9Q825007-part2 -> ../../sdf2
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-SAMSUNG_HM250JI_S15YJD9Q825007-part5 -> ../../sdf5
lrwxrwxrwx 1 root root 9 Feb 22 13:18 ata-ST31000528AS_5VP2APPF -> ../../sdd
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-ST31000528AS_5VP2APPF-part1 -> ../../sdd1
lrwxrwxrwx 1 root root 9 Feb 22 13:18 ata-WDC_WD20EARS-00MVWB0_WD-WCAZA5929549 -> ../../sdc
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-WDC_WD20EARS-00MVWB0_WD-WCAZA5929549-part1 -> ../../sdc1
lrwxrwxrwx 1 root root 9 Feb 22 13:18 ata-WDC_WD30EZRX-00D8PB0_WD-WCC4N1175701 -> ../../sda
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-WDC_WD30EZRX-00D8PB0_WD-WCC4N1175701-part1 -> ../../sda1
lrwxrwxrwx 1 root root 9 Feb 22 13:18 ata-WDC_WD30EZRX-00D8PB0_WD-WMC4N0E19J8T -> ../../sdb
lrwxrwxrwx 1 root root 10 Feb 22 12:10 ata-WDC_WD30EZRX-00D8PB0_WD-WMC4N0E19J8T-part1 -> ../../sdb1
lrwxrwxrwx 1 root root 9 Feb 22 12:10 usb-0204_Flash_Disk_24163900CE3F7909-0:0 -> ../../sde
lrwxrwxrwx 1 root root 10 Feb 22 12:10 usb-0204_Flash_Disk_24163900CE3F7909-0:0-part1 -> ../../sde1

The disks you’re interested in are the ones starting in ata- and ending in -part1. The listing also shows you their symlink destination so you can get a good idea of where they point to. In this case, we’re interested in the disks in Bays 1-4:

ata-WDC_WD30EZRX-00D8PB0_WD-WCC4N1175701-part1
ata-WDC_WD30EZRX-00D8PB0_WD-WMC4N0E19J8T-part1
ata-WDC_WD20EARS-00MVWB0_WD-WCAZA5929549-part1
ata-ST31000528AS_5VP2APPF-part1

Create some point points for them:

sudo mkdir /mnt/disk1 /mnt/disk2 /mnt/disk3 /mnt/disk4

Then add the entries for them into /etc/fstab:

/dev/disk/by-id/ata-WDC_WD30EZRX-00D8PB0_WD-WCC4N1175701-part1 /mnt/disk1 xfs defaults 0 2
/dev/disk/by-id/ata-WDC_WD30EZRX-00D8PB0_WD-WMC4N0E19J8T-part1 /mnt/disk2 xfs defaults 0 2
/dev/disk/by-id/ata-WDC_WD20EARS-00MVWB0_WD-WCAZA5929549-part1 /mnt/disk3 xfs defaults 0 2
/dev/disk/by-id/ata-ST31000528AS_5VP2APPF-part1 /mnt/disk4 xfs defaults 0 2

Once saved, you can mount the disks:

sudo mount -a

Step 6: Software Installation

Well done if you’ve made it this far. Let’s recap!

The system has been built, the drives installed, and the OS is ready to go. Now you’re ready for the fun bit, turning a vanilla OS into a server. To do this we will need to install and configure software that will be running on your server. There are many things you can do with your server now it’s set up — almost limitless, in fact — but we will stick to a few of the basic functions. Below is a list of guides on the kinds of services you might want to run:

  • NFS – A lightweight file sharing protocol specifically designed for UNIX servers to share large files frequently. This is particularly well-suited if you plan on having multiple media clients around your home that want to receive media streams.
  • Samba – A Windows network file share protocol designed to allow folder sharing over a Windows network. This is a great way to connect Windows profiles across multiple PCs in your home, and acts as a simple way to back up your documents.
  • CUPS – A printer sharing protocol. Perfect if you have an old non-networked printer in your home that you want to put to use.
  • Webmin – A web-based administration tool that gives you quick and easy access to particular tasks you may need to perform from time to time.

Hopefully this guide has helped you to set up your first home Linux server. There’s a large and interesting world out there and it’s your first step to some awesome home automation!

Q & A

hugo3191

Hello,

I bought an g1610t proliant server. I would like to install ubuntu server 14.04 on it but i have some trouble with it. Maybe you could have an idea :)

I put a 32Go usb stick on the internal slot and an 8Go usb stick on an external slot (with the iso on it). I get the first menu where i choose (install ubuntu server), but then i get a black screen, then nothing more.

Do you have an idea about that?

(also the server do a 「lot」 of noise when it boots, but when i choose the option 「instal ubuntu server」, the servier quiets)

Thank you for your help

best regards

Reply

December 3, 2015 Stark

Hi Hugo,

It’s good to see another G1610T user! It’s interesting that you’re getting this strange issue with the installer.

Firstly, have you ensured that the drive controller is in AHCI mode? I have not attempted installing Ubuntu (or any other OS) while the RAID controller is engaged.

I’ve also done a bit of looking around Ubuntu Forums and Ask Ubuntu, and I’ve seen that it may be possible to get past the black screen by setting the nomodeset option before selecting ‘Install Ubuntu’. (http://askubuntu.com/questions/485554/ubuntu-14-04-installation-blank-screen). While I did recommend the LTS version (14.04.2), I installed 14.10 on my own G1610T. While a deviation from the guide, it was just a personal preference as I wanted the latest OS and wasn’t concerned with long term support. It could actually be 14.10 that got rid of the problem.

Times have slightly changed since this article was written, so it may be worth attempting to install 14.04.3 instead as that’s the new LTS version (before 16.04 is eventually released next year). If you’re willing to forego the LTS, then give 15.10 a go. It’s the most recent version of the OS.

Don’t worry about the fan noise. It seems that the fan speeds are linked somewhat to the RAID controller. Support for fan speeds on this are lacking in terms of control from the default BIOS. Once Ubuntu boots up, it takes over and deals with it. I have the same thing on my server.

Let me know how you get on!

Reply

December 6, 2015 hugo3191

Hi, Thank you for replying :) I also ask for that trouble on ubuntu forum and no one have seen something like that too. So i sent the server back and bought a new one. I should get it wednesday. If the thing happen again, it should surely be my fault this time.