[erlang-questions] Could not open pty master

zxq9 zxq9@REDACTED
Thu Sep 25 03:21:12 CEST 2014


On Wednesday 24 September 2014 21:00:32 Iván Martínez wrote:
> Hello all,
> Does anyone know why I'm having the following issue with a CentOS 7 system
> with kernel 3.10.23?:
> 
> $ run_erl priv/ log "erl"
> run_erl:187 [6505] Wed Sep 24 18:42:39 2014
> errno=1 'Operation not permitted'
> Could not open pty master
> 
> It works as super user. It also works in a Fedora 20 system with kernel
> 3.16. I couldn't find any difference in user groups or /dev file permits
> between both systems. Starting with a user with UID above or below UID_MIN
> doesn't make any difference.  I don't think it matters, but the only
> difference I could find is that the CentOS has many /dev/pty* files already
> created, while the Fedora doesn't have any.

You might be running into SELinux permission issues. To find out try doing 
"setenforce 0" and then running it again. If that works, use a tool like 
audit2allow or audit2why to create a policy that will permit the actions you 
require to run your program. I haven't kept up with the Fedora/RHEL world 
since 7 came out, but Dan Walsh's blog and Red Hat's SELinux docs have been 
good resources on this in the past.

Of course, you might have a totally different issue, but SELinux booleans and 
audit logs are the first thing I check on a Fedora-type distro when something 
doesn't work but looks like it should.



More information about the erlang-questions mailing list