0

On my Ubuntu 21.10 Ubuntu desktop, which is sometimes on at midnight (if I happen to be awake and using it), a nightly event takes place where there is a lot of disk activity -- the red light for the HDD is blinking repeatedly, even though I'm not doing anything. I don't know what it is, but it does cause the system to slow down.

I know it isn't a user-level or a root-level cronjob. I've checked that. So, I guess it's something that has been turned on by default. I suppose I also have a slight concern that it's something done by an outside party, but I guess that's unlikely since midnight every night is a bit too predictable.

I have set up a backup program, but that program doesn't run at midnight. It's possible it's just rotating log files or something. Whatever it is, I just want to know what it is (and maybe move it to another time).

Anyway, what can I do to figure out what's causing this? I have looked at the output of top, but nothing looks out of place. Besides the user and root's crontab, is there anything else I should check?

Any suggestions would be appreciated!

Ray
  • 2,200

1 Answers1

1

Look at the logs:

# Use the power of the date command to produce journalctl-friendly date format
alias tsjou='date '\''+%y-%m-%d %H:%M:%S'\'''

Examples:

walt@bat:~(0)$ tsjou
22-03-06 14:02:25
walt@bat:~(0)$ tsjou --date="23:45 yesterday"
22-03-05 23:45:00

To see the system logs around midnight:

sudo journalctl --since="$(tsjou --date="23:45 yesterday")" \
                --until="$(tsjou --date="00:15")"

Read man date journalctl. I have more journalctl hints at https://askubuntu.com/users/25618/waltinator?tab=profile You'll have to click the "Read more" button - I'm verbose.

waltinator
  • 37,856