exception - 阅读时的 mv()

标签 exception interrupt

在 Linux ext3 文件系统上,如果在读取文件时对同一个文件(文件描述符)调用 mv() 会发生什么情况?这实际上是一道考试题,我只能说:

  1. CPU 捕获操作系统进行中断处理
  2. 等等,等等

如果操作系统人员可以帮助我,我将不胜感激:D

最佳答案

Linux rename man page:

这解释了大部分细节。

If one or more processes have the file open when the last link is removed,
the link shall be removed before rename() returns, but the removal of the
file contents shall be postponed until all references to the file are closed. 

关于exception - 阅读时的 mv(),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2837135/

相关文章:

c - TCP 套接字,服务器无法响应客户端,接受 : Interrupted system call

linux - 内核如何通知用户空间程序中断发生

c# - 重新抛出无参数 catch 和什么都不做的区别?

java - Kryo 崩溃 EnvironmentFailureException

python - 返回多个值的 cdef 函数的 Cython 异常传播

linux - 如果在执行系统调用时硬件定时器中断触发,会发生什么情况?

c - 如何使用 LKM Hook 中断门

C++ : calling BIOS interrupt 0x21

java - Java EE 项目的异常处理架构

python - 打印完整异常