1. Home
  2. Knowledge Base
  3. Provider Guides
  4. Provider Guide: Hetzner – 2 ways to Raid 0

Provider Guide: Hetzner – 2 ways to Raid 0

Article Contents

In this document, we’ll go through how to setup a Hetzner purchased server, using 2 methods to mount your disks in Raid 0.

Make sure your server is in Rescue Mode.


Handy one liner!

echo x | installimage -p /boot:ext3:1G,/:ext4:all -l 0 -r yes -i images/Debian-1010-buster-64-minimal.tar.gz -a -n Hz && reboot

The above command requires no interaction at all. Simply ensure that your server is in rescue mode, then copy/paste the above! As we advise Debian 10 for new installs with our v3 launch of QB Pro coming up, this will install Debian 10 minimal on your server. Do keep in mind that this is for servers utilizing multiple same drives of same space (example: 2x3TB HDD, 3x2TB HDD, 2x1TB SSD etc). This should not be used if your server has various sized drives or utilizes an drive structure such as 1x250GB SSD + 2x3TB HDD. See further down in this article for more on that.


  1. Type the command installimage like shown below.
  1. You will now be presented with a Distro selection screen:
  1. Select either Ubuntu or Debian. The next screen will allow you to choose a version.

    2 things here:
    • Go for a version QuickBox/QuickBox Pro Supports
    • Select one ending with Your-Version-64-minimal. For example; Ubuntu-2004-focal-64-minimal

  2. After selecting your version the following screen appears:
  1. Leave SWRAID at 1, change SWRAIDLEVEL to 0 and type a proper HOSTNAME like Plex-Media-Server (can be done later as well during QuickBox set up) like shown below:


Method 1 – LVM

  1. Find the following lines and delete them:
Before
After
  1. Now go up a bit and uncomment and change the LVM area lines to look like this:

It will take 512 megabyte and use it for boot and use the rest disk group you define a bit below.
Here you use 10G for swap, 20G for temp and all the rest of the storage for a / mount.
Ps. the Swap line can be removed entirely on systems with lots of ram/space 

  1. Hit F10 and Save:


Method 2

  1. Find this section below:
  1. and change the line into this:

It will use 8G for swap, 512 megabytes for boot and all the rest of the storage will be put in /
Ps. the Swap line can be removed entirely on systems with lots of ram/space

  1. Hit F10 and Save:
  1. Accept this warning:

Depending on the method chosen the final screen will look similar to this:

Notice the Raid level 0, and the Formatting partitions corresponds with the set up we made.

  1. Last thing to do is simply – run reboot command and then you can go for a QuickBox set up described in detail https://quickbox.io/knowledge-base/standard-install/


 

Advanced – Fresh Hetzner server with 2X 3TB HDD and 120GB SSD?

First steps.
  1. In the installimage comment out the 2 HDDS’s.
    • Just put an # in front of them.
  2. Make sure you disable SWRAID by setting it to 0 and SWRAIDLEVEL can be set to anything since it will not be utilizing it.
  3. Hit F10 and accept the warnings.
  4. After Linux is done installing, reboot as shown in the initial part of this guide located in the section above!
Secondly when reboot is done.
  1. First run lsblk to grab the name of each drive you’re looking for /dev/sda and /dev/sdb you wont need the SSD obviously
  1. For each drive you’ll need to type fdisk /dev/sdx replace the x with the letter of the drive. and you’ll want to use option n to make a new partition, just go ahead and use the smaller value for start and biggest value for last sector since I’m sure you want to utilize the whole drive, then option p to print the partition table then option w to finalize the whole thing. repeat for all the drives involved.
  2. Once that’s done type the command ls /dev/sd[a-d]* this will list each of the drives and their partitions and the output should look something like the following:
/dev/sda /dev/sda1 /dev/sdb /dev/sdb1 /dev/sdc /dev/sdc1 /dev/sdd /dev/sdd1

You will only list devices within that scope therefore you’ll probably only have 4 entries.

  1. After that you’ll want to fire up mdadm and create a raid array but we will be doing it using the partition device files and not the disk devices. Make use of /dev/sda1 and /dev/sdb1 instead of /dev/sda and /dev/sdb for this.
