shmget with SHM_HUGETLB flag: Operation not permitted
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 1 line · Chris Wright
did you try setpcaps? smth like setpcaps cap_ipc_lock+e <pid>
Ok. One step further now. The syntax seems correct now. I tried to grant capabilities to the user's shell:
roesrv01~ # setpcaps cap_ipc_lock+e 2864
[caps set to:
= cap_ipc_lock+e
]
Failed to set cap's on process `2864': (Operation not permitted)
and with the setcap tool again:
roesrv01~ # setcap cap_ipc_lock+e a.out
Failed to set capabilities on file `a.out'
(Function not implemented)
Hmmm. What do we do now?
Quoted 3 lines
Quoted 1 line
Are you sure that this capability is my problem?
Yes, take a look at fs/hugetlbfs/inode.c::hugetlb_zero_setup()
Ok, this would explain it. But what role plays the pseudo-filesystem in this case? I don't have it mounted. Isn't it only needed when using mmap, not shmget? I guess, I have a serious lack of knownledge here.
Quoted 8 lines · Jochen Roemling
Ok. One step further now. The syntax seems correct now. I tried to grant capabilities to the user's shell:
roesrv01~ # setpcaps cap_ipc_lock+e 2864
[caps set to:
= cap_ipc_lock+e
]
Failed to set cap's on process `2864': (Operation not permitted) and with the setcap tool again:
This is likely due to not having the capability to grant in the granting process. Things are supposed to be vauely montonic here.
Quoted 4 lines · Jochen Roemling
roesrv01~ # setcap cap_ipc_lock+e a.out
Failed to set capabilities on file `a.out'
(Function not implemented)
Hmmm. What do we do now?
setcap on executables probably isn't supported by your fs.
-- wli