Clean OS (Debian), OpenMediaVault and other "firmwares"

Thanks a lot. Installed following your guide and IPTables are working fine.

It’s worth mentioning that the procedure for installing the new kernel  can be done from within a running NAS. Just make sure you do things right, exactly as described, or it may not boot properly next time.

Hi all, I have  question about keeping system up to date.

I am wondering if i use openmediavault / update manager what is upgraded.

Do you know whether it runs apt-get upgrade? Do i have to run system upgrades manually?

Thanks

Software update in web admin works good. Just disable transmission-plugin first (bug).

Also you can (and must) use apt-get update && apt-get upgrade

Ps: Anyone need software repo for v4 official firmware? (soft, comiled with pagesize=64k and work in v4 fw)

1 Like

Hi Fox_exe and all

during the upgrade i samehow managed to remove openmadiavault, but the OS (debian) is runnig fine… DLNA, FTP, … everything is ok.

Can i reinstall the OS by using image and following the guide from the first comment in this thread?

This time i would like to try clean debian and install the minidlna, ftp, samba by my self :wink:

Thanks

Yeh, sure.

But in OMV you need edit mountpoint of data partition in /etc/fstab:

Remove ‘noexec’, save and run “umount -o remount /mount/point”, where mountpoint - your data directory (/data by default)

1 Like

If you managed to remove OMV and Debian is sane perhaps you do not need a fresh install.

The main utility would be to get entirely rid of configuration files (and some packages likely, such as Nginx) OMV must have left behind.

Otherwise you can always use the purge option while removing a package to make sure configuration fles are deleted as well.

Also, while installing new stuff and given the option to either keep existing configuration files or replace/overwrite them by default package maintainer versions choose the second (it’s a good idea to manually do a backup copy as well, so you  can compare them in the future in case you have problems).

If you are building a Media Server Plex could be a good option. Along with client apps for TVs (Samsung and LG) and mobile devices (which offer a neat interface and additional info and features for media files such as synopsis and automatic subtitles downloading ) and a webinterface, it includes a DLNA server which I have found affords quicker browsing and better organization than MiniDLNA.

Bear  in mind tough that the MyCloud is a bit short on resources to run a Plex Server. It will work but expect periods where the system lags a lot with high loads and a lot of swapping (mostly when Plex is indexing files).

If you go the MiniDLNA way I found there is a package with latest 1.1.4 version for Debian armhf available from  http://www.deb-multimedia.org/. It does use a lot of stuff from SID. I found no problems but one should always think twice before using SID. I managed to render the device totally unusable while performing some updates from SID before.

2 Likes

it seems that i really managed to get rid of openmediavault and related  packages.

The plex media server installation seems to be too advanced for me to test in on the my cloud device directly. I have to play with chroot and bootstrap on PC first.  So i have installed the minidlna instead. I tried the deb-multimedia.org but there was a problem with dependencies in standard debian packages and unstable deb-multimedia repository so i have decided to avoid inreversible mix of packages in the system and go with minidlna 1.0.24.

I also managed to instal Webmin. IMO WebMin gives minimal benefit for single-drive mycloud device comparing to the console. UI is too generic and not very intuitive.  However, i will keep the Webmin for several weeks to give it a chance

I would like to say thanks for all the good hints i have found here :wink:

Webmin has been around for years mostly as a solution for managing webservers and for overall system administration. It is not specifically geared towards home solutions.You can nevertheless better extend it for that purpose by using third party modules such as  MiniDLNA Webmin Module.

MiniDLNA v. 1.1.2 versus v. 1.0.24 adds a better handling of the way content folders are organized. 1.1.2 versus 1.1.4 seems to notoriously add the following option which is useful if you want to serve mediafiles say from a camera, mixing photos and videos:

# + " PV" for pictures and video (eg. media_dir=PV,/home/jmaggard/digital_camera)

As for installing Plex, the bitbucket how-to guide is sound. It will work as it is, although I would suggest installing the chroot outside of the system 2GB partition because of size (the wheezy-armel chroot + Plex amount to as much as 400MB of data).

Is it possible to install it from the SD card?

My device isn’t booting - the two red LEDs are flashing intermittently.

However, when I install the upgraded firmware it looks as if it is booting OK from the SD card.

Can I compile it from source into a bootable binary on the SD card that then installs itself?

If you haven’t tried it, have you an idea of where I should start? The Firmware boots from:

MyPassportWireless_1.03.13.bin

If you put it on the SD card in a directory called ‘update’.

Presumably one way to get it to would would be to replace the above .bin with a compiled binary, then boot it from the SD card - and then login to move install linux where it’s supposed to be.

Is there an easier way you can suggest?

I’d imagine that, at WD, when a broken device comes in, they pop an SD card in and boot from that, it’d make sense, then they can run diagnostics etc, without disturbing the other volumes. I imagine that’s how they recover data.

That looks a possibility - if you boot from the SD card, there’s clearly some sort of ROM based OS  that runs. Do you know if that system has ‘tar’ ‘cp’ and ‘dd’ in it? If it does, then a script that does what you suggest below should do the trick.

Is there an easy way to build a bootable .bin file for the SD card? I see it has to have all the .md5 signatures correct, but, presumably, that’s to make sure that it’s not corrupted, not to prevent anybody from making a similar bootable binary.

From init script (Barebox / bootloader):

#./boot
sata # initialize SATA
sataenv run 7 # try to run script from partition 7
sataenv run 8 # try to run script from partition 8
. /env/bin/boot_sata # if all else fails, use this script to boot

Normal boot script commented, so no possible to boot from any other device except sata. Sorry.

