Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
slapos slapos
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Labels
    • Labels
  • Merge requests 122
    • Merge requests 122
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Environments
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Jobs
  • Commits
Collapse sidebar
  • nexedi
  • slaposslapos
  • Merge requests
  • !1418

Merged
Created Aug 09, 2023 by Boxiang Sun@DaetalusDeveloper

Allow httpd to restart after the sever reboot from poweroff

  • Overview 31
  • Commits 1
  • Changes 5

If a server reboots brutally, there will be a legacy httpd pid file stay in the file system, and the OS may reuse the PID that remains in that file, which will cause httpd service to fail to start even if there is no such httpd service is running.

This commit implemented the following logic:

  1. If there is no existing PID file, then run the httpd service directly
  2. If the PID file exists and contains the PID used by another process, we delete the PID file, then restart the httpd service
  3. If the PID file exists and contains the PID used by another running httpd service, we allow the httpd report the "already running" error normally
Edited Sep 08, 2023 by Romain Courteaud
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Source branch: httpd-reboot
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7