mdadm --create --verbose /dev/md0 --level=0 --raid-devices=2 /dev/sda1 /dev/sdb1
  1. Change /dev/md0 in the command above to something not already being used and change /dev/sda1 and /dev/sdb1 to the appropriate letters and numbers. Take note of what mdx is being used when you run lsblk you can also change the raid level from 0 to 1 if you want/need the security of not losing your files.
  2. Next you’ll want to type the command ls -l /dev/disk/by-uuid and take note of the entries that are there. You should NOT see an entry for your new array.
  3. Type the command mkfs.ext4 -F /dev/md0 make sure you swap /dev/md0 with whatever you used before.
  4. Type the same command again from the previous step:
 ls -l /dev/disk/by-uuid

There should now be a new entry. Copy that new entry (but you only need the UUID) so as to look similar to the following:

lrwxrwxrwx 1 root root 11 Jul 18 17:12 c9399944-da22-456a-8c6b-d768ac3471b1 -> ../../md4

You will only be needing the c9399944-da22-456a-8c6b-d768ac3471b1 part.

Lastly we need to add the whole thing to your fstab file.
  1. Type nano /etc/fstab and add the entry.
    • You should be adding something like this to the bottom of the file:
UUID=c9399944-da22-456a-8c6b-d768ac3471b1 /path/to/mount ext4 auto 0 0

The only things you need to change are the UUID and the /path/to/mount for obvious reasons.

  1. Hit ctrl+x then y and enter and you’re all good.

Now you may be wondering…

Why do you mount with the UUID instead of the /dev/mdx format everyone uses?

Random Internet Person

The reason is because sometimes for no apparent reason that I can find, Linux likes to rename stuff. I setup my array using /dev/md4 and after a reboot it gets renamed to /dev/md127. So had I mounted it in fstab as /dev/md4 the system won’t boot and creates a headache that takes you over a week to figure out why it doesn’t work.

 

Related Articles
Need Support?
Can’t find the answer you’re looking for? Don’t worry we’re here to help!
Contact Support
The following terms and conditions govern all use of the QuickBox.io website and all content, services and products available at or through the website, including, but not limited to, QuickBox.io Forum Software and the QuickBox.io Support Forums, (taken together, the Website). The Website is owned and operated by (“QuickBox.IO”). The Website is offered subject to your acceptance without modification of all of the terms and conditions contained herein and all other operating rules, policies (including, without limitation, QuickBox.io’s Privacy Policy and Community Guidelines) and procedures that may be published from time to time on this Site by QuickBox (collectively, the “Agreement”). Please read this Agreement carefully before accessing or using the Website. By accessing or using any part of the web site, you agree to become bound by the terms and conditions of this agreement. If you do not agree to all the terms and conditions of this agreement, then you may not access the Website or use any services. If these terms and conditions are considered an offer by QuickBox, acceptance is expressly limited to these terms. The Website is available only to individuals who are at least 13 years old.

Your QuickBox.io Account

If you create an account on the Website, you are responsible for maintaining the security of your account and you are fully responsible for all activities that occur under the account. You must immediately notify QuickBox of any unauthorized uses of your account or any other breaches of security. QuickBox will not be liable for any acts or omissions by you, including any damages of any kind incurred as a result of such acts or omissions.

Responsibility of Contributors

