Failed to set scheduler settings: Operation not permitted ( EPERM ) ( glib >= 2.63.4 )
After recent changes in glib GThreadPool code ( as below )
linux_pthread_proxy() calls sched_setattr syscall as below:
static void *
linux_pthread_proxy (void *data)
{
GThreadPosix *thread = data;
/* Set scheduler settings first if requested */
if (thread->scheduler_settings)
{
pid_t tid = 0;
guint flags = 0;
int res;
tid = (pid_t) syscall (SYS_gettid);
res = syscall (SYS_sched_setattr, tid, thread->scheduler_settings->attr, flags);
if (res == -1)
g_error ("Failed to set scheduler settings: %s", g_strerror (errno));
}
return thread->proxy (data);
}
Error message from journactl:
[crvi@localhost ~]$ journalctl /usr/libexec/tracker-extract /usr/libexec/tracker-miner-fs
...
...
-- Reboot --
Feb 04 13:12:25 localhost.localdomain tracker-miner-f[1898]: Failed to set scheduler settings: Operation not permitted
Feb 04 13:12:25 localhost.localdomain audit[1898]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=3 pid=1898 comm="tracker-miner-f" exe="/usr/libexec/tracker-miner-fs" sig=5 res=1
Feb 04 13:12:34 localhost.localdomain tracker-extract[1804]: Failed to set scheduler settings: Operation not permitted
Feb 04 13:12:34 localhost.localdomain audit[1804]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=3 pid=1804 comm="tracker-extract" exe="/usr/libexec/tracker-extract" sig=5 res=1
-- Reboot --
Feb 08 21:50:42 localhost.localdomain tracker-miner-f[1936]: Failed to set scheduler settings: Operation not permitted
Feb 08 21:50:42 localhost.localdomain audit[1936]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=3 pid=1936 comm="tracker-miner-f" exe="/usr/libexec/tracker-miner-fs" sig=5 res=1
Feb 08 21:51:02 localhost.localdomain tracker-extract[1867]: Failed to set scheduler settings: Operation not permitted
Feb 08 21:51:02 localhost.localdomain audit[1867]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=3 pid=1867 comm="tracker-extract" exe="/usr/libexec/tracker-extract" sig=5 res=1