M m_davaee Verified User Joined Mar 16, 2016 Messages 5 Apr 1, 2016 #1 Hi, I need to set cron jobs which run as root user. How can i do this?
Richard G Verified User Joined Jul 6, 2008 Messages 14,306 Location Maastricht Apr 1, 2016 #2 Login as root via SSH or login as a user (or admin) in SSH and su to root. Then you can via: Code: crontab -e You can also login to SSH as a user and then: Code: sudo crontab -e you do need the root password. You can also use /etc/crontab or cron.daily or one of the others, depending on what you want. You need crontabs to be installed, on Centos: Code: yum install crontabs if not present yet.
Login as root via SSH or login as a user (or admin) in SSH and su to root. Then you can via: Code: crontab -e You can also login to SSH as a user and then: Code: sudo crontab -e you do need the root password. You can also use /etc/crontab or cron.daily or one of the others, depending on what you want. You need crontabs to be installed, on Centos: Code: yum install crontabs if not present yet.