Any interests in Kernel 4.0 on My book live?


If you have already backup the data, just format the 1st partition to ext2 format on a Linux PC.
And unpack the rootfs package into it. Then it should boot, and you can ssh to it.
Then you can setup a SWAP partition and the rest as NAS storage.
Just give it a try and post any issue on github page or here.


Thanks mate, I really appreciate your help on this.

Didn’t think it would be that easy though. Might give it a try this weekend. I’ll let you guys know how it turned out. Thanks! :slight_smile:


Are these packages available? I could try to install them on Jessie.


I’m back! :slight_smile:
So, I managed to unpack the rootfs package onto 1st partition and everything went smoothly.
I didn’t manage to mount the 4th partition though. I’m getting a “mount: only root can do that” even when using sudo. Plus, my /etc/fstab seems to be missing, I really don’t know why. Maybe I did something wrong. MBL boots normally though…
I will try it all over again to see if I get a different output. In the meantime if someone could help setup the swap partition, I’d really appreciate it.



You can extract them from a WD image.
I posted the ones I have here


Wrt swap space setup, what is the output of the command “swapon -s” ?
On my system it says:
Filename Type Size Used Priority
/dev/sda3 partition 500608 0 -1

If nothing is diplayed, you can try following commands:
# swapoff /dev/sda3; mkswap -p 16384 /dev/sda3; swapon



Hey @Ewald, thanks for your reply.

I have to repeat the process of formating and unpacking rootfs. But first I think I really should repartition the 1st partition. As I started to make some installs (owncloud and some side-packages) I noticed I only had about 400Mb of unused space.
Anyway, after reinstalling I will try to setup the swap and mount the 4th partition.

Did you manage to install the WD packages on Jessie? Mainly for the leds and stuff. :slight_smile:


I have not tried these packages on Jessie yet. I think I tried on Wheezy, but not 100% sure. I focused my time on compiling a kernel and fixing some of the drivers to improve performance (e.g. crypto). Maybe I can port all these changes to the 4.x kernel, but it’s easier to fix things right now on a 2.6.32 kernel.



I tried to mount the WD Image I used to transform a new 3TB WD Red to a WD Mybook Live, but the mount fails with error “wrong fs type, bad option, bad superblock on /dev/loop0, missing code page or helper program, or other error”.

Thank you for the link; I have seen that installing these packages (on Jessie) is not trivial: for instance wd-nas forces /etc/apt/sources.list back to stock-values and stores standard(?) ssh server-certificates. Did you do any checks/edits before installing them on wheezy?


I was not implying that you can use these packages unmodified on Wheezy or Jessie. Specifically “wd-nas_02.50.00-142897_powerpc.deb” needs to be modified as, like you say, it modifies several system settings like /etc/apt/sources.list or /etc/samba/smb-global.conf. I was merely trying to provide you the packages that came from WD since it takes some effort to extract them. I have things running on Wheezy by editing these package files, but I have not repackaged those in Jessie or Wheezy-ready versions, also because I integrated some code like monitorIO/monitorTemperature into my kernel.

Also it would give the false impression that all WD functions could/would be carried forward, while quite a few things actually don’t work like software updates, factory restore etc. It’s just a few helper functions like, etc that you may want to leverage.



Guys, I’m running out of ideas here. I’ve searched and searched for a solution for this problem and just can’t find any. Here’s what’s happening: I’m trying to mount the data partition, but whenever I execute a “mount” command (as much as “mount -t”) I always get this error:

mount: only root can do that (effective UID is 999)

Does anyone know why this is happening?

I tried your commands to mount swap but running the “swapon -s” afterwards returns absolutely nothing. :confused:


Sorry to hear you have so much trouble. First, you need to make sure that your swap space uses a block size that matches your kernel’s page size. If you are using 16KB then in all commands to create swap space, you should use this size (e.g. mkswap -p 16384)
So first check your kernel page size:
$ sudo getconf PAGESIZE (on my system it’s 64K, on your’s it should be 16K)

Then check your disk partition table
$ sudo parted -l
Model: ATA < your WD drive > (scsi)
Disk /dev/sda: 4001GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt

