Bug 44951 - renaming socket in use does not update /proc/X/fd
Summary: renaming socket in use does not update /proc/X/fd
Status: RESOLVED WILL_NOT_FIX
Alias: None
Product: File System
Classification: Unclassified
Component: ext4 (show other bugs)
Hardware: All Linux
: P1 low
Assignee: fs_ext4@kernel-bugs.osdl.org
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-20 13:23 UTC by Wolfgang Rohdewald
Modified: 2012-08-30 17:09 UTC (History)
3 users (show)

See Also:
Kernel Version: 3.2.0-26 ubuntu
Subsystem:
Regression: No
Bisected commit-id:


Attachments

Description Wolfgang Rohdewald 2012-07-20 13:23:19 UTC
normally, renaming a file in use updates its name in /proc/X/fd

but this does not work for sockets. And so fuser fails to tell me
about the process using the socket when renamed.

using ext4 of course

i5:~/.kajonggserver$ fuser socket
/home/wr/.kajonggserver/socket: 27557
i5:~/.kajonggserver$ l /proc/27557/fd/3
lrwx------ 1 wr wr 64 Jul 18 22:00 /proc/27557/fd/3 -> socket:[1344224]
i5:~/.kajonggserver$ mv socket X
i5:~/.kajonggserver$ fuser X
i5:[Exit 1 (SIGHUP)]~/.kajonggserver$ l /proc/27557/fd/3
lrwx------ 1 wr wr 64 Jul 18 22:00 /proc/27557/fd/3 -> socket:[1344224]


Linux i5 3.2.0-26-generic #41-Ubuntu SMP Thu Jun 14 17:49:24 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
Comment 1 Eric Sandeen 2012-07-20 16:08:01 UTC
(In reply to comment #0)

> using ext4 of course

I doubt that this is unique to ext4, is it?
Comment 2 Wolfgang Rohdewald 2012-07-20 16:50:40 UTC
I also have one ext3 - and yes, ext3 behaves the same way.
Comment 3 Alan 2012-08-30 17:09:31 UTC
Sockets live in their own namespace - the path to it is just a reference to the object.

Note You need to log in before you can comment on or make changes to this bug.