rm file restoration

i have removed below pid file using rm command as i got some error messages with permissions on that

rm xyz.pid

is there is a way i can restore that file

I am trying to start the web logic server and having issues which used to work earlier file

Please advise
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Dr. KlahnPrincipal Software EngineerCommented:
The PID files for web servers are created automatically when the server starts.  Simply stop the server (a cold full stop, not just a restart) and start it again.

You probably have no control over the location or permissions on the server's PID file, so if there is a permissions issue you'll probably need to give the failing process membership in the server's group.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
gudii9Author Commented:
how to do cold full forced stop?
Dr. KlahnPrincipal Software EngineerCommented:
For Apache, "apachectl stop" and then "apachectl start."  For other servers ... no idea.
gudii9Author Commented:
it asked while stoping to remove something i said yes and enter
then it stoppedd
then when i gave start command it started successfully

not sure some times while stopping get these dummy errors making me nervous
Prabhin MPDevOps EngineerCommented:
or else you create  touch a file in the same location and restart the service,

if the service is not stopped kill the service,

kill -9 < service PID>
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.