Crontab

67 views
Skip to first unread message

Anubhav Ahuja

unread,
Mar 31, 2020, 12:45:32 PM3/31/20
to Isilon Technical User Group
Hi All,

I wrote a small crontab to send the output to a group of user every 5 minutes. See Below. Somehow, they (I am also part of that group) are not getting emails. Can anyone point me out on what i am missing 

#custom cron for running the netstat -n command
*/5 * * * * netstat -n | mail -s "output on netstat"

Can you please advise.

Thanks
Anubhav

Chris Pepper

unread,
Mar 31, 2020, 2:14:45 PM3/31/20
to isilon-u...@googlegroups.com
Anubhav,

The cluster-wide crontab is in /etc/mcp/override/crontab.smbtime. Note that isi_ropc executes its argument on only one node.

Unfortunately Dell broke the `mail` command a while ago.

Chris
> --
> You received this message because you are subscribed to the Google Groups "Isilon Technical User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to isilon-user-gr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/isilon-user-group/62bb8d91-50ea-4cfc-a267-311043a66e5e%40googlegroups.com.

Anubhav Ahuja

unread,
Mar 31, 2020, 2:31:13 PM3/31/20
to isilon-u...@googlegroups.com
Thanks Chris, 

So i just put the command */5 * * * * netstat -n to the crontab.smbtime file, how will it mail to the intended recipients 



--
Thanks and Regards
Anubhav Ahuja

Chris Pepper

unread,
Mar 31, 2020, 4:32:18 PM3/31/20
to isilon-u...@googlegroups.com
What version of OneFS? I don’t think it will send email. Try something like this instead:

*/5 * * * * “date; netstat -n; echo" >> /ifs/data/netstat

You could have an NFS client with /ifs/data/ mounted mail the file, if that’s what you really want.

Chris


Anubhav Ahuja

unread,
Mar 31, 2020, 4:33:24 PM3/31/20
to isilon-u...@googlegroups.com
We are on 8.1.2

Chris Pepper

unread,
Mar 31, 2020, 4:42:24 PM3/31/20
to isilon-u...@googlegroups.com

Nathaniel Middleton

unread,
Mar 31, 2020, 4:48:03 PM3/31/20
to isilon-u...@googlegroups.com
I have just been using the /ifs/tools/sendml.py tool.
ex: /usr/bin/python /ifs/tools/sendml.py -t email address -s "Subject"

Chris Pepper

unread,
Mar 31, 2020, 5:09:28 PM3/31/20
to isilon-u...@googlegroups.com
Nathaniel,

Does that work as any user or only root? I think someone suggested that in my (fruitless) search for a mail command.

Thanks,

Chris


Nathaniel Middleton

unread,
Mar 31, 2020, 5:27:47 PM3/31/20
to isilon-u...@googlegroups.com
I am not sure if it requires root- I don't have local users on the isi nodes... so that makes it harder to test and find out on my end...
quick glance- it has perms of root:wheel and 771, but unsure what the dependencies of it require in terms of permissions

Reply all
Reply to author
Forward
0 new messages