Hi,
I hope this is the right forum to post this question, to me it seemed the best match.
I have a problem regarding mounting a JFFS2 partition using NFS. I am using kernel 2.6.20 on my (embedded) system, which I had to patch in order to get this working:
Code:
Index: linux-2.6.16/fs/jffs2/super.c
===================================================================
diff -u -r1.1 -r1.2
--- linux-2.6.16/fs/jffs2/super.c 6 Jun 2006 16:18:24 -0000 1.1
+++ linux-2.6.16/fs/jffs2/super.c 6 Sep 2006 14:14:37 -0000 1.2
@@ -80,6 +80,10 @@
.sync_fs = jffs2_sync_fs,
};
+/* Just declare a void structure as A NULL value implies the default */
+static struct export_operations jffs2_export_ops;
+
+
static int jffs2_sb_compare(struct super_block *sb, void *data)
{
struct jffs2_sb_info *p = data;
@@ -150,6 +154,7 @@
spin_lock_init(&c->inocache_lock);
sb->s_op = &jffs2_super_operations;
+ sb->s_export_op = &jffs2_export_ops;
sb->s_flags = flags | MS_NOATIME;
ret = jffs2_do_fill_super(sb, data, (flags&MS_VERBOSE)?1:0);
@@ -314,6 +319,7 @@
.name = "jffs2",
.get_sb = jffs2_get_sb,
.kill_sb = jffs2_kill_sb,
+ .fs_flags = FS_REQUIRES_DEV,
};
static int __init init_jffs2_fs(void)
See:
http://mhonarc.axis.se/jffs-dev/msg01865.html
However, I've updated to kernel 2.6.23-rc3, and now I have some weird problem mounting this partition over NFS. Mounting seems to work just fine, and I can even do ls and see the files that are on the partition. However, as soon as I try to access a file (e.g., using cat), I get the error message:
cat: /usr/local/script.sh: Stale NFS file handle
Creating a file also seems to work, e.g.
echo "Test" > /usr/local/test.txt
seems to work, the file is actually created. However, it turns out to be empty when catting it...
Has anyone got a clue as to what might have changed in the recent kernels that could trigger this problem?
Thanks,
Sander