Tente:
#!/usr/bin/env ksh
exec 2>ksh_err.txt
print -u2 'log errors to file'
exec 2>'tty'
print -u2 'log errors to console'
Editar 1:
#!/usr/bin/env ksh
exec 8>err.txt
print -u8 'log errors to file'
print -u2 'log errors to console'
Editar 2:
#!/usr/bin/env ksh
exec 3>&2
exec 2>err.txt
print -u2 'log errors to file'
exec 2>&3
print -u2 'log errors to console'