public function ensureOneInstance($name)
 {
     $lastPid = $this->getPid($name);
     if ($lastPid != -1) {
         kill_pid($lastPid);
     }
     $this->setPid($name, getmypid());
 }
示例#2
0
    exit;
}
if (isset($_GET["restart-framework"])) {
    restart_framework();
    exit;
}
if (isset($_GET["restart-amavis"])) {
    restart_amavis();
    exit;
}
if (isset($_GET["restart-monit"])) {
    restart_monit();
    exit;
}
if (isset($_GET["kill-pid"])) {
    kill_pid();
    exit;
}
if (isset($_GET["reconfig-jabberd"])) {
    reconfig_jabberd();
    exit;
}
if (isset($_GET["ejabberd-status"])) {
    ejabberd_status();
    exit;
}
if (isset($_GET["php-cgi-array"])) {
    php_cgi_array();
    exit;
}
if (isset($_GET["yorel-rebuild"])) {
示例#3
0
文件: lxlib.php 项目: zseand/kloxo
/**
 * @return void
 * @param unknown
 * @param unknown
 * @desc the function that does the redefining of fundamental file access functions. Note the double use of 'eval'. hey hey, nothing is impossible in php. Never ever repeat the code; Make it unreadable instead. :-)
 */
function kill_and_save_pid($name)
{
    kill_pid($name);
    usleep(100);
    save_pid($name);
}