5485 Commits

Author SHA1 Message Date
Jeffrey Altman
ce4182ecdc DEVEL15-windows-multi-check-server-20080911
LICENSE MIT

Permit rx_multi check server to be toggled via a registry setting
at checked prior to each invocation.  "MultiCheckServers".
Default is on.

Remove volume status updates for vldb server status changes.


(cherry picked from commit 59c1c22747b8aaf1da31f97d8a3ea178a4f7adee)
2008-09-11 17:52:45 +00:00
Derrick Brashear
8d559e7c2d DEVEL15-aix-export-build-fix-20080906
LICENSE IPL10

add missing ; to case actions


(cherry picked from commit f51e8e7be5b16f84f0603a0e8bc1be4ffafac617)
2008-09-06 12:59:13 +00:00
Derrick Brashear
e953e14e5c DEVEL15-syncserv-syncvldb-manpages-dryrun-20080906
LICENSE IPL10

make syncserv and syncvldb manpages reflect dryrun option


(cherry picked from commit 4119d9742b3e17fac6a3f1f7ab64ec829f085498)
2008-09-06 12:51:27 +00:00
Jeffrey Altman
b10d91c48c DEVEL15-windows-vnovol-20080905
LICENSE MIT

force a volume location update upon receipt of a VNOVOL error
in case the volume was moved.  VMOVED is only returned by the file
server if the volume is in the process of being moved.  Once it has
been deleted the file server returns VNOVOL.


(cherry picked from commit 0860d5b5b17ef5f58592d739424a4cca8dd91bb5)
2008-09-06 05:25:59 +00:00
Derrick Brashear
0984dae857 DEVEL15-fileserver-sticky-bit-admin-only-20080905
LICENSE IPL10

do restrict the sticky bit to admins.


(cherry picked from commit 5c2406070fc08c5fee0a09a1aa25e16af123b81a)
2008-09-05 17:57:55 +00:00
Jeffrey Altman
4c48c08641 DEVEL15-windows-smb-volname-20080904
LICENSE MIT

Advertise the correct length for the volume name.  Do not include the NUL.

Add more create option values as #defines.


(cherry picked from commit beef54e70cc86672b9971288fe4034829186aa41)
2008-09-04 21:09:13 +00:00
Derrick Brashear
be4cac8fab DEVEL15-fileserver-sticky-bit-not-admin-only-20080904
LICENSE IPL10

don't restrict the sticky bit to admins.


(cherry picked from commit 9689e78d716422970a0ae3ad89d36acaa517072e)
2008-09-04 20:41:26 +00:00
Jeffrey Altman
71580c6b52 DEVEL15-windows-cell-locking-20080903
LICENSE MIT

fix a lock order issue and protect the timeout and flags field
of cm_cell_t with the mutex instead of the global lock.


(cherry picked from commit bbd713ad3f403c9137e01797f576f5dbd04a0f08)
2008-09-03 22:04:51 +00:00
Jeffrey Altman
9ac229a2c1 DEVEL15-windows-smb-lock-order-20080903
LICENSE MIT

another lock order violation to fix


(cherry picked from commit 441cc643e027ab98ed14ab486ec077bbbd0c0d4f)
2008-09-03 21:41:04 +00:00
Derrick Brashear
d0efb7b830 DEVEL15-aix61-old-build-system-20080903
LICENSE IPL10

massage in support for pinstall
2008-09-03 20:35:32 +00:00
Niklas Edmundsson
bfd956832e DEVEL15-aix61-initial-support-20080903
LICENSE IPL10
FIXES 113638

aix 6.1 support


(cherry picked from commit 539535cf679d6e70f34b80b74c127efae1f0bba2)
2008-09-03 19:27:02 +00:00
Jeffrey Altman
ca42b6a490 DEVEL15-rx-mutex-init-once-20080903
LICENSE IPL10
FIXES 114555

because rx_Finalize doesn't clean up, we end up reiniting mutexes. use
pthread_once when not in the kernel.
(kernel does not now call rx_Finalize, ever)


(cherry picked from commit 7f4e0dfc3ef1464c8d8b422bf00915fa4538090c)
2008-09-03 19:07:23 +00:00
Derrick Brashear
9735e4c0ed DEVEL15-linux26-libafs-makefileproto-trust-kbuild-system-no-really-20080903
LICENSE IPL10

if we are really not using COMMON_KERN_CFLAGS and being trusting, let's do so.


(cherry picked from commit 995ee981fd2631d6e1e45311cee0a6d58f4a56be)
2008-09-03 17:59:18 +00:00
Jeffrey Altman
96c35b1438 DEVEL15-windows-afsd-dns-env-20080902
LICENSE MIT

Fix the conditionals so that the right thing happens if AFS_AFSDB_ENV
is not defined.


(cherry picked from commit 9803e84e63c28e87c76e6f4e77343fec4ef4dcf4)
2008-09-02 23:35:36 +00:00
Jeffrey Altman
b7d1451499 DEVEL15-windows-fs-setcrypt-auth-20080902
LICENSE MIT

fix parsing and display of fs setcrypt auth


(cherry picked from commit 8bf17e7c813f9b2aa8a953a8d0251322ee970d2c)
2008-09-02 22:25:55 +00:00
Jeffrey Altman
e422b9f856 DEVEL15-smb-string-conversion-20080902
LICENSE MIT

more cases where -1 should be passed in as opposed to the strlen value
when converting between char and wchar forms


(cherry picked from commit 84e10d582abdf65a5354b1c4b41d7e2ecad532f8)
2008-09-02 22:21:34 +00:00
Jeffrey Altman
32dbc21151 DEVEL15-windows-rxkad-auth-20080902
LICENSE MIT

Add ability for users to select rxkad auth only mode.
"fs setcrypt auth".


(cherry picked from commit d94b9a78188357f87fa569ec7738d4e69ff05faa)
2008-09-02 22:16:18 +00:00
Jeffrey Altman
21e93f71f5 DEVEL15-windows-afsd-init-20080902
LICENSE MIT

report state of "Rx Jumbo" and "RxExtraPackets" more often


(cherry picked from commit 21abc0e0b51cd3fd014b06b187d497996058ffe4)
2008-09-02 22:09:13 +00:00
Jeffrey Altman
c80205990c DEVEL15-windows-cell-free-list-20080902
LICENSE MIT

add a free list to the cm_cell_t structure.  if during cm_GetCellGen()
the cm_SearchCellXXX() calls fail, store the allocated cm_cell_t object
on a free list so that it can be reused for the next request.


(cherry picked from commit e31826d3331b8eb1893c627ac55eb299df88995b)
2008-09-02 21:18:33 +00:00
Jeffrey Altman
afbf3a15e3 DEVEL15-windows-cell-alloc-reversed-20080902
LICENSE MIT

The approach taken in windows-cell-alloc-20080902 won't work.


(cherry picked from commit 829ff4e54f055de1dc26a1508d2abf4a3c72ff75)
2008-09-02 17:34:41 +00:00
Jeffrey Altman
8116694a08 DEVEL15-windows-cell-alloc-20080902
LICENSE MIT

Perform the initial cm_SearchCellXXX call using a temporary cm_cell_t
object in case the search fails.


(cherry picked from commit ef64f50fb9f477a0acbe1223ee2b0c9981f9324e)
2008-09-02 16:21:39 +00:00
Jeffrey Altman
7fe8eddfc0 DEVEL15-windows-smb-free-lsa-response-20080901
LICENSE MIT

Whether or not LsaCallAuthenticationPackage succeeds, it may return
a response buffer.  If it does, free it.


(cherry picked from commit a653057ff453a0d340c8153615aa44ae1679c892)
2008-09-01 13:39:39 +00:00
Jeffrey Altman
b13a77c357 DEVEL15-windows-afsd-init-lock-order-validation-20080830
LICENSE MIT

