All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Andrey Nechypurenko <andreynech@googlemail.com>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] rt_task_create fails when running over ssh
Date: Sun, 04 Nov 2012 18:05:28 +0100	[thread overview]
Message-ID: <5096A058.30204@xenomai.org> (raw)
In-Reply-To: <CAOiXNkDY0aofK=woRrF8+Uh0LZVPjx8qVLB6DUVS+xhmKsyB3g@mail.gmail.com>

On 11/04/2012 05:43 PM, Andrey Nechypurenko wrote:

> On 4 November 2012 17:30, Gilles Chanteperdrix
> <gilles.chanteperdrix@xenomai.org> wrote:
>> On 11/04/2012 05:13 PM, Andrey Nechypurenko wrote:
>>
>>> On 3 November 2012 22:34, Gilles Chanteperdrix
>>> <gilles.chanteperdrix@xenomai.org> wrote:
>>>> On 11/03/2012 10:32 PM, Andrey Nechypurenko wrote:
>>>>
>>>>>> Use the DESTDIR environment variable (you can look inside xeno-config to
>>>>>> see how it works, it should be pretty obvious).
>>>>>
>>>>> Thanks for the hint. I'll definitely try. However I doubt that it
>>>>> would solve the issue with rt_task_create() since I were actually
>>>>> copy-pasting the output from xeno-config and only change the -I and -L
>>>>> flags to reflect my directory structure.
>>>>
>>>>
>>>> Yes, I also doubt that very much. What about the arm/thumb issue?
>>>
>>> I've run strace and found the following line in the output when
>>> starting the programm over ssh:
>>> sched_setscheduler(440, SCHED_FIFO, { 99 }) = -1 EPERM (Operation not permitted)
>>> I assume, that this call is the part of rt_task_create(). In contrast,
>>> the same call gets no errors if running in the serial console. Really
>>> strange to me.
>>>
>>> My attempts to change corresponding priorities with ulimit command or
>>> setrlimit() function does not solve the issue. So it seams like ssh
>>> server limits some permissions somehow which causes rt_task_create()
>>> to fail.
> 
>> Did you check if your compiler compiles thumb code or arm code by default?
> 
> objdump says: file format elf32-littlearm
> and file says: ELF 32-bit LSB executable, ARM, version 1 (SYSV)


The result is the same with thumb code. In order to know if a binary is
thumb or arm, run objdump and check if the binary contains 16 bits
instructions.

> 
>> You can run ulimit to check the current limits.
>> And it would be interesting to run the "whoami" command or use getuid()
>> in the program to check whether you are really running as the root user.
> 
> $ ulimit -a


What about whoami or id (it would be nice if did not have to ask the
same questions 3 times)?

I have 0 for scheduling priority and real-time priority, and it does not
seem to cause any issue.

-- 
                                                                Gilles.


  reply	other threads:[~2012-11-04 17:05 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-02 20:24 [Xenomai] rt_task_create fails when running over ssh Andrey Nechypurenko
2012-11-03  1:20 ` Gilles Chanteperdrix
2012-11-03  9:49   ` Andrey Nechypurenko
2012-11-03 10:55     ` Gilles Chanteperdrix
2012-11-03 14:00       ` Andrey Nechypurenko
2012-11-03 14:08         ` Gilles Chanteperdrix
2012-11-03 14:09         ` Gilles Chanteperdrix
2012-11-03 18:42           ` Andrey Nechypurenko
2012-11-03 21:19             ` Gilles Chanteperdrix
2012-11-03 21:32               ` Andrey Nechypurenko
2012-11-03 21:34                 ` Gilles Chanteperdrix
2012-11-04 16:13                   ` Andrey Nechypurenko
2012-11-04 16:27                     ` Gilles Chanteperdrix
2012-11-04 16:48                       ` Andrey Nechypurenko
2012-11-04 16:57                         ` Gilles Chanteperdrix
2012-11-04 16:30                     ` Gilles Chanteperdrix
2012-11-04 16:43                       ` Andrey Nechypurenko
2012-11-04 17:05                         ` Gilles Chanteperdrix [this message]
2012-11-04 17:14                           ` Andrey Nechypurenko
2012-11-04 17:36                             ` Gilles Chanteperdrix
2012-11-04 17:34                           ` Andrey Nechypurenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5096A058.30204@xenomai.org \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=andreynech@googlemail.com \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.