sudo -i then cd /sys/ then find -D stat . -type f -exec strings --print-file-name '{}' \; > /tmp/out.txt

Asked by penalvch

Trying to debug:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/834528

sudo -i

then:
cd /sys/

then:
find -D stat . -type f -exec strings --print-file-name '{}' \; > /tmp/out.txt

stops at:
debug_stats (events)

I'm not a subject matter expert on findutils. However, I am just looking for some information on:
+ Why does this query stop at debug_stats (events)? Is this a bug in findutils?

Thanks!

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu findutils Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

the commands after sudo -i wi;l not be ran until the command finishes as it is interactive sudo. the next command will be ran as the user.

what are you trying to achieve? there may be an easier solution....

Revision history for this message
penalvch (penalvch) said :
#2

See amended question.

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#3

Massively different.

What are you trying to achieve?

Revision history for this message
penalvch (penalvch) said :
#4

actionparsnip, please don't answer questions with questions. If you cannot answer my original question I will have to wait for a subject matter expert to answer it. Thanks!

Revision history for this message
Ralph Corderoy (ralph-inputplus) said :
#5

Try appending " 2>&1" to the end of your command.

    find -D stat . -type f -exec strings --print-file-name {} \; >/tmp/out.txt 2>&1

-D's output is on stderr so is not going to /tmp/out.txt but to the terminal. It is unclear from your description if find hangs at that debug(...) line or whether the shell prompt appears on simply pressing Enter.

As actionparsnip says, what's your aim? You're telling us some of the actual behaviour without the desired behaviour.

Can you help with this problem?

Provide an answer of your own, or ask penalvch for more information if necessary.

To post a message you must log in.