Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jobber refuses to load jobs due to odd logging file format issue #240

Closed
EugenMayer opened this issue Mar 26, 2019 · 9 comments
Closed

jobber refuses to load jobs due to odd logging file format issue #240

EugenMayer opened this issue Mar 26, 2019 · 9 comments
Assignees
Labels
Milestone

Comments

@EugenMayer
Copy link

EugenMayer commented Mar 26, 2019

i suddently happen to notice that no jobber-jobs are running and also jobber list does not list any.

Searching for quiet a while a happen to notice that

jobber reload

fails with

Call to Jobber failed: Invalid log file: /mnt/log/dwcore/cron-history: size is less than entry size

This was a log file before, and even if i do

echo "" > /mnt/log/dwcore/cron-history

to flush the logfile, i get the same error message. Only if rm the file entirely, i can reload the jobs and let them run.

My jobs log config looks like this:

[prefs]
runLog:
  type: file
  path: /mnt/log/dwcore/cron-history
  maxFileLen: 100m
  maxHistories: 2

I am currently not even able to explain what this error message actually mean, but for sure it should not road-block running jobber if the log-file does have an "unexpected EOL" or even "a blank line" or whatever it might actually be

is that actually supposed to happen / is by design?

Version
tried 1.3.2 and 1.3.4

Suggestion
If that is by design, i would at least try to start a discussion if that makes sense.

I suggest, never fail to load or run jobs because of the logfile being missformatted, non existing or even like in this case ( i do not even no ) not being of the "right size"? Always load the jobs, always run them

Workarround
I could ensure this does not happen when remove the runLog configuration entirely, which i did

@EugenMayer
Copy link
Author

Any chance we could move this forward? I found out that the reason for this was a copy&paste issue for 2 jobber configurations sharing the same log-path.

I understand that this is a configuration issue, but beside that really can happen, the second point is, that clearing the log ( echo "" > logfile ) makes the file broken too.

I would really love to have this just a little more robust / warning alike. Any chance of a discussion about this?

@dshearer
Copy link
Owner

dshearer commented Apr 3, 2019 via email

@EugenMayer
Copy link
Author

@dshearer thank you a lot, let me know if you need anything

@dshearer
Copy link
Owner

dshearer commented Apr 6, 2019

I agree with your suggestion. Unfortunately I'm sick, so I may not make much progress this weekend.

@EugenMayer
Copy link
Author

No worries, i wish you to get better soon.

@dshearer
Copy link
Owner

The doctors resuscitated me just so I could work on this bug.

@dshearer dshearer self-assigned this Apr 14, 2019
@dshearer dshearer added the bug label Apr 14, 2019
@dshearer dshearer added this to the 1.4.1 milestone Apr 14, 2019
@EugenMayer
Copy link
Author

Back from the dead - that is real bad ass :)
I guess sqaushing bugs won't be a challenge any longer. Thanks for taking your time for that one!

@EugenMayer
Copy link
Author

I guess this one died? :)

@dshearer
Copy link
Owner

dshearer commented Feb 23, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants