Restart process on linux by its pidn number with kill command, how?

There is no “restart” signal. You need to record the environment (environ, cwd, cmdline, security context…) from /proc/<pid> and manually start the process again.

SIGHUP is close, but it is only used by convention to ask the program to reload its settings.


There is a "RELOAD" signal.

Assume you have a squid process with pid 1 runs in container, if you restart the squid process the container will exit. but you can "RELOAD" it like this:

kill -HUP 1