You are here: Foswiki>Tasks Web>Item10157 (05 Jan 2015, GeorgeClark)Edit Attach

Item10157: we're failing to create a htpasswd.lock file when running a read only process from the commandline

pencil
Priority: Enhancement
Current State: No Action Required
Released In: n/a
Target Release: n/a
Applies To: Engine
Component:
Branches:
Reported By: SvenDowideit
Waiting For:
Last Change By: GeorgeClark
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
 

ItemTemplate edit

Summary we're failing to create a htpasswd.lock file when running a read only process from the commandline
ReportedBy SvenDowideit
Codebase
SVN Range
AppliesTo Engine
Component
Priority Enhancement
CurrentState No Action Required
WaitingFor
Checkins
TargetRelease n/a
ReleasedIn n/a
CheckinsOnBranches
trunkCheckins
masterCheckins
ItemBranchCheckins
Release01x01Checkins
Topic revision: r3 - 05 Jan 2015, GeorgeClark
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy