From: Jeremy Allison <jra-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
To: Steve French <smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Jeremy Allison <jra-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>,
samba-technical
<samba-technical-w/Ol4Ecudpl8XjKLYN78aQ@public.gmane.org>,
"linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: setting allocation size in cifs/smb3
Date: Mon, 21 Jul 2014 11:55:28 -0700 [thread overview]
Message-ID: <20140721185528.GD29893@samba2> (raw)
In-Reply-To: <CAH2r5mtLO9jwBx+EumbXzEjiprPMVvnz39CsZJsEm3dAraDDZQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
On Mon, Jul 21, 2014 at 01:43:12PM -0500, Steve French wrote:
> What about shrinking the file to the wrong size?
In the set allocation path info it's going through:
if (allocation_size) {
allocation_size = smb_roundup(conn, allocation_size);
}
which by default uses 1MB allocation roundup values.
If you need to set the file length, set the file length :-).
It's arguable if the server can mess with allocation
requests on file shrink, but this hasn't caused a
problem in the SMB1/Windows SMB2 code paths so far,
so I'm guessing it might be allowable....
More research needed !
next prev parent reply other threads:[~2014-07-21 18:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-18 6:15 setting allocation size in cifs/smb3 Steve French
2014-07-18 17:09 ` Jeremy Allison
2014-07-19 4:49 ` Steve French
[not found] ` <CAH2r5mubvLEd7QFY8p-YSCojPPdwzQMXK_Ka6k7V0uKRgUeeaw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-07-19 5:14 ` Jeremy Allison
2014-07-21 4:47 ` Steve French
[not found] ` <CAH2r5mvSEYbGxE166W2GijnhKj4hVcVzhVLJQQeQeWejk4AoaQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-07-21 18:28 ` Jeremy Allison
2014-07-21 18:43 ` Steve French
[not found] ` <CAH2r5mtLO9jwBx+EumbXzEjiprPMVvnz39CsZJsEm3dAraDDZQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-07-21 18:55 ` Jeremy Allison [this message]
2014-07-21 19:27 ` Steve French
[not found] ` <CAH2r5msV39xCYsK9Ru=zaJadv5-fKa5-DHwUO7wPt+E55k0vMQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-07-21 19:41 ` Steve French
[not found] ` <CAH2r5msy4OWaJfAKUrc0Tzx73dsb0zx6fU1wAejKsksq1V8gdA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-07-23 0:07 ` Jeremy Allison
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140721185528.GD29893@samba2 \
--to=jra-eunubhrolfbytjvyw6ydsg@public.gmane.org \
--cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=samba-technical-w/Ol4Ecudpl8XjKLYN78aQ@public.gmane.org \
--cc=smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox