All of lore.kernel.org
 help / color / mirror / Atom feed
* Move .nfsXXXX files
@ 2007-01-31 13:33 Trinabh Shukla
  2007-02-01  3:42 ` Trond Myklebust
  2007-02-05 17:51 ` Suresh Jayaraman
  0 siblings, 2 replies; 3+ messages in thread
From: Trinabh Shukla @ 2007-01-31 13:33 UTC (permalink / raw)
  To: nfs


[-- Attachment #1.1: Type: text/plain, Size: 550 bytes --]

The .nfsXXXX file get created when I remove a file while it's being kept
open by one of the process. Due to this I can't remove directory which hold
this file. So I want to move this .nfsXXXX file on different temp directory
on the same nfs file system and delete that directory. Here it's working
properly.

But let me know that is it a correct solution? And removal of .nfs files
does not cause the server serious integrity.

Also it will be good, if you lead some pointers about how this .nfsXXXX
files handle by the NFS server.

Thanks,
-Trinabh

[-- Attachment #1.2: Type: text/html, Size: 594 bytes --]

[-- Attachment #2: Type: text/plain, Size: 347 bytes --]

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

[-- Attachment #3: Type: text/plain, Size: 140 bytes --]

_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Move .nfsXXXX files
  2007-01-31 13:33 Move .nfsXXXX files Trinabh Shukla
@ 2007-02-01  3:42 ` Trond Myklebust
  2007-02-05 17:51 ` Suresh Jayaraman
  1 sibling, 0 replies; 3+ messages in thread
From: Trond Myklebust @ 2007-02-01  3:42 UTC (permalink / raw)
  To: Trinabh Shukla; +Cc: nfs

On Wed, 2007-01-31 at 19:03 +0530, Trinabh Shukla wrote:
> The .nfsXXXX file get created when I remove a file while it's being
> kept open by one of the process. Due to this I can't remove directory
> which hold this file. So I want to move this .nfsXXXX file on
> different temp directory on the same nfs file system and delete that
> directory. Here it's working properly. 
> 
> But let me know that is it a correct solution? And removal of .nfs
> files does not cause the server serious integrity. 

The .nfsXXX file is a sign that some process still has that file open.
If you forcibly delete the file, you are very likely to screw up that
process. Better then just to kill the process.

You might be able to move the file to another directory, but the problem
then is that the process that tried to delete the file may not have
write access to that directory. In this case, the unlink may fail, and
you will be left with a dangling .nfsXXX file.

> Also it will be good, if you lead some pointers about how
> this .nfsXXXX files handle by the NFS server. 

As far as the NFS server is concerned, this is a file just like any
other. The server attaches no special meaning to it.

Trond


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Move .nfsXXXX files
  2007-01-31 13:33 Move .nfsXXXX files Trinabh Shukla
  2007-02-01  3:42 ` Trond Myklebust
@ 2007-02-05 17:51 ` Suresh Jayaraman
  1 sibling, 0 replies; 3+ messages in thread
From: Suresh Jayaraman @ 2007-02-05 17:51 UTC (permalink / raw)
  To: Trinabh Shukla, nfs

>On January 31, 2007 at 7:03 PM, "Trinabh Shukla" <trinabh@gmail.com> wrote:

> The .nfsXXXX file get created when I remove a file while it's being kept
> open by one of the process. Due to this I can't remove directory which hold
> this file. So I want to move this .nfsXXXX file on different temp directory
> on the same nfs file system and delete that directory. Here it's working
> properly.
>
> But let me know that is it a correct solution? And removal of .nfs files
> does not cause the server serious integrity.
 
If you're not bothered about the process which has that file open,
better kill the process. Moving to temp dir has problems as Trond 
mentioned, even if sticky bit(chmod 777+t) is set for the temp dir.

> Also it will be good, if you lead some pointers about how this .nfsXXXX
> files handle by the NFS server.

As the server has no clue of file opens, it cannot implement "delete on 
last close". Also, there is a possibility that client could crash or 
neglect to remove the hidden files. So server may want to cleanup
these files periodically. Some servers (eg. Solaris servers) have a cron 
script which searches exported filesystem for these files that
haven't not been accessed for a while and deletes them.

Thanks,
Suresh


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-02-05 17:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-31 13:33 Move .nfsXXXX files Trinabh Shukla
2007-02-01  3:42 ` Trond Myklebust
2007-02-05 17:51 ` Suresh Jayaraman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.