Hi, After some tests (on a new tmux server, started with "tmux -L test ..."), I could (partially) reproduce the problem.
Partially, because: in fstat output there are 2 kinds of "bugged" entries: tty and null tty: 181 descriptors null: 320 descriptors And I arrived to keep descriptors opened against /dev/tty , but not against /dev/null (for the moment, but I monitor what in my use what generate this...). This occurs with urlview (textproc/urlview), with a custom url_handler. Basically urlview take a text in stdin (generally an email), and display a menu (ncurses) of URLs found in the text. The user choose an URL, and urlview start a command (in my case, a custom script). First, my configuration: $ cat ~/.urlview # command to invoke for selected URL COMMAND /home/semarie/.local/bin/urlview_handler.sh Next, the command started by urlview: $ cat /home/semarie/.local/bin/urlview_handler.sh #!/bin/sh # if TMUX enable, update environment if [ -n "${TMUX}" ] ; then eval `tmux show-environment | grep -v '^-' | sed 's/=\(.*\)$/=\"\1\"/'` unset `tmux show-environment | grep '^-' | sed 's/^-//'` export `tmux show-environment | grep -v '^-' | sed 's/=\(.*\)$//'` fi # check DISPLAY if [ -n "${DISPLAY}" ] ; then exec chrome "$@" fi # if not DISPLAY exec lynx "$@" And when I launch the command: $ echo 'http://www.openbsd.org/' | urlview 3 new descriptors against "tty" are opened and not closed after the command. There are directly correlate with the 3 "tmux show-environment" in the script. I don't remind exactly the purpose of updating the environnement in the script... should be to keep kerberos ticket or display environnement in text-mode ... but ? Additionnaly, running the url_hander alone (without urlview) don't trigger the problem. I will disabling the part of "updating environment" in my script (and if I always need it, I will recall when something won't work !) I will post when I have more info. Please let me known if more informations are needed. Thanks. -- Sebastien Marie