cron job
Moderator: Supporters
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
cron job
I set up the cron job as it says there (https://www.unrealircd.org/docs/Cron_job) but unfortunately it doesn't work.
*/5 * * * * /home/xxxx/xxxxx/unrealircd croncheck
@reboot /home/xxxxx/xxxx/unrealircd start croncheck
MAILTO=[email protected]
or
*/5 * * * * /home/xxxx/xxxxxx/unrealircd croncheck
@reboot /home/xxxx/xxxxxx/unrealircd croncheck
MAILTO=[email protected]
*/5 * * * * /home/xxxx/xxxxx/unrealircd croncheck
@reboot /home/xxxxx/xxxx/unrealircd start croncheck
MAILTO=[email protected]
or
*/5 * * * * /home/xxxx/xxxxxx/unrealircd croncheck
@reboot /home/xxxx/xxxxxx/unrealircd croncheck
MAILTO=[email protected]
Re: cron job
The second one there looks correct. In what way do you mean it doesn't work? Did your server crash? Are you testing it and there was nothing after 5 minutes or reboot? Please explain further
Got an idea for a module? Don't be shy! Come talk to me on #unreal-support
Like the support I provide? Consider supporting me with a donation.
Like the support I provide? Consider supporting me with a donation.
Re: cron job
Actually I think it may be slightly wrong.
It should be
It seems like you may have
so you should have
For clarity, you must run the "unrealircd" script which is inside the "unrealircd" directory, so you just gotta call that instead of calling the directory itself
It should be
Code: Select all
/home/user/unrealircd/unrealircd croncheck
Code: Select all
/home/user/some_directory/unrealircd croncheck
Code: Select all
/home/user/some_directory/unrealircd/unrealircd croncheck
Got an idea for a module? Don't be shy! Come talk to me on #unreal-support
Like the support I provide? Consider supporting me with a donation.
Like the support I provide? Consider supporting me with a donation.
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
Re: cron job
Does not start after rebooting the server after 5 minutes. No matter whether /home/xxxx/xxxxx/unrealircd croncheck or /home/xxxx/xxxxxx/unrealircd start croncheck
If I run it manually, the cron starts, but not automatically.
It works manually via ./unrealircd croncheck
If I run it manually, the cron starts, but not automatically.
It works manually via ./unrealircd croncheck
Re: cron job
I don't know what your xxxxx's mean and it would be easier to understand if you used obscure names like /some_directory/.
I'm sure you need to have this:
I believe you are missing an "/unrealircd"
It's my understanding that you are trying to call the "unrealircd" directory instead of the "unrealircd" file which is inside the "unrealircd" directory ;D
I'm sure you need to have this:
Code: Select all
/home/xxxx/xxxxx/unrealircd/unrealircd croncheck
instead of what you have which is
/home/xxxx/xxxxx/unrealircd croncheck
It's my understanding that you are trying to call the "unrealircd" directory instead of the "unrealircd" file which is inside the "unrealircd" directory ;D
Got an idea for a module? Don't be shy! Come talk to me on #unreal-support
Like the support I provide? Consider supporting me with a donation.
Like the support I provide? Consider supporting me with a donation.
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
Re: cron job
sorry about the incomprehensible directory with xxx .
home/user/ircd/unrealircd croncheck.
ircd is the name of the folder unrealircd
hope it's better now
home/user/ircd/unrealircd croncheck.
ircd is the name of the folder unrealircd
hope it's better now
Re: cron job
indeed, it needs an extra /unrealircd on the end of it, like so:
Code: Select all
/home/user/ircd/unrealircd/unrealircd
Got an idea for a module? Don't be shy! Come talk to me on #unreal-support
Like the support I provide? Consider supporting me with a donation.
Like the support I provide? Consider supporting me with a donation.
Re: cron job
There seems to be some miscommunication here.Valware wrote: ↑Sat Jul 20, 2024 12:12 pm indeed, it needs an extra /unrealircd on the end of it, like so:Code: Select all
/home/user/ircd/unrealircd/unrealircd
We need to know the folder where the executable is placed.
During UnrealIRCd compilation, after the ./Config command, this question will appear:
Code: Select all
In what directory do you want to install UnrealIRCd?
(Note: UnrealIRCd 6 will need to be installed somewhere.
If this directory does not exist it will be created.)
[/home/USER/unrealircd] ->
Code: Select all
*/5 * * * * /home/USER/ircd/unrealircd croncheck
Code: Select all
*/5 * * * * /home/USER/ircd/unrealircd/unrealircd croncheck
Because, if the folder was renamed after UnrealIRCd has been installed, this has harmful consequences.
My case:
I answered /home/USER/ircdz and my cronjob is set as the following:
Code: Select all
*/5 * * * * /home/USER/ircdz/unrealircd croncheck
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
Re: cron job
Code: Select all
In what directory do you want to install UnrealIRCd?
(Note: UnrealIRCd 6 will need to be installed somewhere.
If this directory does not exist it will be created.)
[/home/USER/unrealircd] ->
Code: Select all
[/home/USER/unrealircd] ->/home/user/ircd
if I run the following in the ircd folder manuell:
./unrealircd croncheck
with the following entries in the cronjob
Code: Select all
/home/user/ircd/unrealircd/unrealircd croncheck
or
/home/user/ircd/unrealircd croncheck
Re: cron job
For your installation, your crontab must be:/home/user/ircd/unrealircd/unrealircd croncheck
or
/home/user/ircd/unrealircd croncheck
Code: Select all
*/5 * * * * /home/USER/ircd/unrealircd croncheck
Are you saving the crontab properly?
Are you saving the crontab as the user running UnrealIRCd?
There's no # at the beginning of the line?
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
Re: cron job
Am I wrong? You can only call crontab -e with root, right? If I'm wrong, then thanks for the improvement.
Even if it's not relevant to the topic, I'm very surprised and pleased with the new functions you've integrated. Keep up the good work.
Even if it's not relevant to the topic, I'm very surprised and pleased with the new functions you've integrated. Keep up the good work.
Re: cron job
Yes, you're wrong. You should use crontab -e as the user running UnrealIRCd.Xander2024 wrote: ↑Sat Jul 20, 2024 1:25 pm Am I wrong? You can only call crontab -e with root, right? If I'm wrong, then thanks for the improvement.
Even if it's not relevant to the topic, I'm very surprised and pleased with the new functions you've integrated. Keep up the good work.
Otherwise you may mess up files permissions.
-
- Posts: 6
- Joined: Sat Jul 20, 2024 10:47 am
Re: cron job
Your last question about crontab was saved correctly. That was my mistake, and the last answer was wrong. I finally got to my goal. THX
Thanks to everyone who tried to help.
The MAILTO... function gets the domain name from the host or hostname file when sending emails?
The email thing would be great.
Thanks to everyone who tried to help.
The MAILTO... function gets the domain name from the host or hostname file when sending emails?
The email thing would be great.