Skip to contentSkip to conversation

3-word attributes encoding

DISCUSSION Benny Halevy 2 participants 6 messages Mar 30, 2009 – Apr 1, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Let me know what you think...

Other than that,
git://linux-nfs.org/~bhalevy/linux-pnfs.git nfsd41-for-2.6.30 holds version 3 of the nfsd41 patchset, rebased onto your update for-2.6.30 branch, and with these cleanup patches squashed-in:

[PATCH 1/3] SQUASHME: get callback minorversion from fore channel's [PATCH 2/3] SQUASHME: nfsd41: use nfsd4_cb_sequence for callback minorversion [PATCH 3/3] SQUASHME: Revert "sunrpc: add cl_private field to struct rpc_clnt"

Benny

#1 lore raw
Quoted 10 lines · Benny Halevy

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

"suboptimal" means it does some extra memcpy'ing?

Quoted 4 lines

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Odd thing to have to do, but OK. --b.

Quoted 17 lines

Let me know what you think...

Other than that,
git://linux-nfs.org/~bhalevy/linux-pnfs.git nfsd41-for-2.6.30 holds version 3 of the nfsd41 patchset, rebased onto your update for-2.6.30 branch, and with these cleanup patches squashed-in:

[PATCH 1/3] SQUASHME: get callback minorversion from fore channel's [PATCH 2/3] SQUASHME: nfsd41: use nfsd4_cb_sequence for callback minorversion [PATCH 3/3] SQUASHME: Revert "sunrpc: add cl_private field to struct rpc_clnt"

Benny
_______________________________________________
pNFS mailing list
[email protected]
http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs

#2 lore raw
Quoted 12 lines · J. Bruce Fields
Quoted 10 lines · Benny Halevy

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

Quoted 1 line

"suboptimal" means it does some extra memcpy'ing?

Yes, I believe so.

Quoted 7 lines
Quoted 5 lines

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Odd thing to have to do, but OK. --b.

What would you prefer to do?
Revert to old behavior by returning at least two bitmap words or use the args bitmap length for encoding the res?

Benny

Quoted 17 lines
Quoted 17 lines

Let me know what you think...

Other than that,
git://linux-nfs.org/~bhalevy/linux-pnfs.git nfsd41-for-2.6.30 holds version 3 of the nfsd41 patchset, rebased onto your update for-2.6.30 branch, and with these cleanup patches squashed-in:

[PATCH 1/3] SQUASHME: get callback minorversion from fore channel's [PATCH 2/3] SQUASHME: nfsd41: use nfsd4_cb_sequence for callback minorversion [PATCH 3/3] SQUASHME: Revert "sunrpc: add cl_private field to struct rpc_clnt"

Benny
_______________________________________________
pNFS mailing list
[email protected]
http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs

#3 lore raw
Quoted 23 lines · Benny Halevy
Quoted 12 lines · J. Bruce Fields
Quoted 10 lines · Benny Halevy

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

Quoted 1 line

"suboptimal" means it does some extra memcpy'ing?

Yes, I believe so.

Quoted 6 lines
Quoted 5 lines

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Quoted 5 lines
Quoted 1 line

Odd thing to have to do, but OK. --b.

What would you prefer to do?
Revert to old behavior by returning at least two bitmap words or use the args bitmap length for encoding the res?

Whichever requires the least code? I don't know.

If the client really needs this, then it needs to be agreed on by more than just the linux server. It's unfortunate if making this arbitrary undocumented choice of result encoding makes a significant difference to the client's performance.

--b.

#4 lore raw
Quoted 20 lines · J. Bruce Fields
Quoted 19 lines · Benny Halevy
Quoted 11 lines · J. Bruce Fields
Quoted 10 lines · Benny Halevy

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

Quoted 1 line

"suboptimal" means it does some extra memcpy'ing?

Yes, I believe so.

Quoted 4 lines
Quoted 4 lines

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Quoted 6 lines
Quoted 4 lines
Quoted 1 line

Odd thing to have to do, but OK. --b.

What would you prefer to do?
Revert to old behavior by returning at least two bitmap words or use the args bitmap length for encoding the res?

Whichever requires the least code? I don't know.

The former seems simpler to code.

Quoted 5 lines

If the client really needs this, then it needs to be agreed on by more than just the linux server. It's unfortunate if making this arbitrary undocumented choice of result encoding makes a significant difference to the client's performance.

I think that currently it affects only getacl and I have no measurements of to what extent the effect of performance is.

Benny

Quoted 2 lines

--b.

#5 lore raw
Quoted 31 lines · Benny Halevy
Quoted 20 lines · J. Bruce Fields
Quoted 19 lines · Benny Halevy
Quoted 11 lines · J. Bruce Fields
Quoted 10 lines · Benny Halevy

Bruce,

As I mentioned in a reply to Trond,
"nfsd41: support for 3-word long attribute bitmask" changes the server fattr encoding logic so it may send back a bitmap of length 1, even if the client sent a bitmap of length 2, if the second word of the bitmap is zero. Although I think this a valid implementation and other servers may do the same, it seems sub-optimal for the client's decoding of acl of fs_locations.

Quoted 1 line

"suboptimal" means it does some extra memcpy'ing?

Yes, I believe so.

Quoted 4 lines
Quoted 4 lines

It's pretty easy to revert to the old behavior on the server by always returning at least two bitmap words, or, if we keep the bitmap length, not just the val, in nfsd4_decode_bitmap we can return a bitmap of the same length in the reply.

Quoted 6 lines
Quoted 4 lines
Quoted 1 line

Odd thing to have to do, but OK. --b.

What would you prefer to do?
Revert to old behavior by returning at least two bitmap words or use the args bitmap length for encoding the res?

Whichever requires the least code? I don't know.

The former seems simpler to code.

Quoted 1 line
Quoted 7 lines
Quoted 4 lines

If the client really needs this, then it needs to be agreed on by more than just the linux server. It's unfortunate if making this arbitrary undocumented choice of result encoding makes a significant difference to the client's performance.

I think that currently it affects only getacl and I have no measurements of to what extent the effect of performance is.

I'd rather just not worry about it. If it turns out to be a problem then we can try to figure out a less fragile solution.

--b.