Installing DEBIAN + Openmediavault on Mycloud HOME DUO

符修杰
2023-12-01

I got the WD Mycloud HOME DUO, a two-disc version of the previous Mycloud home device. Since the OEM firmware of this device is the same garbage as in the single-disc version, I had to install the debian on this device. All considerations about the need to change the firmware I outlined in the previous post - it describes the installation of the debian on single-disc devices.
Unlike the semi-working methods previously outlined here, my version does not require changing the standard boot loader of the device, which is a rather dangerous
operation. Checksums of all partitions are automatically recalculated during the installation process. In addition, I refused to use EMMC memory to host the system. The fact is that, unlike single-disc devices, the standard firmware here is placed not on the disk, but in the EMMC flash drive standing on the board. This is done so that, if necessary, it would be possible to freely replace disks without disrupting the system. But EMMC has a rather limited rewrite resource, has a size of only 4G, and stores a regular loader of the U-boot system, the violation of which will lead to the bricking of the device. So I created a partition on each of the disks for the system, and built both of these partitions into RAID1. This allows you to painlessly remove any of the disks from the system on the go, and then insert a new disk, create a partition on it of the desired size and connect it back to the mirror array without reinstalling the system.
Given some of the problems with my previous version of the debian, I've made some important improvements.

I tweaked the kernel sources by throwing out the stupid names of the sataa and satab disk devices. Such names were needed by the regular android to distinguish between internal HDDs and external USB drives. This only hinders us - because of this, openmediavault did not see the disks, and even after the correction refused to work with RAID arrays. Now the disks are called by the canonical names sda and sdb, and openmediavault normally sees raid:

In the previous version, the system was installed blindly - the user could not control the installation process. Here I made a universal flash drive - both repair and installation. On the flash drive there is an installation script that is run by the user in a telnet session. The installation process is now fully user-controlled.
Given the strange desire of some people to return the native firmware, I made a script lying on the same installation flash drive, automatically restoring the original WD system from a backup. In this case, all the data on the disk, of course, is destroyed.
Finally, I have prepared 2 variants of the system - Debian 9 stretch + OMV4 (as in the previous version), as well as the newer Debian 10 Buster + OMV5. The choice of the system to install is made by the parameters of the installation script. The old Debian 9 works faster and the OMV control panel is more responsive. But the debian is 10 newer, and in OMV5 is the latest current version of OMV. So everyone decides for himself what to put to himself. Personally, I settled on Debian9+OMV4.
The only thing I didn't do was the correct HDD sleep mode. I don't have enough time now to patiently look for all the processes that awaken the screw, as docent778did. Perhaps there will be those who want to do the same with this version of the system. I can't yet.
As a result, instead of a completely useless box, we get a full-fledged and quite productive two-disc NAS, with a convenient Web control panel OpenMediaVault.
It looks something like this:

To install the system, you will need any USB flash drive. It should be split with MBR, and the partition with the installation files should be number 1 and formatted in FAT32. On this section, you need to unpack the files from the attached archive, insert the flash drive into the top USB-slot (in the lower one it will not work), hold down the reset button with something sharp and turn on the power. After the indicator blinks evenly, the button can be released.

At the end of the download (about 1 minute), the system will receive a DHCP network address. Next, you need to go to this address by telnet, and in response to the invitation "#" enter the command:

install-omv.sh size type ver
The command has
3 parameters: size - the size of the Linux


partition in gigabytes, from 4 to 1024  type - the type of RAID array to be created:
0 -
RAIDO, stripe 1 - RAID1, mirror
j - a linear array of 2 disks, jbod
x - do not create RAID


ver - version installed1 of the system:
9 - Debian 9 stretch + Openmediavault 4
10 - Debian 10 buster + Openmediavault 5

At the end of the installation, you again get to the command line, and you can reboot the system with the reboot -f command.



the
install-omv.sh 8 1 10

will create an 8 GB partition for the user, create file partitions combined in RAID1 (mirror) on the rest of the disk space, and install Debian 10.

Raid1 is the most reliable - you can replace any of the drives without losing

data. A raid0 array is the fastest - transferring files is about 15% faster than with a linear array, but in the event of a failure of one of the disks, all data is sent to the sink. Linear JBOD array is slower than raid0, but if one of the disks fails, there is a chance to restore at least part of the data using special programs.

Here's an example of an installation

session:
After the installation is complete, you should take some additional steps to configure the disk storage. This is done through the OMV control panel, and is described in detail in the README.pdf file. This file also describes in more detail the procedure for installing the system and there is other important and useful information, including the logins-passwords available in the system of users. So I strongly recommend reading this document, despite the classic dislike of reading the documentation.
Note that this installation option destroys ALL information available there from the
disk. So if you poured there the files you need through the standard firmware, be sure to copy them somewhere before the installation. And finally,  here's a link to archive with files
 类似资料:

相关阅读

相关文章

相关问答