Welcome, Guest. Please login or register.

Author Topic: crontab not in correct location  (Read 597 times)

Westy_87

  • Newbie
  • *
  • Posts: 14
    • View Profile
crontab not in correct location
« on: March 13, 2024, 12:18:02 am »
Good Morning,

I tried to update the crontab directly through GUI but it didn't seem to be making any differences.

After doing some digging, I realise the GUI is changing a file called crontab in var/nedi/inc/

But when I check the crontab file for user www-data it shows the original file without the changes made.

Any idea how to fix the link between GUI and actual crontab file?

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2897
    • View Profile
    • NeDi
Re: crontab not in correct location
« Reply #1 on: March 15, 2024, 09:59:01 am »
Look around line 143 in System-Files.php. This (temporary) crontab is installed via system command and the result printed out...
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

Westy_87

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: crontab not in correct location
« Reply #2 on: April 02, 2024, 07:13:42 am »
Thanks.

When I make a change in the crontab section in the gui, it says

Write /var/nedi/inc/crontab (21 bytes) OK

then it says

Crontab Update Errors


I can see the file is being updated, but then the system command to update the actual cron isn't working I guess. Any idea how to troubleshoot that?

Edit:
I can see in /var/spool/cron/crontabs/ is a file www-data that contains the crontab entries from before the link was somehow broken.

permissions issue or anything?

nedi:~$ sudo ls -l /var/nedi/inc/crontab
-rw-r--r-- 1 www-data www-data 21 Apr  2 05:11 /var/nedi/inc/crontab
nedi:~$ sudo ls -l /var/spool/cron/crontabs/www-data
-rw------- 1 www-data crontab 1569 Jan 18 03:27 /var/spool/cron/crontabs/www-data
« Last Edit: April 02, 2024, 07:33:20 am by Westy_87 »