1RFIO_CHOWN(3) Rfio Library Functions
2RFIO_CHOWN(3)
3
4
5
6[1mNAME[0m
7 rfio_chown ‐ change owner and group of a directory/file
8
9[1mSYNOPSIS[0m
10 [1m#include <sys/types.h>[0m
11 [1m#include "rfio_api.h"[0m
12
13 [1mint rfio_chown (const char *[4m[22mpath[24m[1m, uid_t
14[4m[22mnew_uid[24m[1m, gid_t [4m[22mnew_gid[24m[1m)[0m
15
16[1mDESCRIPTION[0m
17 [1mrfio_chown [22msets the owner and the group of a
18directory/file to the
19 numeric values in [4mowner[24m and [4mgroup[24m respec‐
20tively. If [4mowner[24m or [4mgroup[24m is
21 specified as ‐1, [1mrfio_chown() [22mdoes not change the
22corresponding ID of
23 the file.
24
25 [4mpath[24m specifies the logical pathname relative to
26the current directory
27 or the full pathname.
28
29 The effective user ID of the process must match the own‐
30er of the file
31 or be super‐user.
32
33[1mRETURN VALUE[0m
34 This routine returns 0 if the operation was successful or
35‐1 if the
36 operation failed. In the latter case, [1mserrno [22mis set
37appropriately.
38
39[1mERRORS[0m
40 [1mEPERM [22mThe effective user ID does not match
41the owner of the file
42 and is not super‐user.
43
44 [1mENOENT [22mThe named file/directory does not ex‐
45ist or is a null path‐
46 name.
47
48 [1mEACCES [22mSearch permission is denied on a
49component of the [4mpath[0m
50 prefix or write permission on the file itself
51is denied.
52
53 [1mEFAULT [4m[22mpath[24m is a NULL pointer.
54
55 [1mENOTDIR [22mA component of [4mpath[24m prefix is
56not a directory.
57
58 [1mEINVAL [4m[22mnew_uid[24m or [4mnew_gid[24m is
59invalid.
60
61 [1mENAMETOOLONG [22mThe length of [4mpath[24m exceeds
62[1mCA_MAXPATHLEN [22mor the length of
63 a [4mpath[24m component exceeds [1mCA_MAX‐
64NAMELEN[22m.
65
66 [1mSENOSHOST [22mHost unknown.
67
68 [1mSENOSSERV [22mService unknown.
69
70 [1mSETIMEDOUT [22mTimed out.
71
72 [1mSECONNDROP [22mConnection closed by remote end.
73
74 [1mSECOMERR [22mCommunication error.
75
76[1mSEE ALSO[0m
77 [1mCastor_limits(4)[0m
78
79[1mAUTHOR[0m
80 [1mLCG Grid Deployment [22mTeam
81
82
83
84LCG $Date: 2005/03/31 13:13:02 $
85RFIO_CHOWN(3)
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132