Re: Can not rename(move) a file in java.io.tmpDir to a mounted gluster volume

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




----- Original Message -----
> From: "ssdf dfdfd" <kkyspy@xxxxxxxxx>
> To: gluster-users@xxxxxxxxxxx
> Sent: Sunday, May 24, 2015 9:01:41 AM
> Subject:  Can not rename(move) a file in java.io.tmpDir to a	mounted gluster volume
> 
> gluster version: 3.6.2 from ppa:gluster/glusterfs-3.6
> os: ubuntu 14.04
> 
> The gluster volume is mounted at '/nfs_gluster'. A jave http server
> takes uploaded files in directory '/tmp' and rename (move) them to a
> subdirectory in the volume at '/nfs_gluster/data'. Here is the java
> code
> 
> UPLOADED_FILE.renameTo(new File('/nfs_gluster/data', NEW_FILE_NAME);
> 
> The java program runs without any error or exception, but no file was
> moved: there was nothing in '/nfs_gluster/data'.
> 
> However, if I set java to use a tmp directory that is also part of the
> mounted volume, everything works as expected: the uploaded files was
> moved to '/nfs_gluster'. ie,
> 
> System.set("java.io.tmpDir", "/nfs_gluster")
> 
> make everything work.
> 
> I believe this is a bug, probably relate to
> 
> http://www.gluster.org/pipermail/gluster-users.old/2015-January/020194.html

Is it something to do with cross file-system rename. I am not familiar with
Java but we encountered similar issue with python.

See http://bugs.python.org/issue212317.

A quick google search gave me below mention link:
http://stackoverflow.com/questions/7087743/how-to-rename-a-file-to-another-file-system

> 
> Cheers
> David
> _______________________________________________
> Gluster-users mailing list
> Gluster-users@xxxxxxxxxxx
> http://www.gluster.org/mailman/listinfo/gluster-users
> 
_______________________________________________
Gluster-users mailing list
Gluster-users@xxxxxxxxxxx
http://www.gluster.org/mailman/listinfo/gluster-users




[Index of Archives]     [Gluster Development]     [Linux Filesytems Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux