Bobcares

DirectAdmin dead but subsys locked Error: How to Solve?

by | Mar 24, 2023

Let us take closer look at the error DirectAdmin dead but subsys locked Error. With the support of our DirectAdmin support services at Bobcares we will now learn how to remove the error easily.

Error: DirectAdmin dead but subsys locked Error

DirectAdmin dead but subsys locked Error

DirectAdmin is a web-based hosting control panel that is intended to simplify administration. It is compatible with ever-changing web hosting environments. DirectAdmin is commonly abbreviated as DA. DirectAdmin can run on any system with the bare minimum of configurations. DirectAdmin’s default port is 2222.

Checking the DA status will tell us whether or not the DirectAdmin is currently running. The following command can be used to determine the current status of the DirectAdmin. To do this, we have to log in as root. In the terminal, type the following command.

# service directadmin status

Dead but subsys locked

If the the error message ‘directadmin dead but subsys locked, open up, it means that DirectAdmin is not currently running on the server, but the ‘pid’ file is. PID stands for process identification number. Each process in a system is given a unique id by which it can be identified.

If we receive this status message, we will be unable to access the DirectAdmin control panel. This is a significant issue because we may be unable to manage the server until we regain access to the control panel. We must restart the DirectAdmin service to regain access to the control panel. In this case, restarting the process may be difficult. However, we can restart the DirectAdmin service.

Dead but subsys locked: Troubleshoot

Ensure that DirectAdmin is no longer alive

Before we restart the service, we must ensure that DirectAdmin is no longer active. We can verify this with the ‘ps’ command. The ps command displays information about the currently running processes, including their process ID numbers (PIDs). The ps command displays all currently active processes.

We can use grep to print only the DirectAdmin information in the output. This is a very useful pattern matching tool that is found on all unix/linux systems. To do this, we must be logged in as root.

# ps -aux | grep directadmin

Exanple

root 22755  0.0  0.0   6444   692 pts/0 S+   06:51   0:00 grep directadmin

Kill the process

If the above command returns any lines other than the ‘grep’ line, it indicates that the DirectAdmin process is active in the system. Because the DirectAdmin service is currently inactive, these processes have no effect. However, it will prevent DirectAdmin service start/restart operations.

We must kill these processes using their process ids in order to restart the DirectAdmin service. The kill command will terminate a process based on the kill signal and PID specified by the user. The process id will be obtained from the output of the ps command. To terminate a process, use the ‘kill’ command with the process id. This will most probably remove the DirectAdmin dead but subsys locked Error.

Syntax

kill pid

The pid here represents the number displayed in the second column of the ps output.

Force kill

Repeat the ps line after completing the preceding method. This is to confirm that the DirectAdmin process has ended.

# ps waux | grep directadmin

Syntax

# kill -9

or we can type in the following command line:

kill -SIGKILL pid
Using any method, terminate all existing DirectAdmin processes.

Remove pid file

This is the next steps in removeing the DirectAdmin dead but subsys locked Error. A Pid-File is a file that stores the process identification number (pid) in a specific location on the filesystem, allowing other programmes to determine the pid of a running script.

Once all instances of DirectAdmin have been terminated, look for a file named /var/run/directadmin.pid. If we find this file, we will delete it with the rm command.

# rm /var/run/directadmin.pid

Reboot the DirectAdmin

The DirectAdmin service should then be restarted. We can restart the DirectAdmin service with the following command:

# service directadmin restart

This is the final step in removing the error DirectAdmin dead but subsys locked Error.

[Need assistance with similar queries? We are here to help]

Conclusion

To sum up we have now seen how to remove the error DirectAdmin dead but subsys locked Error. With the support of our DirectAdmin Support services at Bobcares we have now gone through a complete guide on how to remove the error.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Never again lose customers to poor
server speed! Let us help you.