<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Arial,Helvetica,sans-serif;" dir="ltr">
<p>I have 4 instances of icecast running on my server.</p>
<p><br>
</p>
<p></p>
<div>#Command to start icecast<br>
/usr/bin/icecast -c /etc/icecast.xml -b &<br>
/usr/bin/icecast -c /etc/icecast1.xml -b &<br>
/usr/bin/icecast -c /etc/icecast2.xml -b &<br>
/usr/bin/icecast -c /etc/icecast3.xml -b &</div>
<p></p>
<p><br>
</p>
<p>I am trying to integrate an automated Let's Encrypt Certificate renewal. My testing found that I need to restart the icecast processes for the certificate to update. I created a bash script that would open the firewall port, renew the cert, combine the
certificates, overwrite the old cert, close the firewall port, kill the icecast services and then start them.</p>
<p><br>
</p>
<p>Everything works except for the restarting of the services. Killing them works fine but starting them hangs. Please help me create the steps to start the 4 icecast instances via bash. I have tried no & and && as well. Feeling really stupid right now.
Thank you in advance for your time and please spell out the answer without assuming my knowledge or lacktherof!
<span>😉</span> </p>
<p><br>
</p>
<p></p>
<div>#Kill all processes with the name icecast<br>
ps -ef | grep icecast | grep -v grep | awk '{print $2}' | xargs -r kill -9</div>
#Start my icecast instances<br>
<p></p>
<p></p>
<div>/usr/bin/icecast -c /etc/icecast.xml -b &<br>
/usr/bin/icecast -c /etc/icecast1.xml -b &<br>
/usr/bin/icecast -c /etc/icecast2.xml -b &<br>
/usr/bin/icecast -c /etc/icecast3.xml -b &</div>
<br>
<p></p>
<p><span>PS: If I can get this working I can post it to github for everyone who would like to secure their icecast traffic and renew it automatically.</span><br>
</p>
<p><br>
</p>
</div>
</body>
</html>