Smlnj interactive system: fatal error

Having received a strange error on my Crouton chroot on my Chromebook after apt-get install smlnjand trying to call smlfrom the terminal, this is an error that I could not find anywhere:

$ sml
/usr/lib/smlnj/bin/sml: Error -- unable to map 1179648 bytes, errno = 1
/usr/lib/smlnj/bin/sml: Fatal error -- unable to allocate memory object for BIBOP

Any directions?

+4
source share
1 answer

: ( № 120) ​​ SML/NJ 110.77 ( ) MAP_ANONYMOUS, Linux. SMLNJ , . /dev, exec .


Chromium OS, ChrUbuntu Crouton, , .

strace on sml () :

open("/dev/zero", O_RDONLY)             = 4
mmap2(NULL, 1245184, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE, 4, 0) = -1 EPERM (Operation not permitted)

mmap (2), EPERM , , noexec.

, mount :

...
devtmpfs on /dev type devtmpfs (rw,nosuid,noexec,relatime,size=960456k,nr_inodes=240114,mode=755)
...

, , /dev exec:

$ sudo mount -o remount,exec /dev
$ sml
Standard ML of New Jersey v110.75 [built: Thu May  9 05:41:01 2013]
- 
+4

Source: https://habr.com/ru/post/1540795/


All Articles