htc2010

Why Does the Install Require a USB Stick?

Recommended Posts

Is there a specific reason why the boot images must be run from a USB stick or LiveCD? Other than the obvious need to have a quick way to update boot images or OS images, is there any other technical reason why the boot image has to be on a stick? I have a SATA DoM I want to use for this purpose and was wondering if XPenology would still install if I (1) cloned a USB to the SATA disk-on-module,(2) set the SATA DoM as boot drive, and (3) installed the OS using the standard installer from tutorials, and (4) created my RAID5 array using the 3 hard drives attached to a PCIe SATA III controller card? Similarly, I notice that other NAS distros do allow you to specifically install to a standalone drive in the server if available or allow an install to another USB stick. I just don't see that option available with XPenology.

 

Alternatively, I was hoping to "force" the installation to go onto the disk-on-module by using a standard install procedure using a USB stick, and then attaching my RAID array separately, to get the added benefit of a standalone install on an SSD. Has anyone tried either instance? Lastly, I am aware that installing XPenology using either method yields very minimal performance benefits; I'm just curious to know if it's possible as a strictly academic exercise - that and my need to just use up the spare parts I have sitting around.

 

Many Thanks in Advance!

 

PS: Yes, I have seen the Cyanlabs tutorial on installing without a USB stick. However, that method seems outdated using DSM 5.0. I would like to attempt the above with DSM 5.2.

Share this post


Link to post
Share on other sites

The USB is just a boot environment, not installation media and not the OS. The OS is installed on your disks in the NAS itself in a separate (non-accessible from GUI) raid container. Putting it on anything other than a cheap/free small thumbdrive is really being wasteful.

Share this post


Link to post
Share on other sites

Thanks for clarifying. It does basically answer my question that it will work, albeit in a roundabout way as I mentioned in the OP. It's really just about aesthetics. I have a cheapy USB flash drive but don't like it sticking out of the system. Too easy to get knocked out, thus the reason I want to either put the bootloader onto the SATA DoM inside the chassis. Alternatively, I could also boot from a USB stick, do the initial install to the DoM, and then add the HDD's after. This, I assume, will put the DS OS directly onto the SSD device and use the RAID array for storage, as opposed to being installed onto the array directly, correct?

Share this post


Link to post
Share on other sites

I regularly flash the DOM in my machine once I am satisfied with the stability of a release. Just use the dd command and write the boot image to the device. The tricky part is identifying the DOM device.

Share this post


Link to post
Share on other sites

superb ... I'm actually coming from a strictly no-linux background. I'm going to use a cloning utility to dump my 16GB bootable USB to my 16GB DOM module. That part'll be easy ... The last of my components are coming today - can't wait!

Share this post


Link to post
Share on other sites

viewtopic.php?f=2&t=4606

 

See the 'Replacing QNAP Boot Image with XPEnology' section. You will need to find your own DOM by size, not sure exactly what that will be. Otherwise the steps should be the same.

Share this post


Link to post
Share on other sites

Thank you for that link! Converting a QNAP device to Synology ... QNAP engineers should have a heart attack seeing that, LOL.

 

Thank you for the link. I'm anxiously awaiting all my pieces arriving today ... Got my motherboard, PCIe SATA controller, and case. Just waiting on the drives today. Will be mounting 3x500GB 2.5" drives into this tiny little 65 watt Antec ISK 300 case.

Share this post


Link to post
Share on other sites

All the parts came and I finished assembling. Now I GET IT. So for everyone else who came into the same situation as myself: the reason that you MUST use a USB stick is that the installer for DS installs itself in a psuedo-RAID fashion across all physical disks as part of its scripted installer. It does not overwrite USB. By booting from my DOM and attempting to install DS, it would be attempting to install to every physical drive, effectively installing OVER the bootloader and rendering the device unbootable. I see where Cyanlab's mod comes in, which allows you to get this working without a USB stick!

 

So what I ultimately did is this ...

 

Unplug all HDD's except the DOM. This forces DS to install directly to the DOM, effectively putting the OS on a separate, standalone drive. Then after updating and configuring, plug in the HDD array. In reality, I have a feeling that DS will install itself over to the array anyway as a failsafe, but that's kind of an under the hood thing that I'm not privy to. So far, so good. Update 2 installed perfectly. Does anyone have any insight on how DS installs itself from drive to drive?

Share this post


Link to post
Share on other sites

I think your deductions are right - I experienced something similar.

 

I originally had an ESXI virtualised setup - USB boot, DSM virtual machine installed onto an SSD. After all booted/installed/updated I added two new 3TB drives and created a SHR volume spanning the two.

 

Long story short, ESXI wasn't stable, so I decided to move to bare metal.

 

Removed the SSD and put in a USB key with the DSM installer and booted. To my surprise, Is booted straight into DSM, and i didn't need to reinstall the DSM software.

 

Can only assume that whenever you create a new Volume in DSM it also installs the DSM software onto it - As somebody else suggested, this is a good form of fault tolerance as it will still boot after losing *any* drive (assuming you have more than 1!)

Share this post


Link to post
Share on other sites

The USB is a bootloader only. It's not meant to be written to. In a real Synology box, internally there is flash storage on a little board that plugs into an internal type usb header. Most of the time when people have issues with their box not booting, nothing happening, ect, it's because this usb flash storage got corrupted. It's not intended to be written to. It just boots the box, and is what either greets you with the install wizard, or boots of the install on your disk array.

 

When you create an array, it partitions each disk into at least 3 partitions. 1st one is DSM install - it's mirrored onto every storage disk in your box (not the usb flash). 2nd is swap partition - it's also mirrored on every storage disk. Partition 1 and 2 are basically RAID 1. Partition 3 is your storage array, which can be a few different RAID types depending on what you chose during the array creation, and the number of disks you have.

 

Now you may be able to trick/hack the DSM install onto your boot disk... (some have done it). But it's not really going to do much for you, as DSM will still be installed on the 1st partition of every storage disk. The only way DSM will not partition a disk is either esata/usb (removable drives), which can't be used in arrays.

Share this post


Link to post
Share on other sites

I have gone to using Sandisk Cruzer Fit drives. I ordered a bunch of 16gb sticks of the USB 3 variant (~$9US each) for use with XPenology and ESXi. They are very small, so much so that I would recommend putting a lanyard on then or something you can use to help pull them out. It has worked out quite well in both environments. I am using them in USB2 ports.

Share this post


Link to post
Share on other sites

I have my Xpenology box running and I can now confirm some of these details that I was inquiring about over the past day. And Diverge, thank you for that detail. Based on what I just did with my server, that is exactly what happens. Originally, I had DSM installed directly onto my SATA DoM without any other drives attached. Then I added the RAID array separately. Once I got it all working, I converted the SATA DOM into an SSD cache drive, which required it to be wiped. In doing so, the device went into degraded mode right away, rebooted, and repaired itself, using the installed copies on the other drives. Extremely good fail safe, I'm loving it. :smile:

 

So yes, using an SSD really makes no difference in terms of storage performance. It's all installed into every drive anyway. However, having an SSD attached for an iSCSI drive attached as a cache drive will be a nice way to push things over the edge!

Share this post


Link to post
Share on other sites

I don't know if it is fixed, but the SSD cache setup in DSM in Xpenology was broken last time I tried to use it and I am not sure it ever got fixed. Maybe someone else can chime in?

Share this post


Link to post
Share on other sites