Please use the Apache issue tracking system for new NetBeans issues ( !!

Bug 194328

Summary: cannot execute on Win 7: Unable to start pty process
Product: cnd Reporter: Thomas Preisler <thp>
Component: executionAssignee: Andrew Krasny <akrasny>
Status: RESOLVED DUPLICATE QA Contact: issues <>
Priority: P2 CC: apepin
Version: 7.0   
Target Milestone: TBD   
Hardware: PC   
OS: Other   
Issue Type: DEFECT Exception Report:
Attachments: screen shot

Description Thomas Preisler 2011-01-13 21:47:30 UTC
Today I'm getting this when trying to run Welcome on Windows 7:

Unable to start pty process: 

It wors fine with the 'Standard Output' output window.
Comment 1 Thomas Preisler 2011-01-13 21:58:46 UTC
INFO []: [26527 ms.] Error occurred: Unable to start pty process: Unable to start pty process: 
        at org.netbeans.modules.nativeexecution.PtyNativeProcess.create(
[catch] at org.netbeans.modules.nativeexecution.AbstractNativeProcess.createAndStart(
        at org.netbeans.modules.nativeexecution.api.execution.NativeExecutionService$
        at org.netbeans.modules.nativeexecution.api.execution.NativeExecutionService$
        at java.util.concurrent.FutureTask$Sync.innerRun(
        at org.openide.util.RequestProcessor$
        at org.openide.util.RequestProcessor$
Comment 2 Andrew Krasny 2011-01-17 11:53:03 UTC

please provide some details... 
Is it 64-bit or 32-bit OS? 
What toolchain was used? Do you have msys/cygwin? Versions? Do you use profiling?
can you start pty process outside the IDE (in shell's terminal, cd to netbeans/ide/bin/nativeexecution/Windows-x86/ and run ./pty)? 

Are you getting this error every time you try to start the project, or it's just a single failure?


are you able to reproduce the problem? (I've just tried on my Win7 distribution and it works)

Comment 3 Leonid Lenyashin 2011-01-18 16:31:09 UTC
Please reopen when more details provided.
Comment 4 Alexander Pepin 2011-01-18 16:55:17 UTC
I can not reproduce this either.
Comment 5 Thomas Preisler 2011-01-18 17:55:07 UTC
I'm running Win 7 in Virtual Box on my Mac. I believe it is a 32 bit version. I'm using Cygwin and MinGW, and I believe it is happening with both chains (has the tool chain anything to do with running a simple app as Welcome?). I'm using all standard setup so profiler is enabled and it is (was) happening every time I tried to run it (Welcome). Will try again with today's version and see if it is reproducible and re-open if it is.
Comment 6 Thomas Preisler 2011-01-18 22:01:24 UTC
OK, here are the details:

Using Win 7 32 bit version on Virtual Box image on a MAC

Using Cygwin and MinGW and it fails with both tool chains (tool chain probably doesn't matter when running a simple app like Welcome).

It happens every time I run in terminal Window

It works fine in standard output window.

./pty in netbeans/ide/bin/nativeexecution/Windows-x86 doesn't run in my MSys terminal window. See attached screen shot.

./pty does run in my cygwin termina window.

I installed a build and ran it from the desktop icon and it fails too. Not sure how MinGW is involved here.

If I run NetBeans from a MinGW window, it also doesn't work.

I opened the bug again. Please feel free to downgrade or close if you think it is an isolated case.
Comment 7 Thomas Preisler 2011-01-18 22:03:20 UTC
Created attachment 105120 [details]
screen shot
Comment 8 Thomas Preisler 2011-01-18 22:25:09 UTC
Cygwin version:

CYGWIN_NT-6.1 thp-PC 1.5.25(0.156/4/2) 2008-06-12 19:34 i686 Cygwin 

Is this OK? Incompatible? Too old?
Comment 9 Thomas Preisler 2011-01-18 22:54:56 UTC
Upgraded Cygwin to

CYGWIN_NT-6.1 thp-PC 1.7.7(0.230/5/3) 2010-08-31 09:58 i686 Cygwin 

and now it works. So, please feel free to close as 'using unsupported version' is that is the case. Or perhaps pty should be relinked with older Cygwin library to be compatible?
Comment 10 Alexander Pepin 2011-01-19 10:26:27 UTC
Cygwin 1.7.* should be used on Windows 7 instead of 1.5.* which was developed before Windows 7. At the same time users on WinXP/Vista can continue using cygwin 1.5.* (WinXP SP3 is a primary NB 7.0 platform).
Comment 11 Alexander Pepin 2011-01-19 15:42:20 UTC
Closed as CND works fine with cygwin 1.7.7 on both WinXP and Windows 7.
Comment 12 72VanMojick 2013-09-13 08:37:31 UTC
Please look this Web to solve this trouble, please:
Comment 13 72VanMojick 2013-09-13 08:40:53 UTC
(In reply to 72VanMojick from comment #12)
> Please look this Web to solve this trouble, please:

Please, sure before ,that you have installed the compiler, debugger, make and plugin c/c++.
Maybe you should use External terminal, try it.
Comment 14 niamtni 2013-10-05 03:57:39 UTC
I'm able to reproduce the defect using a newer version of Cygwin. 

Here's my system config: 

CYGWIN_NT-6.1 srihari-PC 1.7.25(0.270/5/3) 2013-08-31 20:37 x86_64 Cygwin
Product Version: NetBeans IDE 7.3.1 (Build 201306052037)
Java: 1.7.0_25; Java HotSpot(TM) 64-Bit Server VM 23.25-b01
Runtime: Java(TM) SE Runtime Environment 1.7.0_25-b17
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)

I'm running the sample Welcome app, and it gives me the following error when i try on internal terminal. 

Unable to start pty process: 
RUN FAILED (exit value -2, total time: 97ms)

When i switch to "Standard terminal", i see the following: 

    729 [main] welcome_1 8732 C:\Users\srihari\Documents\NetBeansProjects\Welcome_1\dist\Debug\Cygwin_4.x-Windows\welcome_1.exe: *** fatal error - error while loading shared libraries: /cygdrive/C/Program Files/NetBeans 7.3.1/ide/bin/nativeexecution/Windows-x86/unbuffer.dll: cannot open shared object file: Exec format error
  30452 [main] welcome_1 8732 open_stackdumpfile: Dumping stack trace to welcome_1.exe.stackdump
RUN FAILED (exit value 256, total time: 1s)

As Thomas observed, this is fine when I run the program on "External Terminal".
Comment 15 soldatov 2013-10-05 07:49:12 UTC

*** This bug has been marked as a duplicate of bug 234221 ***
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo