0
我寫了一個Cron作業來殺死已經睡了太久的進程。但是,當我殺死一個進程時,它立即重新生成。什麼是重新啓動這些進程?它是一個MySQL設置?MySQL KILL - 進程立即重新生成
這裏是我使用的代碼:
db.driver.execQuery 'select * from information_schema.processlist where time > 2000', (err, threads) ->
if err? then return
if !threads? then return
for thread in threads
do (thread) ->
db.driver.execQuery 'kill ' + thread.ID, (err, response) ->
console.log 'Killed thread that was ' + thread.TIME + ' seconds old'
可以是無數的東西,像一個監視器進程..試圖識別用戶 – Gadonski 2014-12-01 16:33:20