xfs
[Top] [All Lists]

migin (sample_hsm) returns EBADF too

To: linux-xfs@xxxxxxxxxxx
Subject: migin (sample_hsm) returns EBADF too
From: Takayuki Sasaki <sasaki@xxxxxxxxxxxxxxxxxx>
Date: Fri, 28 Sep 2001 19:39:34 +0900
Sender: owner-linux-xfs@xxxxxxxxxxx
Hi there,

I could migrate the file data using migout ( see previous my
mail ), so try to stage the data in with
linux-2.4-xfs/cmd/xfstests/dmapi/src/sample_hsm/migin daemon,
but it returned EBADF too.

# ./migout -l dmapi_log /migfs

It seems that it closes a file descriptor for /dev/dmapi when
starting up.

Here is the patch, also it works for me :)

--- migin.c     2001/03/07 22:43:23     1.2
+++ migin.c     2001/09/28 10:37:25
@@ -112,6 +112,13 @@
         
 
        /*
+        * Turn ourselves into a daemon
+        */
+       error = mk_daemon(logfile);
+       if (error) 
+               exit(1);
+       
+       /*
         * Now we have our filesystem name and possibly a size threshold
         * to look for. Init the dmapi, and get a filesystem handle so
         * we can set up our events
@@ -125,13 +132,6 @@
                exit(1);
        }
 
-       /*
-        * Turn ourselves into a daemon
-        */
-       error = mk_daemon(logfile);
-       if (error) 
-               exit(1);
-       
 
        /*
         * Set the event disposition so that our session will receive 


cheers,

Takayuki


<Prev in Thread] Current Thread [Next in Thread>
  • migin (sample_hsm) returns EBADF too, Takayuki Sasaki <=