jails Error in jail: *ERROR*: Could not open file: /dev/pts/0

When I run Emacs client inside jail I get the following error:

Code:
# emacsclient --create-frame --alternate-editor='' --socket-name=test
*ERROR*: Could not open file: /dev/pts/0

Jail config (/etc/jail.conf):

Code:
allow.chflags=1;
exec.clean;
exec.stop = "/bin/sh /etc/rc.shutdown";
ip4=inherit;
mount.devfs;
exec.start = "/bin/sh /etc/rc";

allow.raw_sockets;
allow.sysvipc;

myjail {
        path="/myjail";
}

Expected behavior is to open the console version of the Emacs editor in terminal. In other cases, it works fine, Emacs opens.

Other cases when it works without errors:
  • inside tmux, which is running inside jail.
  • with or without tmux, just in the command line of the host server outside the jail.
  • Emacs (not Emacs client) works in all cases.
I tried changing the permissions on the file /dev/pts/0, but it didn't help. I hope this issue can be solved by one line in /etc/jail.conf, which I just don't know.
 
Back
Top