monitoring incoming mailbox in console mode

Matthias Apitz guru at
Sat Sep 11 09:34:15 UTC 2021

El día jueves, septiembre 09, 2021 a las 08:48:52a. m. +0200, Matthias Apitz escribió:

> Thanks for the hints about biff(1). I wasn't aware of it, even if I was
> used to use xbiff in the past.
> But, biff(1) does not do anything. I run
> $ truss -o -f biff b
> and attached is the output of Any ideas?

I've had a glance through the source in /usr/src/usr.bin/biff/biff.c and
it only tweaks on some bits in the perms of the tty you're login on:

	switch (argv[0][0]) {
	case 'n':
		if (chmod(name, sb.st_mode & ~(S_IXUSR | S_IXGRP)) < 0)
			err(2, "%s", name);
	case 'y':
		if (chmod(name, (sb.st_mode & ~(S_IXUSR | S_IXGRP)) | S_IXUSR)
		    < 0)
			err(2, "%s", name);
	case 'b':
		if (chmod(name, (sb.st_mode & ~(S_IXUSR | S_IXGRP)) | S_IXGRP)
		    < 0)
			err(2, "%s", name);
	return (sb.st_mode & (S_IXUSR | S_IXGRP) ? 0 : 1);

and then exits. The rest should depend on the login shell and its env
var MAIL and/or MAIL_PATH.

Said that, it does not do what I want because in many times my netbook
is only booted, receives mails to /var/mail/guru and I'm only connected
via SSH to it.


Matthias Apitz, ✉ guru at, +49-176-38902045
Public GnuPG key:
August 13, 1961: Better a wall than a war. And, while the GDR was still existing,
no German troups and bombs have been killed in Yugoslavia, Afghanistan, Afrika...

More information about the freebsd-questions mailing list