If you post material to the Website, post links on the Website, or otherwise make (or allow any third party to make) material available by means of the Website (any such material, “Content”), You are entirely responsible for the content of, and any harm resulting from, that Content. That is the case regardless of whether the Content in question constitutes text, graphics, an audio file, or computer software. By making Content available, you represent and warrant that:
  • the downloading, copying and use of the Content will not infringe the proprietary rights, including but not limited to the copyright, patent, trademark or trade secret rights, of any third party;
  • if your employer has rights to intellectual property you create, you have either (i) received permission from your employer to post or make available the Content, including but not limited to any software, or (ii) secured from your employer a waiver as to all rights in or to the Content;
  • you have fully complied with any third-party licenses relating to the Content, and have done all things necessary to successfully pass through to end users any required terms;
  • the Content does not contain or install any viruses, worms, malware, Trojan horses or other harmful or destructive content;
  • the Content is not spam, is not machine- or randomly-generated, and does not contain unethical or unwanted commercial content designed to drive traffic to third party sites or boost the search engine rankings of third party sites, or to further unlawful acts (such as phishing) or mislead recipients as to the source of the material (such as spoofing);
  • the Content is not pornographic, does not contain threats or incite violence, and does not violate the privacy or publicity rights of any third party;
  • your content is not getting advertised via unwanted electronic messages such as spam links on newsgroups, email lists, blogs and web sites, and similar unsolicited promotional methods;
  • your content is not named in a manner that misleads your readers into thinking that you are another person or company; and
  • you have, in the case of Content that includes computer code, accurately categorized and/or described the type, nature, uses and effects of the materials, whether requested to do so by QuickBox or otherwise.

User Content License

User contributions are licensed under a GNU General Public License. Without limiting any of those representations or warranties, QuickBox has the right (though not the obligation) to, in QuickBox’s sole discretion (i) refuse or remove any content that, in QuickBox’s reasonable opinion, violates any QuickBox policy or is in any way harmful or objectionable, or (ii) terminate or deny access to and use of the Website to any individual or entity for any reason, in QuickBox’s sole discretion. QuickBox will have no obligation to provide a refund of any amounts previously paid.

Payment and Renewal

General Terms

Optional paid services or upgrades may be available on the Website. When utilizing an optional paid service or upgrade, you agree to pay QuickBox the one-time, monthly or annual subscription fees indicated. Payments will be charged on a pre-pay basis on the day you purchase the service or upgrade and will cover the use of that service or upgrade for a monthly or annual subscription period as indicated. These fees are not refundable. The one exception is QuickBox Pro, which provides a 3 Day money back policy, after 3 days, fees are not refundable.

Automatic Renewal

Unless you notify QuickBox before the end of the applicable subscription period that you want to cancel a service or upgrade, your subscription will automatically renew and you authorize us to collect the then-applicable annual or monthly subscription fee (as well as any taxes) using any credit card or other payment mechanism we have on record for you. Subscriptions can be canceled at any time. Please be advised that renewal fees are non-refundable. We provide courtesy emails notifying you of any upcoming renewals several days in advance, failure to cancel an unwanted subscription is not the responsibility of QuickBox.IO.

Refunds

We provide a 3-day “no questions asked” refund for new QuickBox Pro subscriptions (meaning, not for QuickBox.IO provided services such as Migration Service, Server Optimization, and our Guru Install Service). Refunds do not apply for upgrades or renewals. Such refund shall be available for a period of three (3) days from the end of the business day the purchase was made (and if such day is not a business day, then the following business day). We may refuse to refund people who acted in bad faith or misused the Services, or otherwise violated any of the policies stated in the Terms of Service.

Services

Hosting, Support Services

Optional Hosting and Support services may be provided by QuickBox under the terms and conditions for each such service. By signing up for a Hosting/Support or Support services account, you agree to abide by such terms and conditions.

Responsibility of Website Visitors

QuickBox has not reviewed, and cannot review, all of the material, including computer software, posted to the Website, and cannot therefore be responsible for that material’s content, use or effects. By operating the Website, QuickBox does not represent or imply that it endorses the material there posted, or that it believes such material to be accurate, useful or non-harmful. You are responsible for taking precautions as necessary to protect yourself and your computer systems from viruses, worms, Trojan horses, and other harmful or destructive content. The Website may contain content that is offensive, indecent, or otherwise objectionable, as well as content containing technical inaccuracies, typographical mistakes, and other errors. The Website may also contain material that violates the privacy or publicity rights, or infringes the intellectual property and other proprietary rights, of third parties, or the downloading, copying or use of which is subject to additional terms and conditions, stated or unstated. QuickBox disclaims any responsibility for any harm resulting from the use by visitors of the Website, or from any downloading by those visitors of content there posted.

Content Posted on Other Websites

We have not reviewed, and cannot review, all of the material, including computer software, made available through the websites and web pages to which QuickBox.io links, and that link to QuickBox.io. QuickBox does not have any control over those non-QuickBox.io websites and web pages, and is not responsible for their contents or their use. By linking to a non-QuickBox.io website or web page, QuickBox does not represent or imply that it endorses such website or web page. You are responsible for taking precautions as necessary to protect yourself and your computer systems from viruses, worms, Trojan horses, and other harmful or destructive content. QuickBox disclaims any responsibility for any harm resulting from your use of non-QuickBox.io websites and web pages.

Copyright Infringement and DMCA Policy

As QuickBox asks others to respect its intellectual property rights, it respects the intellectual property rights of others. If you believe that material located on or linked to by QuickBox.io violates your copyright, and if this website resides in the USA, you are encouraged to notify QuickBox in accordance with QuickBox’s Digital Millennium Copyright Act (“DMCA”) Policy. QuickBox will respond to all such notices, including as required or appropriate by removing the infringing material or disabling all links to the infringing material. QuickBox will terminate a visitor’s access to and use of the Website if, under appropriate circumstances, the visitor is determined to be a repeat infringer of the copyrights or other intellectual property rights of QuickBox or others. In the case of such termination, QuickBox will have no obligation to provide a refund of any amounts previously paid to QuickBox.

Intellectual Property

This Agreement does not transfer from QuickBox to you any QuickBox or third party intellectual property, and all right, title and interest in and to such property will remain (as between the parties) solely with QuickBox. QuickBox, QuickBox.io, the QuickBox.io logo, and all other trademarks, service marks, graphics and logos used in connection with QuickBox.io, or the Website are trademarks or registered trademarks of QuickBox or QuickBoxs licensors. Other trademarks, service marks, graphics and logos used in connection with the Website may be the trademarks of other third parties. Your use of the Website grants you no right or license to reproduce or otherwise use any QuickBox or third-party trademarks.

Advertisements

QuickBox reserves the right to display advertisements on your content unless you have purchased a Services account and/or received proper access promotions within the provided Forums.

Attribution

QuickBox reserves the right to display attribution links such as ‘Powered by QuickBox.io,’ theme author, and font attribution in your content footer or toolbar. Footer credits and the QuickBox.io toolbar may not be removed regardless of upgrades purchased.

Changes

QuickBox reserves the right, at its sole discretion, to modify or replace any part of this Agreement. It is your responsibility to check this Agreement periodically for changes. Your continued use of or access to the Website following the posting of any changes to this Agreement constitutes acceptance of those changes. QuickBox may also, in the future, offer new services and/or features through the Website (including, the release of new tools and resources). Such new features and/or services shall be subject to the terms and conditions of this Agreement.

Termination

QuickBox may terminate your access to all or any part of the Website at any time, with or without cause, with or without notice, effective immediately. If you wish to terminate this Agreement or your QuickBox.io account (if you have one), you may simply discontinue using the Website. All provisions of this Agreement which by their nature should survive termination shall survive termination, including, without limitation, ownership provisions, warranty disclaimers, indemnity and limitations of liability.

Disclaimer of Warranties

The Website is provided “as is”. QuickBox and its suppliers and licensors hereby disclaim all warranties of any kind, express or implied, including, without limitation, the warranties of merchantability, fitness for a particular purpose and non-infringement. Neither QuickBox nor its suppliers and licensors, makes any warranty that the Website will be error free or that access thereto will be continuous or uninterrupted. If you’re actually reading this, here’s a treat. You understand that you download from, or otherwise obtain content or services through, the Website at your own discretion and risk.

Disclaimer of Software

This script is intended for general use and no warranty is implied for suitability to any given task. QuickBox.IO will hold no responsibility for your setup or any damage done while using/installing/modifying this script or any of its plugins. Please keep in mind QuickBox.IO nor it’s staff are responsible for keeping your Software and/or Server up-to-date; this is a responsibility solely left to the user of the QuickBox Pro software.

