| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ok, here's the fix for the write times breakage
with the new tests in S4 smbtorture.
The key is keeping in the share mode struct
the "old_file_time" as the real write time,
set by all the write and allocation calls,
and the "changed_write_time" as the "sticky"
write time - set by the SET_FILE_TIME calls.
We can set them independently (although I
kept the optimization of not setting the
"old_file_time" is a "changed_write_time"
was already set, as we'll never see it.
This allows us to update the write time
immediately on the SMBwrite truncate case,
SET_END_OF_FILE and SET_ALLOCATION_SIZE calls,
whilst still have the 2 second delay on the
"normal" SMBwrite, SMBwriteX calls.
I think in a subsequent patch I'd like to
change the name of these from "old_file_time"
to "write_time" and "changed_write_time" to
"sticky_write_time" to make this clearer.
I think I also fixed a bug in Metze's original
code in that once a write timestamp had been
set from a "normal" SMBwriteX call the fsp->update_write_time_triggered
variable was set and then never reset - thus
meaning the write timestamp would never get
updated again on subsequent SMBwriteX's.
The new code checks the update_write_time_event
event instead, and doesn't update is there's
an event already scheduled.
Metze especially, please check this over for
your understanding.
Jeremy.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We now never call file_ntimes() directly, every update
is done via smb_set_file_time().
This let samba3 pass the BASE-DELAYWRITE test.
The write time is only updated 2 seconds after the
first write() on any open handle to the current time
(not the time of the first write).
Each handle which had write requests updates the write
time to the current time on close().
If the write time is set explicit via setfileinfo or setpathinfo
the write time is visible directly and a following close
on the same handle doesn't update the write time.
metze
|
|
|
|
| |
Jeremy.
|
|
|
|
|
| |
Dos mode calculation was masking out FILE_ATTRIBUTE_OFFLINE so that code to set file offline
was never called before. Merge from Tridge's v3-0-ctdb git tree.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
result for a file.
This makes sense as upper levels are only taking returned result of 0
(no error) into consideration when deciding whether to mark file
offline/online as returned from is_offline.
That means that we simply can move the decision down to VFS module and
clean up upper levels so that they always see only file status. If there
is an error when trying to identify file status, then VFS module could
decide what to return (offline or online) by itself -- after all, it
ought to have system-specific knowledge anyway.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
operations to VFS
Offline files support and remote storage are for allowing communication with
backup and archiving tools that mark files moved to a tape library as offline.
We translate this info into corresponding CIFS offline file attribute and
mark an exported volume as remote storage.
Async I/O force is to allow selective redirection of I/O operations to asynchronous
processing in case it is viable at VFS module discretion. It is needed for
proper handling of offline files as performing regular I/O on offline file will
block smbd.
Signed-off-by: Alexander Bokovoy <ab@samba.org>
|
|
|
|
| |
Michael
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes a make test failure on Solaris. When creating a new file,
file_set_dosmode() called from open_file_ntcreate calculates a new permission
mask, very likely different from what had been calculated in
open_file_ntcreate. Further down we overwrote the newly calculated value with
SMB_FCHMOD_ACL, ignoring what file_set_dosmode had calculated.
Why did Linux not see this? fchmod_acl on a newly created file without acls
would not retrieve an acl at all, whereas under Solaris acl(2) returns
something even for files with just posix permissions returns something.
Jeremy, given that we have very similar code in 3.0.28 this might also explain
some of the bug reports that people have concerning ACLs on new files.
Volker
P.S: This one took a while to find...
|
|
|
|
|
|
| |
message accordingly. Apart from not supporting create time we
now pass the S4 RAW-NOTIFY torture.
Jeremy.
|
|
|
|
|
|
|
| |
False instead of NULL. Fix more of the notifications to
be correct for Samba4 RAW-NOTIFY torture (we had missed
one when calling set_ea_dos_attribute().
Jeremy.
|
|
|
|
|
|
|
| |
bugs in various places whilst doing this (places that assumed
BOOL == int). I also need to fix the Samba4 pidl generation
(next checkin).
Jeremy.
|
| |
|
|
|
|
| |
Jeremy.
|
|
|
|
|
|
|
|
|
|
| |
for utimes - change the call to ntimes. This preserves
nsec timestamps we get from stat (if the system supports
it) and only maps back down to usec or sec resolution
on time set. Looks bigger than it is as I had to move
lots of internal code from using time_t and struct utimebuf
to struct timespec.
Jeremy.
|
| |
|
|
|
|
|
|
|
|
| |
make sense
again :-)
Volker
|
|
|
|
|
|
|
| |
The only difference between the two trees now w.r.t file
serving are the changes to smbd/open.c in this branch I need
to review.
Jeremy.
|
|
|
|
|
|
|
|
|
| |
starts to make
sense. Until then, remove it from the tree to keep the diff between 3_0_24 and
3_0 small.
Volker
|
| |
|
|
|
|
|
|
|
| |
This involved passing the dirname as argument to a few routines instead of
calling parent_dirname() deep down.
Volker
|
|
|
|
|
|
|
| |
to do the upper layer directories but this is what
everyone is waiting for....
Jeremy.
|
|
|
|
|
|
| |
read ea's from an msdfs link. Stop it from doing that.
Jerry please merge to 3.0.23.
Jeremy.
|
|
|
|
|
|
| |
a valid return from getting an xattr. Don't disable if
we get it.
Jeremy.
|
|
|
|
| |
HSM is interested in. Tested on both IRIX and SLES9.
|
|
|
|
|
| |
to the attr list not resetting it.
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
|
|
|
|
|
|
|
| |
added new parameter : map readonly = [yes|no|permissions]
If yes: map inverse of user "w" bit to mean readonly.
If no: never set DOS readonly bit.
If permissions: check file permissions for user and set readonly
bit if the current user cannot write.
If store dos attributes is set to yes then this parameter
is ignored.
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
|
| |
read-only. Noticed by Andrew Bartlett.
Jeremy
|
|
|
|
|
| |
when DOS attributes are stored in EA's.
Jeremy.
|
|
|
|
|
|
|
|
| |
Don't update the time on read-only shares.
We need this as set_filetime (which can be called on
close and other paths) can end up calling this function
without the NEED_WRITE protection.
Jeremy.
|
|
|
|
|
|
|
|
|
| |
tests on this as it's very late NY time (just wanted to get this work
into the tree). I'll test this over the weekend....
Jerry - in looking at the difference between the two trees there
seem to be some printing/ntprinting.c and registry changes we might
want to examine to try keep in sync.
Jeremy.
|
|
|
|
|
| |
Fixes bug #2774.
Jeremy.
|
|
|
|
|
|
|
|
| |
checking for write access in a directory before delete. Also
controls checking for write access before labeling a file read-only
if DOS attributes are not being stored in EA's.
Docuementation to follow.
Jeremy.
|
|
|
|
|
|
|
| |
"read-only"
issue.
Jeremy.
|
|
|
|
|
| |
not an existing one.
Jeremy.
|
|
|
|
|
|
| |
Rolling back r3496 (close #2015).
Guenther
|
|
|
|
| |
Guenther
|
|
|
|
|
|
|
|
| |
st_blksize, it isn't what you think....
Jeremy.
--his line, and those below, will be ignored--
M source/smbd/dosmode.c
|
|
|
|
|
| |
doesn't support EA's.
Jeremy.
|
|
|
|
|
|
| |
dos attributes in an EA. Based on an original patch from tridge, but
modified somewhat to cover all cases.
Jeremy.
|
|
|
|
| |
Jeremy
|
|
|
|
|
|
| |
"hidden" dot files.
Jeremy.
|
|
|
|
|
| |
if the file has an ACL.
Jeremy.
|
|
|
|
|
|
|
| |
#ifdef HAVE_STAT_ST_BLKSIZE and #ifdef HAVE_STAT_ST_BLOCKS,
respectively.
Fixes bug 550 reported by Joachim Schmitz <schmitz@hp.com>.
|
|
|
|
| |
VFS_ macros at system side. We currently have one clash with AIX and its VFS_LOCK. Compiled and tested -- no new functionality or code, just plain rename of macros for yet-unreleased VFS API version. Needs to be done before a24 is out
|
|
|
|
|
|
|
|
|
| |
1. Finally work with cascaded modules with private data storage per module
2. Convert VFS API to macro calls to simplify cascading
3. Add quota support to VFS layer (prepare to NT quota support)
Patch by Stefan (metze) Metzemacher, with review of Jelmer and me
Tested in past few weeks. Documentation to new VFS API for third-party developers to follow
|
|
|
|
| |
Andrew Bartlett
|
| |
|