How to install Pogoplug software on V2 Plug

This forum is for Marvell Kirkwood devices such as the GoFlex Home/Net, PogoPlug v1/v2, SheevaPlug, and ZyXEL devices.

Re: How to install Pogoplug software on V2 Plug

Postby moonman » Thu Jun 28, 2012 8:06 am

For testing only for kernel (uname -a) Linux Arch Linux ARM install 3.1.10-11-ARCH #1 PREEMPT Mon May 21 05:59:32 UTC 2012 armv5tel GNU/Linux
EDIT: File deleted not to confuse people
Last edited by moonman on Tue Jul 03, 2012 6:16 pm, edited 2 times in total.
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: How to install Pogoplug software on V2 Plug

Postby moonman » Thu Jun 28, 2012 8:14 am

$this->bbcode_second_pass_code('', './hbplug_init: line 7: 9870 Segmentation fault insmod $INSTDIR/bin/xce.ko
')
:cry:

I suppose it isnt as simple as changinging ioctl to unlocked_ioctl. Some professional input would be nice
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: How to install Pogoplug software on V2 Plug

Postby moonman » Thu Jun 28, 2012 9:41 am

I am a big fool. I've been trying to get xce for pogoplug mobile to run on V2 :lol: Just noticed I had downloaded the wrong source.
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: How to install Pogoplug software on V2 Plug

Postby moonman » Thu Jun 28, 2012 10:03 am

Ok, this one seems to work.
Here's patch:
$this->bbcode_second_pass_code('', '--- xce_dev_old.c 2010-03-23 14:52:24.000000000 -0600
+++ xce_dev.c 2012-06-28 03:48:00.000000000 -0600
@@ -17,10 +17,13 @@
#include <linux/miscdevice.h>
#include <linux/poll.h>
#include <linux/mm.h>
+#include <linux/sched.h>
#include <linux/pagemap.h>

#include <linux/mtd/mtd.h>

+#include <linux/slab.h>
+
#ifdef MODULE_ALIAS_MISCDEV
MODULE_ALIAS_MISCDEV(XCE_MINOR);
#endif
@@ -86,7 +89,7 @@
static ssize_t xce_dev_write(struct file *, const char __user *, size_t, loff_t *);
static int xce_dev_open(struct inode *, struct file *);
static int xce_dev_release(struct inode *, struct file *);
-static int xce_dev_ioctl(struct inode * i, struct file * f, unsigned int r, unsigned long p);
+static long xce_dev_ioctl(struct file * f, unsigned int r, unsigned long p);
static int xce_dev_mmap(struct file *, struct vm_area_struct *);
static unsigned int xce_dev_poll(struct file *, struct poll_table_struct *);

@@ -119,7 +122,7 @@
.write = xce_dev_write,
.open = xce_dev_open,
.release = xce_dev_release,
- .ioctl = xce_dev_ioctl,
+ .unlocked_ioctl = xce_dev_ioctl,
.mmap = xce_dev_mmap,
.poll = xce_dev_poll,
};
@@ -372,7 +375,7 @@

static ssize_t xce_dev_read(struct file * f, char __user * buf, size_t sz, loff_t * off)
{
- XCE_DLOG("Device read %zu bytes by PID: %d\n", sz, current->pid);
+ // XCE_DLOG("Device read %zu bytes by PID: %d\n", sz, current->pid);
return -EIO;
}

@@ -576,7 +579,7 @@
return 0;
}

-static int xce_dev_ioctl(struct inode * i, struct file * f, unsigned int cmd, unsigned long arg)
+static long xce_dev_ioctl(struct file * f, unsigned int cmd, unsigned long arg)
{
void __user *argp = (void __user *)arg;
unsigned int size;
')

Module is attached. I'll be away for a week so test the hell out of it :)
It goes into /usr/local/cloudengines/bin and replaces the existing xce.ko
EDIT: This module is compiled for kernel 3.1.10-11-ARCH and will only work with this version. If there's an update, this module will need to be recompiled. Check your kernel version if the module doesn't load (uname -a)
Attachments
xce.tar.gz
(10.26 KiB) Downloaded 472 times
Last edited by moonman on Thu Jul 05, 2012 5:21 am, edited 1 time in total.
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: How to install Pogoplug software on V2 Plug

Postby rty » Thu Jun 28, 2012 1:33 pm

$this->bbcode_second_pass_quote('moonman', 'I') am a big fool. I've been trying to get xce for pogoplug mobile to run on V2 :lol: Just noticed I had downloaded the wrong source.


You are a hero in my eyes, moonman.

By the way, will you be updating the steps you outlined on post #1 of this thread?
Alarm + Samba + NginX + Php+ MySQL + phpMyAdmin on Raspberry Pi 3, Pogoplug 4, Pogoplug E02, Seagate Goflex Home
rty
 
Posts: 75
Joined: Sun Jun 03, 2012 8:57 am
Location: Singapore

Re: How to install Pogoplug software on V2 Plug

Postby WarheadsSE » Thu Jun 28, 2012 1:39 pm

I think I'll source mine up on GitHub sometime this week, it was an OS'd release anyways. Might have to make a few subtrees for oxnas/kirkwood, and see about pulling the difference for the newer platforms vs what I might have based mine on. Admittedly, I neutered all the gpio calls for the kirkwood one I built. Sadly, I am still attempting to sort out getting it running as a user other than root.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: How to install Pogoplug software on V2 Plug

Postby moonman » Fri Jun 29, 2012 7:23 am

$this->bbcode_second_pass_quote('rty', '
')By the way, will you be updating the steps you outlined on post #1 of this thread?

The steps are the same as in post #2 outlined by WarheadsSE except before step 2:
Run $this->bbcode_second_pass_code('', '/usr/local/cloudengines/bin/hbplug') then,proceed to step 2 and edit the hbplug.conf
$this->bbcode_second_pass_code('', 'nano /usr/local/cloudengines/bin/hbplug.conf')

Example:
$this->bbcode_second_pass_code('', '#example below: vfsdir<number>=<name>,<path>
#vfsdir0=plugdata,/media/2TBDrive/Downloads
installdir=/usr/local/cloudengines
#datadir=.
datadir=.
nohotplug=1
svcid=xxxxxxxxxxxxxxxxxxxxxxx')

Replace the xce.ko with the one I compiled in /usr/local/cloudengines/bin/

Do steps 3 and 4

After step 4 you can put "pogoplug" in the list of DAEMONS in /etc/rc.conf
Reboot and register your device at my.pogoplug.com

So far my plug has been up for 22 hours :)

I don't know if it is legal, but here's the whole cloudengines folder if you don't want to go through the update procedure: http://www.mediafire.com/?vkutk99wfqom15q Let me know if this is againt law or against something, I'll remove the link.
Just untar into /usr/local
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: How to install Pogoplug software on V2 Plug

Postby rty » Fri Jun 29, 2012 11:05 am

Thank you very much Moonman! :D

I got it to work but my Pogoplug V2 (E02) rebooted by itself twice after that (over a period of 1-2 hours). I did replace the xce.ko in /usr/localengines/bin with yours. In your previous post, you mentioned about a patch. Any patch script I have to run? By the way, both random reboot events took place with my SSH terminal session active and my webbrowser displaying disk content over Mypogoplug.com.

Here are some of my observations on my V2 (E02):

1. As you previously noted, hbplug.conf didn't exist in /usr/local/cloudengines/bin.

I created one and filled in as follows

$this->bbcode_second_pass_code('', '
#example below: vfsdir<number>=<name>,<path>
vfsdir0=plugdata,/public
installdir=/usr/local/cloudengines
datadir=.
nohotplug=1
')

I left the svcid line out as WarheadSE suggested. It was inserted automatically afterward.
vfsdir0 line, however, must not be commented out.

2. After completing all the steps, I found another copy of hbplug.conf in my /root directory. I am not sure how it was created or whether I can safely delete it or not. Also the svcid number found inside is different from the one in /usr/local/cloudengines/bin/hbplug.conf.
Alarm + Samba + NginX + Php+ MySQL + phpMyAdmin on Raspberry Pi 3, Pogoplug 4, Pogoplug E02, Seagate Goflex Home
rty
 
Posts: 75
Joined: Sun Jun 03, 2012 8:57 am
Location: Singapore

Re: How to install Pogoplug software on V2 Plug

Postby rty » Fri Jun 29, 2012 2:45 pm

I am not sure if this helps but everytime I start the engine with the command "rc.d start pogoplug", I get error messages even though the engine works.

$this->bbcode_second_pass_quote('', '
')[root@pogo public]# rc.d start pogoplug
Loading fs modules:
Error: could not insert module /usr/local/cloudengines/bin/fat.ko: Invalid module format
Error: could not insert module /usr/local/cloudengines/bin/vfat.ko: Invalid module format
Error: could not insert module /usr/local/cloudengines/bin/hfs.ko: Invalid module format
Error: could not insert module /usr/local/cloudengines/bin/hfsplus.ko: Invalid module format
Error: could not insert module /usr/local/cloudengines/bin/fuse.ko: Invalid module format
Success
Error: could not insert module /usr/local/cloudengines/bin/ufsd.ko: Invalid module format
Loading rt3070sta.ko: Error: could not insert module /usr/local/cloudengines/bin/rt3070sta.ko: Invalid module format
Success
Loading tun.ko: Error: could not insert module /usr/local/cloudengines/bin/tun.ko: Invalid module format
Success
Loading xce.ko: Error: could not insert module /usr/local/cloudengines/bin/xce.ko: Invalid module format
Success
/etc/rc.d/pogoplug: line 77: /dev/xce: No such device
Starting hbplug: Success


Additionally, when I executed dmesg, I spotted these:
$this->bbcode_second_pass_quote('', '
')[ 109.205380] xce: disagrees about version of symbol module_layout
[ 109.240658] hbwd (728): /proc/728/oom_adj is deprecated, please use /proc/728/oom_score_adj instead.


FYI:
Linux version 3.1.10-9-ARCH (root@platinum) (gcc version 4.6.3 (GCC) ) #1 PREEMPT Thu Apr 19 04:10:03 UTC 2012
Alarm + Samba + NginX + Php+ MySQL + phpMyAdmin on Raspberry Pi 3, Pogoplug 4, Pogoplug E02, Seagate Goflex Home
rty
 
Posts: 75
Joined: Sun Jun 03, 2012 8:57 am
Location: Singapore
Top

Re: How to install Pogoplug software on V2 Plug

Postby rty » Sun Jul 01, 2012 3:43 pm

I upgraded to 3.1.10-11-ARCH (#1 PREEMPT Mon May 21 05:59:32 UTC 2012 armv5tel GNU/Linux) and tried to compile xce.ko myself. Ended up with this error instead:

$this->bbcode_second_pass_quote('', '
')[root@pogo pogoplug_xce_2_1_0]# make
Building XCE module for kernel /lib/modules/3.1.10-11-ARCH/build
make -C /lib/modules/3.1.10-11-ARCH/build SUBDIRS=`pwd` modules
make[1]: Entering directory `/usr/src/linux-3.1.10-11-ARCH'
CC [M] /root/xce/pogoplug_xce_2_1_0/xce_mod.o
CC [M] /root/xce/pogoplug_xce_2_1_0/xce_thread.o
CC [M] /root/xce/pogoplug_xce_2_1_0/xce_dev.o
In file included from /root/xce/pogoplug_xce_2_1_0/xce_dev.c:22:0:
include/linux/mtd/mtd.h:29:25: fatal error: mtd/mtd-abi.h: No such file or directory
compilation terminated.
make[2]: *** [/root/xce/pogoplug_xce_2_1_0/xce_dev.o] Error 1
make[1]: *** [_module_/root/xce/pogoplug_xce_2_1_0] Error 2
make[1]: Leaving directory `/usr/src/linux-3.1.10-11-ARCH'
make: *** [all] Error 2


Got the same error even after this copy: cp /usr/include/mtd/mtd-abi.h /usr/src/linux-3.1.10-11-ARCH/include/linux/mtd
Symbolic link doesn't work either.

Moonman, your xce.ko doesn't seem to solve the frequent random reboot issue on my V2. Please help.
Alarm + Samba + NginX + Php+ MySQL + phpMyAdmin on Raspberry Pi 3, Pogoplug 4, Pogoplug E02, Seagate Goflex Home
rty
 
Posts: 75
Joined: Sun Jun 03, 2012 8:57 am
Location: Singapore
Top

PreviousNext

Return to Marvell Kirkwood

Who is online

Users browsing this forum: No registered users and 15 guests