配置seafile 开机启动
[root@seafile system]# cat seafile.service
[Unit]
Description=Seafile
add mysql.service or postgresql.service depending on your database to the line below
After=network.target mariadb.service
[Service]
Type=oneshot
ExecStart=/data/haiwen/seafile-server-latest/seafile.sh start
ExecStart=/data/haiwen/seafile-server-latest/seahub.sh start
ExecStop=/data/haiwen/seafile-server-latest/seafile.sh stop
ExecStop=/data/haiwen/seafile-server-latest/seahub.sh stop
RemainAfterExit=yes
User=root
Group=root
[Install]
WantedBy=multi-user.target
[root@seafile system]#
错误:
[root@seafile system]# systemctl start seafile
Job for seafile.service failed because the control process exited with error code. See “systemctl status seafile.service” and “journalctl -xe” for details.
[root@seafile system]# journalctl -xe
– Defined-By: systemd
–
– Unit seafile.service has failed.
– The result is failed.
9月 10 23:11:23 seafile.local systemd[1]: Unit seafile.service entered failed state.
9月 10 23:11:23 seafile.local systemd[1]: seafile.service failed.
9月 10 23:11:23 seafile.local polkitd[863]: Unregistered Authentication Agent for unix-proces
9月 10 23:11:58 seafile.local polkitd[863]: Registered Authentication Agent for unix-process:
9月 10 23:11:58 seafile.local systemd[1]: Reloading.
9月 10 23:11:58 seafile.local polkitd[863]: Unregistered Authentication Agent for unix-proces
9月 10 23:12:03 seafile.local polkitd[863]: Registered Authentication Agent for unix-process:
9月 10 23:12:03 seafile.local systemd[1]: Starting Seafile…
– Subject: Unit seafile.service has begun start-up
– Defined-By: systemd
–
– Unit seafile.service has begun starting up.
9月 10 23:12:03 seafile.local seafile.sh[17782]: Seafile controller is already running, pid 1
9月 10 23:12:03 seafile.local systemd[1]: seafile.service: main process exited, code=exited,
9月 10 23:12:03 seafile.local systemd[1]: Failed to start Seafile.
– Subject: Unit seafile.service has failed
– Defined-By: systemd
–
– Unit seafile.service has failed.
– The result is failed.
9月 10 23:12:03 seafile.local systemd[1]: Unit seafile.service entered failed state.
9月 10 23:12:03 seafile.local systemd[1]: seafile.service failed.
9月 10 23:12:03 seafile.local polkitd[863]: Unregistered Authentication Agent for unix-proces
lines 3110-3141/3141 (END)