Comments (6)
systemctl服务配置文件里面可以写,用服务吧。
from mcsmanager.
能解决大部分问题,但还是有点不方便。我的服务端都放在 /opt
下,这个目录只有 root 有权限,所以如果想创建新的服务端就要进终端先创建个文件夹,或者就得改现在的目录结构。同样这样还是不支持多个用户,不过问题不大,真有需求可以用不同用户开多个 daemon。
from mcsmanager.
目前如果用
su
切换身份执行会有 bug:如果用 ^C 停止服务器,会直接报Session terminated, killing shell... ...killed.
,服务端不是被正常停止了,而是su
被强行杀掉了,不会触发服务器的自动保存等,或者干脆卡在停止过程也没法强制停止,取决于是直接用su
还是在启动脚本里写su
。
你说的是「启动命令」处设置 su 相关的命令吗?跟安装脚本没关系吧?
from mcsmanager.
你说的是「启动命令」处设置 su 相关的命令吗?跟安装脚本没关系吧?
启动脚本里写 su
意思是写个 start.sh
,在里面写 su
,启动命令是 start.sh
。
from mcsmanager.
你说的是「启动命令」处设置 su 相关的命令吗?跟安装脚本没关系吧?
启动脚本里写
su
意思是写个start.sh
,在里面写su
,启动命令是start.sh
。
明白了,MCSManager 启动子进程后,此进程的权限全部继承 MCSManager 的权限,也就是说你的面板 Daemon 程序使用的是什么用户,那么你的实例真实进程就一定会是这个用户,无法更改。
使用 Docker 可以更改。
你在启动脚本中写 su 切换到其他用户,实际上是启动另外一个 shell 子进程,此时你如果输入 ctrl c,那么随着父进程被结束,你的su子进程将会一起被杀死,这是不可避免的。
from mcsmanager.
你在启动脚本中写 su 切换到其他用户,实际上是启动另外一个 shell 子进程,此时你如果输入 ctrl c,那么随着父进程被结束,你的su子进程将会一起被杀死,这是不可避免的。
是的。但这样的话服务端收不到 SIGINT 信号,也就没法正常退出。
from mcsmanager.
Related Issues (20)
- [Bug Report] 仿真终端模式下无法使用相对路径启动实例 HOT 2
- [Feature] 能否删除或者缩短设置界面的margin-top HOT 2
- [Bug Report] Unable to start Minecraft Forge Servers HOT 2
- [Bug Report] HOT 3
- [Bug Report] HOT 4
- 错误报告 HOT 2
- [Feature] 我觉得''定时备份功能''是特别有必要的 HOT 3
- [Bug Report] 节点代理问题 HOT 8
- API文档 HOT 4
- [Feature] 实例开机延时启动和重启间隔时间功能
- [Bug Report] V10无法删除文件 HOT 4
- [Feature] 新增自定义配置文件 HOT 2
- [Bug Report] 删除文件功能存在问题 HOT 1
- [Bug Report] [Operation Error] 实例状态不正确,有其他任务正在运行中 HOT 2
- [Bug Report] 启用docker容器,网络模式host时,启动mc服务器的报错 HOT 3
- How to add the language of my country?
- [Bug Report] 文件管理复制剪贴按钮逻辑
- [Bug Report] 启动报错 HOT 8
- [Bug Report] 节点在线但无法连接 HOT 9
- 快速部署中的下载节点全部无法ping通 HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mcsmanager.