litespeedtech / litespeedtech/openlitespeed

File ownership in /tmp/lshttpd/ is wrong after changing user/group

Open
#319 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
1.5k
Forks
233
Avg merge
2d 19h
Merged PRs (30d)
5

Description

I installed OpenLiteSpeed, changed run user and group to `lsws` (which I created first) and did a reinstall, user and group ownership seems to be applied correctly to files in `$SERVER_ROOT`. But not so to files in `/tmp/lshttpd/`.

The server's error log showed me:
> Failed to open the real time report: /tmp/lshttpd/.rtreport!

The content of `/tmp/lshttpd/` looks like:
```
drwxr-xr-x 3 lsws lsws 10 Jun 11 01:32 ./
drwxrwxrwt 14 root root 40 Jun 11 01:32 ../
-rw-r--r-- 1 root root 7 Jun 11 01:32 lshttpd.pid
srwxr-xr-x 1 lsws lsws 0 Jun 11 01:32 lsphp.sock=
srwxr-xr-x 1 lsws lsws 0 Jun 11 01:32 lsphp.sock.100000=
-rw-r--r-- 1 lsws lsws 32 Jun 11 01:32 lsphp.sock.100000.pid
-rw-r--r-- 1 lsws lsws 32 Jun 11 01:32 lsphp.sock.pid
-rw-r--r-- 1 nobody nogroup 910 Jun 10 00:53 .rtreport
-rw-r--r-- 1 root nogroup 233 Jun 11 01:32 .status
drwx------ 2 lsws lsws 2 Jun 11 01:32 swap/
```

There are still files with the old owner nobody/nogroup.

I think: **Either the ownership of the files should be changed correctly or the folder should be completely emptied during the reinstall.**

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the reinstall after changing the run user and group to lsws, then inspect /tmp/lshttpd/ alongside $SERVER_ROOT and the error-log failure for .rtreport. Trace how the temporary directory and its files are created or retained during reinstall. Done means files in /tmp/lshttpd/ have the configured ownership, or the directory is emptied during reinstall.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.