Test a schedule expression

Parse a schedule and show when it runs next. Note: systemd has its own calendar format and does not understand cron syntax.

systemd-analyze calendar '*/5 * * * *'

tool
linux133 commands
tags
linux

More linux commands

  • command > /tmp/out.log 2> /tmp/err.log

    Write stdout and stderr to separate files.

  • command 2>&1 | tee /tmp/all.log

    Send stdout and stderr to a file and to the screen at the same time.

  • grep -rl 'old_string' /etc/ | xargs sed -i 's/old_string/new_string/g'

    Find files that contain the text and replace it directly in them.

  • awk '{print $1, $3}' /etc/passwd

    Print the 1st and 3rd fields of each line. By default awk splits on spaces, so for /etc/passwd you need -F: to split on colons.

  • awk '{sum += $2} END {print sum}' file.txt

    Add up the values in column 2 of a text file.

all 133 linux commands