К основному контенту

BASH enable/disable CRON

 

Disable

crontab -l | sed '/^[^#].*pg13_new_restore_centos8/s/^/#/' | crontab -

Enable

crontab -l | sed '/^#.*pg13_new_restore_centos8/s/^#//' | crontab -

Комментарии

Популярные сообщения из этого блога

Repeat Linux command every x seconds

watch -n 5 "ps -ef | grep COPY" watch -n 10 "psql -U postgres -c \"select clock_timestamp() - query_start as duration, substr(query,1,50) from pg_stat_activity where pid <> pg_backend_pid() and state='active' order by 1 desc\"" for i in {1..10}; do ps -ef | grep COPY; date ; sleep 5; done while true; do ps -ef | grep COPY ; date ; sleep 5; done