By default, cron will email the owner of the account under which the crontab is running.
The system-wide crontab is in /etc/crontab runs under the user `root'
Because root is used widely, I'd recommend adding a root alias to your /etc/aliases file anyways. (run 'newaliases' after)
The normal way to structure this is for root to be aliased to another user on the system, e.g. for me I'd alias 'root' to 'phil' (my user account) and alias 'phil' to my external email address.
If you have a specific user cron that you'd like emailed to you on output, you can use /etc/aliases again (providing you have superuser access) to redirect the user to another email address, or you can use the following at the top of your crontab:
MAILTO="email@domain.com"
If mail should be sent to a local user, you may put just the username instead:
MAILTO=someuser
If you need more information see crontab(5) by running:
man 5 crontab
As of GNU coreutils 7.5 released in August 2009, sort
allows a -h
parameter, which allows numeric suffixes of the kind produced by du -h
:
du -hs * | sort -h
If you are using a sort that does not support -h
, you can install GNU Coreutils. E.g. on an older Mac OS X:
brew install coreutils
du -hs * | gsort -h
From sort
manual:
-h, --human-numeric-sort compare human readable numbers (e.g., 2K 1G)
Best Answer
To quickly kill all the stopped jobs under the bash, enter:
jobs -ps
lists the process IDs (-p
) of the stopped (-s
) jobs.kill -9 `jobs -ps`
sends SIGKILL signals to all of them.