Item10157: we're failing to create a htpasswd.lock file when running a read only process from the commandline
Priority: Enhancement
Current State: No Action Required
Released In: n/a
Target Release: n/a
Applies To: Engine
Component:
Branches:
cd ~/src/foswiki/core/bin
./rest /MongoDBPlugin/update updateweb=Tasks
./rest /MongoDBPlugin/update updateweb=Development
data(restplugin) $ cd ~/src/foswiki/core/bin
bin(restplugin) $ ./rest /MongoDBPlugin/update updateweb=Tasks
/home/sven/src/foswiki/core/working/htpasswd.lock open or create password lock file failed -check access rights: Permission denied at /home/sven/src/foswiki/core/lib/Foswiki/Users/HtPasswdUser.pm line 130.
Foswiki detected an internal error - please check your Foswiki logs and webserver logs for more information.
path open or create password lock file failed -check access rights: Permission deniedbin(restplugin) $ ./rest /MongoDBPlugin/update updateweb=Development
/home/sven/src/foswiki/core/working/htpasswd.lock open or create password lock file failed -check access rights: Permission denied at /home/sven/src/foswiki/core/lib/Foswiki/Users/HtPasswdUser.pm line 130.
Foswiki detected an internal error - please check your Foswiki logs and webserver logs for more information.
path open or create password lock file failed -check access rights: Permission deniedbin(restplugin) $
running as a user that can't access the lock file, but otherwise has suffient rights
I'm not sure why we're reading, or neading to read the password file - perhaps we can optimise a little, perhaps not.
--
SvenDowideit - 15 Dec 2010
mmm, it looks like we're making a mess of it.
if your .htpasswd file is unreadable by the user you try&fail to run a script as, foswiki crashes, and leaves behind a htpasswd.lock file made by this new user.
then, the normal .htpasswd user runs a script (presumably as the webserver) and crashes because it can't access the htpasswd.lock file.
and thus you have a dead wiki.
a little more error checking and post crash cleanup should help.
--
SvenDowideit - 16 Dec 2010
The shell scripts really need to run using the same user as the web server. Password lock is only part of the issue. Ownership can change on topics, logs, working files, etc. Setting this to No Action
--
GeorgeClark - 05 Jan 2015