From init script (Barebox / bootloader):

#./boot
sata # initialize SATA
sataenv run 7 # try to run script from partition 7
sataenv run 8 # try to run script from partition 8
. /env/bin/boot_sata # if all else fails, use this script to boot

Normal boot script commented, so no possible to boot from any other device except sata. Sorry.


Partition 7 is the DataVolume partition, I think - what is partition 8? Is it the SD card?

But the firmware is installed from the SD card by booting from the ‘update’ directory. 

Do you have the source of /env/bon/boot_sata  — It must have a provision for booting from the SD card.

fustbariclation wrote:

Partition 7 is the DataVolume partition, I think - what is partition 8? Is it the SD card

But the firmware is installed from the SD card by booting from the ‘update’ directory. 

Do you have the source of /env/bon/boot_sata  — It must have a provision for booting from the SD card.

No. You wrong:

/dev/sda1 - raid 1 Disk #1 - Root FS (mdadm raid)
/dev/sda2 - raid 1 Disk #2
/dev/sda3 - Swap
/dev/sda4 - Ext4 - User data (DataVolume)
/dev/sda5 - Main kernel
/dev/sda6 - backup kernel (Не используется вообще нигде)
/dev/sda7 - Boot config for Barebox
/dev/sda8 - Backup config (Not used)

There is no support for SD card. Only sata port (‘sata’ command from boot script initializing internal sata port. USB port not used at boot)

How does it boot from the SD card to install firmware then?

Hi hvalntim

i have installed the plex media server. I am still wondering how it is possible that it works with mixed armel/armhf architecture. It seems that armhf is backward compatible;-).

However, OS died while plex indexing large number of files. I am not sure whether it runned out of memory but at the end OS stands still :-(. I stopped all my services to spare some memoty and tried again, but it did not help. I am thinking mounting the tmp to the HDD. I am not sure whether plex media server uses the tmp folder but when it does it might eat all the RAM. Didi you do some tweaking to make the plex server really working?

ARMHF - Floating point instructions works at hardware (No emulation)
ARMEL - Floating point instructions emulated programmatically.
There is no difference between armel/armhf (but hf works faster)

1 Like

Great work Fox_exe and thanks for the guide. Since I have no linux knowledge I used the auto installation guide. After the installation I cannot access dev/sda4. I cannot see the partitions when i use fdisk. But can see it with sfdisk.

What should I do further? Please help. I dont need any raid functionality, I just want to install Minidlna and logitech media server on my device.

fdisk -l

WARNING: GPT (GUID Partition Table) detected on ‘/dev/sda’! The util fdisk doesn’t support GPT. Use GNU Parted.

Disk /dev/sda: 3000.6 GB, 3000592982016 bytes
255 heads, 63 sectors/track, 364801 cylinders, total 5860533168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sda1 1 4294967295 2147483647+ ee GPT
Partition 1 does not start on physical sector boundary.

Disk /dev/md0: 2047 MB, 2047803392 bytes
2 heads, 4 sectors/track, 499952 cylinders, total 3999616 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000

Disk /dev/md0 doesn’t contain a valid partition table

Disk /dev/md1: 2047 MB, 2047803392 bytes
2 heads, 4 sectors/track, 499952 cylinders, total 3999616 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000

Disk /dev/md1 doesn’t contain a valid partition table

sfdisk -l

WARNING: GPT (GUID Partition Table) detected on ‘/dev/sda’! The util sfdisk doesn’t support GPT. Use GNU Parted.

Disk /dev/sda: 364801 cylinders, 255 heads, 63 sectors/track
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

Device Boot Start End #cyls #blocks Id System
/dev/sda1 0+ 267349- 267350- 2147483647+ ee GPT
start: (c,h,s) expected (0,0,2) found (0,0,1)
/dev/sda2 0 - 0 0 0 Empty
/dev/sda3 0 - 0 0 0 Empty
/dev/sda4 0 - 0 0 0 Empty

Disk /dev/md0: 499952 cylinders, 2 heads, 4 sectors/track

sfdisk: ERROR: sector 1076830729 does not have an msdos signature
/dev/md0: unrecognized partition table type
No partitions found

Disk /dev/md1: 499952 cylinders, 2 heads, 4 sectors/track

sfdisk: ERROR: sector 1076830729 does not have an msdos signature
/dev/md1: unrecognized partition table type
No partitions found

pradeepzn, what exacly firmware you installed? Clean debian?

Ok, just edit mount point:

nano /etc/fstab

And edit or add this line:

# Data ("Shares" in original firmware)
/dev/sda4 /data ext4 noatime,data=writeback,barrier=0,nobh,errors=remount-ro 0 0

Change /data to any other folder (But crete this folder first: mkdir /data )

Save it (crtl-x, yes) and run mount -a (Or reboot device)

Clean Debian is the firmware. Edited fstab as advised, now i can access my library.

I installed logitech media server, i can access the web page and configure, will test it further with my streaming devices.

Please suggest, can I go ahead and install other tweaks like samba4 ?

Thanks a lot for the guidance…

even 180 MB free ram did not help to run the plex media server on top of my 1000 + familly photo and  video archive :frowning:

Whole system got frozen everytime the plex tried to index archive. Seems that Plex server on mycloud is not really suitable  for large familly archives. However, i managed to install the miniDLNA 1.1.2 via debootstrap thanks to  ikubux’s guide. So i am now happily running  miniDLNA 1.1.2 for my kids and  miniDLNA 1.0.24 for my movies in paralel.  

FYI Jessie debian release seems to be running in chroot without any problems