[orocosusers] getting a permission denied on deployers after running setcap for soem

Hi all,

I am running indigo+14.04,

i need to use the soem master, I execute

sudo setcap cap_net_raw+ep /opt/ros/indigo/bin/rttlua-gnulinux

after doing that calling the rttlua gives

$ rttlua-gnulinux
Real-time memory: 517904 bytes free of 524288 allocated.
0.023 [ ERROR ][Thread] Failed to set thread name for lua: Permission
denied
0.023 [CRITICAL][Thread] Could not create thread lua.
pure virtual method called
terminate called without an active exception
Aborted (core dumped)

something similar happens also for the normal deployer (after the setcap
command).

$ deployer
Real-time memory: 517904 bytes free of 524288 allocated.
0.024 [ ERROR ][Thread] Failed to set thread name for Deployer:
Permission denied
0.025 [CRITICAL][Thread] Could not create thread Deployer.
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc
Aborted (core dumped)

if I reinstall the debian package (ros-indigo-ocl) the exectuables are
overwritten, and this problem is not present anymore (but i cannot
configure the SOEM master component...)

any ideas?

Cheers, Gianni.

[orocosusers] getting a permission denied on deployers after run

Hi Gianni,

I could reproduce this issue and also found your post on StackExchange:
http://unix.stackexchange.com/questions/308622/cap-net-raw-influences-pt...

Apparently this patch is responsible for the regression:
https://github.com/orocos-toolchain/rtt/pull/128 in combination with
https://github.com/orocos-toolchain/rtt/commit/bc05dceed2f123c35893bf003...

I also cannot explain why the capability set influences pthread_setname_np,
but I will create a hotfix for 2.8.3 and rerelease it into ROS. A failure
the set the name of the thread should not lead to the termination of the
process.

Cheers,
Johannes

On Thu, Sep 8, 2016 at 11:03 AM, Gianni Borghesan <
gianni [dot] borghesan [..] ...> wrote:

> Hi all,
>
> I am running indigo+14.04,
>
> i need to use the soem master, I execute
>
> sudo setcap cap_net_raw+ep /opt/ros/indigo/bin/rttlua-gnulinux
>
>
> after doing that calling the rttlua gives
>
> $ rttlua-gnulinux
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.023 [ ERROR ][Thread] Failed to set thread name for lua: Permission
> denied
> 0.023 [CRITICAL][Thread] Could not create thread lua.
> pure virtual method called
> terminate called without an active exception
> Aborted (core dumped)
>
>
> something similar happens also for the normal deployer (after the setcap
> command).
>
> $ deployer
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.024 [ ERROR ][Thread] Failed to set thread name for Deployer:
> Permission denied
> 0.025 [CRITICAL][Thread] Could not create thread Deployer.
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
> Aborted (core dumped)
>
> if I reinstall the debian package (ros-indigo-ocl) the exectuables are
> overwritten, and this problem is not present anymore (but i cannot
> configure the SOEM master component...)
>
> any ideas?
>
> Cheers, Gianni.
>
>
> --
> ------------------------------------------------
> Gianni Borghesan, PhD
> Robot Assisted Surgery group
> Robotics Research group
> KU Leuven,
> Department of Mechanical Engineering,
> Division of PMA
> Room 02.019
> Celestijnenlaan 300B, B-3001 Heverlee, Belgium.
> Tel: +32 163 29267
>
> ------------------------------------------------
>

Ruben Smits's picture

[orocosusers] getting a permission denied on deployers after run

Which kernel version are you using?

R.

On Thu, Sep 8, 2016 at 11:03 AM Gianni Borghesan <
gianni [dot] borghesan [..] ...> wrote:

> Hi all,
>
> I am running indigo+14.04,
>
> i need to use the soem master, I execute
>
> sudo setcap cap_net_raw+ep /opt/ros/indigo/bin/rttlua-gnulinux
>
>
> after doing that calling the rttlua gives
>
> $ rttlua-gnulinux
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.023 [ ERROR ][Thread] Failed to set thread name for lua: Permission
> denied
> 0.023 [CRITICAL][Thread] Could not create thread lua.
> pure virtual method called
> terminate called without an active exception
> Aborted (core dumped)
>
>
> something similar happens also for the normal deployer (after the setcap
> command).
>
> $ deployer
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.024 [ ERROR ][Thread] Failed to set thread name for Deployer:
> Permission denied
> 0.025 [CRITICAL][Thread] Could not create thread Deployer.
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
> Aborted (core dumped)
>
> if I reinstall the debian package (ros-indigo-ocl) the exectuables are
> overwritten, and this problem is not present anymore (but i cannot
> configure the SOEM master component...)
>
> any ideas?
>
> Cheers, Gianni.
>
>
> --
> ------------------------------------------------
> Gianni Borghesan, PhD
> Robot Assisted Surgery group
> Robotics Research group
> KU Leuven,
> Department of Mechanical Engineering,
> Division of PMA
> Room 02.019
> Celestijnenlaan 300B, B-3001 Heverlee, Belgium.
> Tel: +32 163 29267
>
> ------------------------------------------------
>

[orocosusers] getting a permission denied on deployers after run

Hi Ruben,

On 08/09/16 15:00, Ruben Smits wrote:
> Which kernel version are you using?

Linux version 3.19.0-68-generic (buildd@lcy01-32) (gcc version 4.8.4
(Ubuntu 4.8.4-2ubuntu1~14.04.3) ) #76~14.04.1-Ubuntu SMP Fri Aug 12
11:46:25 UTC 2016

>
> R.
by the way, if i run as a superuser, rttlua works, so it is probably
some issue related to permissions on functions such as pthread_create...

>
> On Thu, Sep 8, 2016 at 11:03 AM Gianni Borghesan
> <gianni [dot] borghesan [..] ... gianni [dot] borghesan [..] ...>>
> wrote:
>
> Hi all,
>
> I am running indigo+14.04,
>
> i need to use the soem master, I execute
>
> sudo setcap cap_net_raw+ep /opt/ros/indigo/bin/rttlua-gnulinux
>
>
> after doing that calling the rttlua gives
>
> $ rttlua-gnulinux
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.023 [ ERROR ][Thread] Failed to set thread name for lua: Permission
> denied
> 0.023 [CRITICAL][Thread] Could not create thread lua.
> pure virtual method called
> terminate called without an active exception
> Aborted (core dumped)
>
>
> something similar happens also for the normal deployer (after the
> setcap
> command).
>
> $ deployer
> Real-time memory: 517904 bytes free of 524288 allocated.
> 0.024 [ ERROR ][Thread] Failed to set thread name for Deployer:
> Permission denied
> 0.025 [CRITICAL][Thread] Could not create thread Deployer.
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
> Aborted (core dumped)
>
> if I reinstall the debian package (ros-indigo-ocl) the exectuables are
> overwritten, and this problem is not present anymore (but i cannot
> configure the SOEM master component...)
>
> any ideas?
>
> Cheers, Gianni.
>
>
> --
> ------------------------------------------------
> Gianni Borghesan, PhD
> Robot Assisted Surgery group
> Robotics Research group
> KU Leuven,
> Department of Mechanical Engineering,
> Division of PMA
> Room 02.019
> Celestijnenlaan 300B, B-3001 Heverlee, Belgium.
> Tel: +32 163 29267
>
> ------------------------------------------------
>