Number Start End Size File system Name Flags
3 15.7MB 528MB 513MB linux-swap(v1) primary
1 528MB 2576MB 2048MB ext3 primary raid
2 2576MB 4624MB 2048MB ext3 primary raid
4 4624MB 4001GB 3996GB ext4 primary

Model: Linux Software RAID Array (md)
Disk /dev/md1: 2048MB
Sector size (logical/physical): 512B/4096B
Partition Table: loop

Number Start End Size File system Flags
1 0.00B 2048MB 2048MB ext3

Except for partition 4, your first 3 partitions should be similar in size (2G, 2G, 512MB).
Unlike kl-yang, I am using ext3 for boot/root (modified kernel and uboot for this), but your’s should be ext2. Did you also create a Linux Soft RAID /dev/md ? As you can see, in may case I created the RAID group with two drives (sda 0 & 1), but de-activated the second drive. That is why it shows only /dev/md1 within the RAID group.

For performance reasons, your data partition (sda4) should have the same blocksize as your kernel page size. To check this use:
$ sudo /sbin/dumpe2fs /dev/sda4 | grep 'Block size’

Then, fix your missing /etc/fstab, it can create the mount problems you have (missing /proc).
Mine contains:
proc /proc proc defaults 0 0
sysfs /sys sysfs defaults 0 0

## found that Access DLNA can sometimes temporarily use up to 70M of the /tmp sp
## increasing to 100M maximum
tmpfs /tmp tmpfs rw,size=100M 0 0

/dev/sda1 / ext3 defaults,noatime,nodiratime,barrier=1 0 0
/dev/sda3 swap swap defaults 0 0
/dev/sda4 /mnt/DataVolume ext4 exec,rw,noatime,nodiratime,data=writebac
k,barrier=0,nobh,errors=remount-ro,suid 0 1
/mnt/DataVolume/cache /CacheVolume none defaults,bind 0 0
/mnt/DataVolume/shares /shares none defaults,bind 0 0
/mnt/DataVolume/shares /nfs none defaults,bind 0 0

The last 3 lines you don’t need right now (this will come when you start to configure NFS/Samba). For sda1, change ext3 to ext2.

Then run “mount -a” or reboot your NAS.
That’s all I can think of right now…



I finally managed to resize my sda1 and 2 by cutting short on sd4. Unpacked kl-yang’s image’s again hoping to solve some of the problems but they all remain.

Ok, here’s my outputs:

root@localhost:~# sudo getconf PAGESIZE
root@localhost:~# sudo parted -l
Warning: Not all of the space available to /dev/sda appears to be used, you can
fix the GPT to use all of the space (an extra 2 blocks) or continue with the
current setting?
Fix/Ignore? i
Model: ATA WDC WD20EURS-63S (scsi)
Disk /dev/sda: 2000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:

Number Start End Size File system Name Flags
_ 3 15.7MB 528MB 513MB linux-swap(v1) primary msftdata_
_ 1 528MB 5722MB 5194MB ext2 primary raid_
_ 2 5722MB 10.9GB 5194MB ext2 primary raid_
_ 4 10.9GB 2000GB 1989GB ext4 primary msftdata_

No raid indication whatsoever. As far as I understand I can’t create raid on a running device, right? Should I connect the HDD to my laptop again and create it under Ubuntu?

Plus, I wonder why partitions 3 and 4 are flagged as msftdata?

Moving on…

root@localhost:~# sudo /sbin/dumpe2fs /dev/sda4 | grep ‘Block size’
dumpe2fs 1.42.12 (29-Aug-2014)
Block size: 65536

Using “blockdev” though…

root@localhost:~# blockdev --getbsz /dev/sda4

Where do I stand with this one? lol

Now, here’s a “mount -l” output:

root@localhost:~# mount -l
/dev/sda1 on / type ext2 (rw,relatime,errors=continue)
devtmpfs on /dev type devtmpfs (rw,relatime,size=127600k,nr_inodes=7975,mode=755)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,mode=755)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
cgroup on /sys/fs/cgroup/cpu type cgroup (rw,nosuid,nodev,noexec,relatime,cpu)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)

Seems like /proc is properly mounted (is it?).

Thank you so much for your help mate. Without all these issues sorted I can’t even think of installing ownCloud and all the other stuff I need.