Add TransarcAFSDaemon/Parameters key "LockOrderValidation" DWORD
to control lock order validation functionality.  Defaults to off
for release builds and on for checked builds.


(cherry picked from commit 83dadab93adde0812f9ae228667683cfcc761f67)
2008-08-30 15:14:43 +00:00
Jeffrey Altman
a44537d8c7 DEVEL15-windows-lock-order-validation-20080830
LICENSE MIT

Add osi_SetLockOrderValidation(int) to permit lock order validation
to be turned on and off.  Must be executed before the first lock
is obtained.


(cherry picked from commit a36596f10ff4d87d75a808cabe4e0e5ec661c5df)
2008-08-30 15:05:14 +00:00
Jeffrey Altman
41695e42e8 DEVEL15-windows-buf-shutdown-20080829
LICENSE MIT

During buf_Shutdown() all dirty buffers should be written to the file
server if they can be.


(cherry picked from commit ccdf50ade371de595abe20f5a6b0ff149ce9ae79)
2008-08-30 03:15:07 +00:00
Jeffrey Altman
665f1b9a01 DEVEL15-windows-afsd-shutdown-20080829
LICENSE MIT

reorganize the service shutdown order to permit dirty buffers to be
flushed to the file server without competition from incoming requests.


(cherry picked from commit 2da64d02a2707a3c9220951a30b5cea8464b9ef9)
2008-08-30 03:06:28 +00:00
Jeffrey Altman
54a0f07111 DEVEL15-windows-check-servers-20080828
LICENSE MIT

if the server count is zero, don't both trying


(cherry picked from commit 00fee5efee68f1647fa810dffa7ad991235d01c5)
2008-08-28 10:47:41 +00:00
Jeffrey Altman
64b8b64495 DEVEL15-windows-check-server-heap-overwrite2-20080827
LICENSE MIT

the incorporation of nconns into the foo incremental was a mistake


(cherry picked from commit 43eb87a916b87c6037841ea38cde616014d892a8)
2008-08-28 00:44:03 +00:00
Jeffrey Altman
60a3670e19 DEVEL15-windows-check-server-heap-overwrite-20080827
LICENSE MIT

Protect against a heap overwrite that could occur is the number of file
servers or vldb servers grows while the maximum number of connections
is computed and when the connection list is populated.


(cherry picked from commit e68255c12c444e36b7ca7f1864d964cd3a0bcda8)
2008-08-27 23:09:56 +00:00
Jeffrey Altman
c96303577a DEVEL15-windows-callback-lock-order-20080827
LICENSE MIT

do not hold cm_server_t mutex when calling cm_FindVolumeByID because
the cm_volume_t lock must be obtained ahead of the cm_server_t mutex


(cherry picked from commit 0affa4b86a08c3be9cb4edc4c9f680ae02a2fcd8)
2008-08-27 23:03:19 +00:00
Jeffrey Altman
d090881286 DEVEL15-windows-lock-order-20080827
LICENSE MIT

do not hold cm_scacheLock while obtaining cm_scache_t->rw


(cherry picked from commit c50857b05e6636bef864c9418b21d1bf3c63494a)
2008-08-27 13:18:04 +00:00
Jeffrey Altman
32ad8285cd DEVEL15-windows-short-names-20080827
LICENSE MIT

plus and equal are not valid characters in short names.
we replace them with left and right brace in order to
minimize the instability in the file names.


(cherry picked from commit bef68684fd7bb4e58e621766a0f2abbdfd15af80)
2008-08-27 12:49:20 +00:00
Matt Benjamin
8703e7f1a5 DEVEL15-freebsd-70-client-20080826
LICENSE IPL10