QuickBox.IO and it’s associated staff reserve the right to terminate support at any time on the grounds that third-party applications; not yet approved, tested, or otherwise are found to be a result in QuickBox Pro malfunctioning.

Licensed under BSD 3-Clause

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  • Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  • Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  • Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Limitation of Liability

In no event will QuickBox, or its suppliers or licensors, be liable with respect to any subject matter of this agreement under any contract, negligence, strict liability or other legal or equitable theory for: (i) any special, incidental or consequential damages; (ii) the cost of procurement for substitute products or services; (iii) for interruption of use or loss or corruption of data; or (iv) for any amounts that exceed the fees paid by you to QuickBox under this agreement during the twelve (12) month period prior to the cause of action. QuickBox shall have no liability for any failure or delay due to matters beyond their reasonable control. The foregoing shall not apply to the extent prohibited by applicable law.

General Representation and Warranty

You represent and warrant that (i) your use of the Website will be in strict accordance with the QuickBox Privacy PolicyCommunity Guidelines, with this Agreement and with all applicable laws and regulations (including without limitation any local laws or regulations in your country, state, city, or other governmental area, regarding online conduct and acceptable content, and including all applicable laws regarding the transmission of technical data exported from the country in which this website resides or the country in which you reside) and (ii) your use of the Website will not infringe or misappropriate the intellectual property rights of any third party.

Indemnification

You agree to indemnify and hold harmless QuickBox, its contractors, and its licensors, and their respective directors, officers, employees and agents from and against any and all claims and expenses, including attorneys’ fees, arising out of your use of the Website, including but not limited to your violation of this Agreement.

Miscellaneous

This Agreement constitutes the entire agreement between QuickBox and you concerning the subject matter hereof, and they may only be modified by a written amendment signed by an authorized executive of QuickBox, or by the posting by QuickBox of a revised version. Except to the extent applicable law, if any, provides otherwise, this Agreement, any access to or use of the Website will be governed by the laws of the state of California, U.S.A., excluding its conflict of law provisions, and the proper venue for any disputes arising out of or relating to any of the same will be the state and federal courts located in San Francisco County, California. Except for claims for injunctive or equitable relief or claims regarding intellectual property rights (which may be brought in any competent court without the posting of a bond), any dispute arising under this Agreement shall be finally settled in accordance with the Comprehensive Arbitration Rules of the Judicial Arbitration and Mediation Service, Inc. (“JAMS”) by three arbitrators appointed in accordance with such Rules. The arbitration shall take place in San Francisco, California, in the English language and the arbitral decision may be enforced in any court. The prevailing party in any action or proceeding to enforce this Agreement shall be entitled to costs and attorneys’ fees. If any part of this Agreement is held invalid or unenforceable, that part will be construed to reflect the parties’ original intent, and the remaining portions will remain in full force and effect. A waiver by either party of any term or condition of this Agreement or any breach thereof, in any one instance, will not waive such term or condition or any subsequent breach thereof. You may assign your rights under this Agreement to any party that consents to, and agrees to be bound by, its terms and conditions; QuickBox may assign its rights under this Agreement without condition. This Agreement will be binding upon and will inure to the benefit of the parties, their successors and permitted assigns.

This document was last updated January 18, 2020.

Guidelines

Please add bugs found in QuickBox Pro using this template:

Bug Report
Select Bug Report as the issue template

Please add feature requests for application inclusion in QuickBox Pro using this template:

Application Feature Request
Select Application Feature Request as the issue template

Please add feature requests for general QuickBox Pro using this template:

Select General Feature Request as the issue template
Select General Feature Request as the issue template

Viewing issues as well as feature requests does not require an account.

You will need to create an account on our Lab in order to post both Issues as well as Feature Requests.
You can register an account here if you do not already have one.

We look forward to your reports as well as your ideas and suggestions for ongoing developments to the QuickBox Pro software!

The QuickBox Pro Community Appreciation Day Event Sale is in full effect.
Get your savings on!
00
Days
00
Hours
00
Minutes
00
Seconds