PS: Linux is such a pain in the a**. lol

PPS: great… after creating the /etc/fstab and rebooting my SSH is broken. :angry: This is utterly frustrating!


Your partition has sector size of 64K. Original WD kernel use 64K page. The file system sector size must not exceeed the pagesize. The new kernel is compiled with 16K pagesize. On x86 the pagesize is 4K, so the partition will not mount on pc either. That’s the reason to backup first and prepare partition with a pc. Later they can be easily mount on pc for data recovery in case needed. Reformat the partition will allow easy mount.


Things are looking quite good. I noticed your OS partitions are 5GB in size, but is all OK.
You can fix the GPT to use all the blocks in your drive (just hit f after parted -l)

As per kl-yang, you will need to reformat /dev/sda4 to match your kernel page size e.g.
sudo mkfs.ext4 -b 16384 -i 65536 -m 0 /dev/sda4 (block size 16K, avg. file system 64k)

Of course make sure you have no valuable data on sda4 as the above command will erase all data!
This wil fix your mount issue of /dev/sda4.

With respect to the SSH problem: this is a very tricky part of the process and the same problem happened to me a few times. I recommend to enable basic telnet until you are 100% that you can survive a reboot with ssh.
Note that the newer versions of openssh in Debian (like Jessie) disallow password based login for the root user. Therefore you have to change in /etc/ssh/sshd_config:
PermitRootLogin: prohibit-password
PermitRootLogin: yes
In addition, you can place the public part of your ssh key generated on the PC using puttygen in /root/.ssh/authorized_keys.

You are very close!


If only it was that simple. I fixed the GPT using “parted -l” but I still have the same problem. Also formatted sda4 to match the pagesize. But I still get the same error trying to use “mount”. This is definitely something OS related. A simple “mount -t” returns the “mount: only root can do that (effective UID is 999)” error.

I have SSH back. Solution? Deleted the /etc/fstab. I installed the telnet server just in case. But then I created the file again and both ssh and telnet are gone. Seems like creating the fstab file prevents the device from booting.

I’m at a stalemate here. Really don’t know what to do next.


Something must be have gone wrong in the installation process, making the debugging probably so hard :angry:
It seems that either you are not root or the mount command is not owned by root…
What do the ls -l /bin/mount and id commands say?
Right now at work I have no access to a Debian Jessie powerPC instance but on Wheezy it should give:
-rwsr-xr-x 1 root root 92924 Dec 11 2012 /bin/mount
uid=0(root) gid=0(root) groups=0(root)

At least it would explain why /etc/fstab is giving you some much troubles as you would end up with no /tmp, /proc etc. causing telnet, ssh etc. all to fail.



Probably, but it definitely has something to do with kl_yang’s image. I unpacked the image 3 times already, I get the same errors every single time (hey @kl_yang, would you please shed some light on this?? Thanks mate!! :slight_smile:)

Thought I left my laptop on at home, but it’s off though. Can’t really check that command right now. I will try later tonight and see if it helps. But yeah… this sounds like it’s permissions related. In that case how can I fix it? Would “chown” be of any help?

PS: wait a minute… mount is inside /bin? That must be it… I remember checking folder permissions a few days ago and some of them presented “999”. And I think /bin was one of them. BTW… is it normal that some of the OS folders are set to 999?

PPS: did I mention earlier that I’m a complete linux noob? lol :stuck_out_tongue:


To be honest, I cannot see what’s wrong.
I just try to unpack the tar.gz package and boot, it seems fine.
Just to be sure, when you format the partition, use default sector size (4K), which will be easier when later you need disassemble HD and mount on PC to recover data.
When you unpack the image, use tar, not some program (zip/rar) on window, tar will keep the owner and permission bits correct.
Other than those, cannot think of anything can go wrong like this.


Huh… I’m not even sure which app I used to unpack. I did it under Ubuntu. Right-clicked the file under /Documents and selected “Extract here”. Then copied to sd?1 Maybe it was because I copied the folders instead of unpacking directly to the partition?

What’s the best way to format the boot partition then? I opened Gparted and did a simple format. Don’t remember it asking for sector size. I could try formatting again though.