Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ss-manager] Fall back to /tmp if workdir is / #2986

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

xwjdsh
Copy link

@xwjdsh xwjdsh commented Nov 23, 2023

I want to try using ss-manager to replace ss-server. I updated the ExecStart option, the config file located /lib/systemd/system/shadowsocks-libev.service.

...
DynamicUser=true
ExecStart=/usr/bin/ss-manager -c $CONFFILE $DAEMON_ARGS
...

Then I restarted the service, I got the following log.

Nov 23 11:59:23 eve systemd[1]: Started Shadowsocks-libev Default Server Service.
Nov 23 11:59:23 eve ss-manager[483697]:  2023-11-23 11:59:23 INFO: using tcp fast open
Nov 23 11:59:23 eve ss-manager[483697]:  2023-11-23 11:59:23 INFO: working directory points to //.shadowsocks
Nov 23 11:59:23 eve ss-manager[483697]:  2023-11-23 11:59:23 ERROR: mkdir: Read-only file system
Nov 23 11:59:23 eve ss-manager[483697]:  2023-11-23 11:59:23 ERROR: unable to create working directory
Nov 23 11:59:23 eve systemd[1]: shadowsocks-libev.service: Main process exited, code=exited, status=255/EXCEPTION
Nov 23 11:59:23 eve systemd[1]: shadowsocks-libev.service: Failed with result 'exit-code'.

I noticed that DynamicUser is used in the default systemd config, which may be why the user's workdir is '/', I thought maybe it could ignore / and use /tmp instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant