NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

Remote debug for specific user produces : "Working directory refers to non-existent path :

 
Post new topic   Reply to topic    NetBeans Forums -> C/C++ Users
View previous topic :: View next topic  
Author Message
UnhandledException



Joined: 07 Feb 2017
Posts: 6

PostPosted: Tue Feb 07, 2017 9:39 pm    Post subject: Remote debug for specific user produces : "Working directory refers to non-existent path : Reply with quote

What Works
Here is a simple sample that I used (from another thread) and it actually works.

- Local platform is Windows 7 with NetBeans 8.2 and just apply latest patches.
- Remote host is Linux and the following was created

#include <stdio.h>
#include <unistd.h>

int main(int argc, char** argv) {
for (int i = 0; i < 100; i++) {
printf("%d\n", i);
sleep(1);
}
return 0;
}

- Built the file with debug and executed it.
> g++ -g -o test test.cpp
> ./test

- On Windows In NetBeans I pressed Debug|Attach Debugger
- Selected "Gdb Debugger", "user1@host", "./test" process and "<no project>" filter
- Pressed OK button
This successfully attaches to the process and the IDE opens "test.cpp"file in Full Remote mode.

What Also Works

Now to test with my actual process (myProcess) which is a different user (User2).

- On same Windows In NetBeans I pressed Debug|Attach Debugger
- Selected "Gdb Debugger", "user2@host", "myProcess" process and "<no project>" filter
- Pressed OK button
This works!!!!!!!



What Fails

Using a different user (User3) and attempting to connect to another process (myProcess2) fails.

- On same Windows In NetBeans I pressed Debug|Attach Debugger
- Selected "Gdb Debugger", "user3@host", "myProcess2" process and "<no project>" filter
- Pressed OK button
This produces the error "Working directory refers to non-existent path : C:\"


As a test
As a test, the source code for the test procedure was removed and the same steps followed. This process still worked. Instead of the source file opening, a new window actually opens with the title "Disassembly". This is a good indication that it is unrelated to not finding the source file.


As a 2nd test, the same steps were followed but user2 was used and attempted to attached to the ./test process started by user1. Doing this generated the same error. This seems to indicate that if a user attempts to attach to a process they don't own then it generates the error.

I did verify the scenario which fails (user3 attaching to myProcess2) is owned by user3 which would indicate that the error message may be generic or there is something different about User3 and/or the associated process.

Is there anything specific to check about the user and/or process?
What else could be causing this error?
Back to top
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> C/C++ Users All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo