Restart a daemon in linux

Any idea how to restart a daemon in Linux ? Tks
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

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.

What version if Linux?

In most the following will work:

/etc/init.d/daemonname restart


service daemonname restart

Or in newer systemd systems:

Systemctl restart daemonname.service
AXISHKAuthor Commented:
I simply run the command in bash shell....

So should I just create a file under /etc/init.d/mysqlproxy.servcice and paste the line there ?

./mysql-proxy --proxy-address=:3306 --proxy-backend-addresses=xxxxx:3306 --daemon
Can you please specify what Linux distro and version you are using?
Acronis True Image 2019 just released!

Create a reliable backup. Make sure you always have dependable copies of your data so you can restore your entire system or individual files.

AXISHKAuthor Commented:

Red Hat 4.1.2-55

Here is a link to an init script you can use:

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
BTW, RedHat 4 has been end of life for quite some time now.  You really should upgrade to at minimum RED HAT 5.
AXISHKAuthor Commented:
Here are the steps that I install the server. Is the setup correct or not ? It doesn't work...
Is the problem on the distribution version ?

cd /usr/local
 tar xvzf /home/scigadm/mysql-proxy-0.8.5-linux-rhel5-x86-64bit.tar.gz
 cd mysql-proxy-0.8.5-linux-rhel5-x86-64bit/bin
You are trying to install a redhat 5 package onto a red hat 4 system.  That can lead to issues and very well might be the ready it is not installing or starting.
AXISHKAuthor Commented:
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.