HP scanner needs smaller SMB2 rwsize
Multiple reports of HP scanners or all-in-ones that "scan to network disk" seem to fail with recent illumos builds.
This email thread details the symptoms, and a workaround using kmdb or /etc/system: https://illumos.topicbox.com/groups/developer/Tb306d72d143674f7-M22f50ecc1f5f7fe5a3c9c052
Updated by Gordon Ross about 1 year ago
The max r/w size we report apparently confuses the (lame) scanner client
into trying to send writes larger than will fit in a NetBIOS frame.
I'd suggest, in smb2_negotiate_common, instead of directly using
smb2_max_rwsize, conditionally use a smaller value, i.e.
perhaps something like:
uint32_t max_rwsize; /* * Some older clients are confused by large max_rwsize, * so if no CAP_LARGE_MTU lower it to 64k. */ max_rwsize = smb2_max_rwsize; if ((s->capabilities & SMB2_CAP_LARGE_MTU) == 0) max_rwsize = (1 << 16);
Then use max_rwsize in the smb_mbc_encodef call.
Updated by Electric Monk about 1 year ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit aa321b3cd36298fca4306c4e06284d250e998cf7 Author: Dan McDonald <email@example.com> Date: 2018-05-01T18:39:17.000Z 9500 HP scanner needs smaller SMB2 rwsize Reviewed by: Yuri Pankov <firstname.lastname@example.org> Reviewed by: Andy Fiddaman <email@example.com> Reviewed by: Bill Sommerfeld <firstname.lastname@example.org> Reviewed by: Toomas Soome <email@example.com> Approved by: Gordon Ross <firstname.lastname@example.org>