FreeBSD 7.0 client support (and 8.0 support but that's a moving target)


(cherry picked from commit a123bd8ccde0d6baf04401201b1672b19e9778db)
2008-08-26 15:59:52 +00:00
Tom Keiser
be677d800b DEVEL15-studio12-solaris-updates-20080826
LICENSE IPL10
FIXES 113671

update so we build with studio 12 on solaris


(cherry picked from commit 4d245c6a19394d54a241bd612016b10d1113ee7b)
2008-08-26 15:11:46 +00:00
Derrick Brashear
b9cabc6477 DEVEL15-linux-rpm-make-dkms-remove-work-20080826
LICENSE IPL10

rpm -e failed because of a typo here when removing our dkms rpm


(cherry picked from commit 82c62ae0e3b6366c9cdef0569e5be4637127e586)
2008-08-26 14:44:43 +00:00
Jeffrey Altman
740bb7a7b2 DEVEL15-windows-scache-lock-20080825
LICENSE MIT

restore a missing obtain write lock


(cherry picked from commit e16c4f8a96f0568d5f7155c88f9b877baa500b7d)
2008-08-26 05:56:42 +00:00
Jeffrey Altman
23b2990d35 DEVEL15-windows-misc-20080825
LICENSE MIT

avoid a deadlock in cm_GiveUpAllCallbacks

log UAEEXIST / EEXIST in cm_Analyze


(cherry picked from commit e0380d54bad50582b6bc39e2b41e78d72117ec79)
2008-08-26 05:38:44 +00:00
Jeffrey Altman
cd99ca3b39 DEVEL15-windows-client-osi-20080825
LICENSE MIT

add more asserts to attempt to catch locks released in threads other
than the one that obtained them.


(cherry picked from commit cb455744d49f250c236ab24cdcfffda104ef3774)
2008-08-26 05:16:02 +00:00
Derrick Brashear
dfc6d001f1 DEVEL15-server-argument-consistency-and-jumbograms-off-20080824
LICENSE IPL10
FIXES 108703

go through and make servers able to take debug log level on command line;
add -jumbo; default to -nojumbo


(cherry picked from commit 12c8abc69030d3368194b148c692215c61b5da9c)
2008-08-25 02:14:59 +00:00
Jeffrey Altman
15418516cc DEVEL15-windows-smb-more-check-open-done-20080824
LICENSE MIT

call cm_CheckNTOpenDone() in error conditions as well


(cherry picked from commit a88d12746a9e7e8e79a80c5bcafda449810b4e22)
2008-08-24 22:46:42 +00:00
Jeffrey Altman
1cdb4d92f9 DEVEL15-windows-prefetch-lock-order-20080824
LICENSE MIT

lock order violation between cm_daemonLock and cm_scache_t rw lock


(cherry picked from commit 82741251b1f444a1f18e3b9816f8cadac3e168b5)
2008-08-24 18:47:43 +00:00
Jeffrey Altman
a330485dee DEVEL15-windows-smb-locks-20080224
LICENSE MIT

smb_dirSearch_t refCount field is protected by smb_globalLock not the
smb_dirSearch_t mutex.

Do not hold the smb_fid_t mutex across calls to smb_NotifyChange()


(cherry picked from commit 24f8b1b4c327c3fb01a575ccb46d5ae6bf7edd36)
2008-08-24 17:33:06 +00:00
Jeffrey Altman
15467848df DEVEL15-windows-check-nt-open-lock-sync-20080224
LICENSE MIT

Move cm_SyncOpDone(CM_SCACHESYNC_LOCK) from cm_CheckNTOpen to
cm_CheckNTOpenDone.  This is necessary to synchronize lock operations.


(cherry picked from commit cc48a5a3b4d328127ca56c1a5845ec6cac136548)
2008-08-24 17:27:24 +00:00
Derrick Brashear
0f0725dcdc DEVEL15-darwin-fake-afs-bigger-20080822
LICENSE IPL10
FIXES 112564

set up max uint64 "free" in afs so finder isn't dumb.


(cherry picked from commit 186f707378ce0c04705170743cbc67ff44e1c93f)
2008-08-22 20:26:48 +00:00
Derrick Brashear
96431d61b2 DEVEL15-analyze-srvr-safety-check-20080822
LICENSE IPL10
FIXES 112681

safety check to make sure a conn's srvr is set before dereferencing it


(cherry picked from commit ea81e608bae42ea84d7bc85d289bfe6f24d8d383)
2008-08-22 19:52:57 +00:00
Jeffrey Altman
629ec8b276 DEVEL15-windows-misc-20080822
LICENSE MIT

1. In multi-threaded applications deadlocking is always a problem.
Deadlock avoidance requires a strict adherence to a documented
hierarchy.  The lock hierarchy for OAFW is described in a file
called locks.txt.  There are two problems.  First, some of the
locks are not included in locks.txt.  Second, it is nearly
impossible given the depth of function calls for any programmer
 to identify all of the locks that are held at any given time
a function is called.  This patch implements a new locking order
verification mechanism.  Each lock is assigned a lock level at
initialization.  Each thread maintains a queue of held locks.
Each time a lock is acquired the queue is checked to ensure that
no locks with a higher level than the requested lock has already
been acquired.  If a violation occurs, the service panics.

2. When the service panics ensure that a minidump will always be generated.

3. Remove unused lock cm_bufGetMutex.

4. The lock order verifier identified approximately a dozen
lock order violations that are corrected.

5. A race condition within the function path cm_GetSCache() ->
cm_GetNewSCache() -> cm_RecycleSCache() permitted a cm_scache_t
object to be issued simultaneously to two threads.  This would
eventually result in a panic due to the resulting under count.

6. Fix interpretation of the empty string as the ioctl path to
mean the current directory.   "fs lsm", "symlink list", etc.
now return a "not a ..." error instead of "does not exist".

7. Add SMB_STRF_SRCNULTERM flag to smb_ParseStringXXX functions
to indicate that the input string is a nul terminated string.
Assign it when input strings are nul terminated.

8. The CIFS protocol specification for handling NT_TRANSACT_CREATE
does not match the observed behavior.  The 'nameLength' is specified
in bytes not in characters.  Fix the implementation to match.

9. The cm_HaveAccessRights() attempt at deadlock avoidance by calling
lock_TryRead() on the parent directory cm_scache_t rw-lock does not
avoid the deadlock.  Avoid the deadlock by enforcing the lock order
of lowest vnode first.  Then remove the infinite loop avoidance in
cm_SyncOp() that was returning an unwarranted access denied error.


(cherry picked from commit ef10390e12ffd697f9eaaacd1d7291e05d16c835)
2008-08-22 19:10:00 +00:00
Derrick Brashear
e4c9c47cd1 DEVEL15-rx-allow-jumbogram-disabling-really-20080822
LICENSE IPL10

right now, jumbograms can still be sent when -nojumbo is specified. make the
current macro a default and override when we're supposed to.


(cherry picked from commit 46dbd678714110002a36269beca8961e013650ac)
2008-08-22 05:31:48 +00:00
Jeffrey Altman
d26c86abe6 DEVEL15-windows-list-symlink-20080820
LICENSE MIT

Another casaulty of the Unicode transition, the return value of the
ListLink operation was not being convered from wchar to char before
it was copied into the output buffer.


(cherry picked from commit a00f706eb67c257af9892557cfb6ad35594144cf)
2008-08-20 20:46:16 +00:00
Jeffrey Altman
b2030e2942 DEVEL15-windows-afsd-service-20080820
LICENSE MIT

When afsd_service.exe is not running as a service do not call the
Service Manager functions.  Doing so causes invalid access exceptions
to be thrown in the kernel and can corrupt the heap.


(cherry picked from commit 9488898fdb22e8c999ad4f713bd656caba91fe1c)
2008-08-20 20:42:47 +00:00
Derrick Brashear
18398383f9 DEVEL15-redhat-spec-default-build-authlibs-20080820
LICENSE IPL10
FIXES 101879

make build_authlibs default usefully


(cherry picked from commit 651f25b9c84b57cb88e2066c91c5234399673164)
2008-08-20 19:45:28 +00:00