All Forums |
Register |
Login |
Search |
Subscriptions |
My Profile |
Inbox |
Tool Warehouse |
FAQs |
Resources |
Help |
Member List |
Address Book |
Logout |
|
|
posix.exe hangs - can't run any shell
|
Logged in as: Guest |
Users viewing this topic: none |
|
Login  |
|
|
posix.exe hangs - can't run any shell - Dec. 23, '05, 8:31:33 AM
|
|
|
gk
Posts: 6
Joined: Nov. 23, '05,
Status: offline
|
I have installed SFU 3.5 with all available hotfixes, read the documentation, etc. but cannot launch any shell via posix.exe, such as:
C:\WINDOWS\system32\POSIX.EXE /u /c /bin/ksh -l
C:\WINDOWS\system32\POSIX.EXE /u /c /bin/csh -l
When I try to execute posix.exe it seems to hang with a flashing '_' in the terminal window. I never see any kind of command prompt and have to quit with Cntl-C
Any ideas?
My system is the following:
OS: Windows XP (SP3)
CPU: AMD Athlon 64 X2 4400+
Board: ASUS A8N-SLI Premium (nVidia nForce 4 SLI chipset)
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 9:31:07 AM
|
|
|
cortez_
Posts: 330
Joined: Mar. 27, '04,
From: Poland
Status: offline
|
Have you turned the DEP off? http://www.interopsystems.com/tools/faqs.aspx#20
by the way when did Microsoft release the SP3 for WinXP??
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 10:40:26 AM
|
|
|
gk
Posts: 6
Joined: Nov. 23, '05,
Status: offline
|
Thanks for the reply.
I read the FAQ and tried turning DEP AlwaysOff by editing boot.ini:
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /noexecute=AlwaysOff /fastdetect
I have rebooted but still cannot launch ksh and am seeing the error in my log:
cannot connect to Interix subsystem.
My reference to running XP "SP3" was terminology I came upon using "System Information for Windows (SIW)" - it means that hotfixes to SP2 have been applied. Perhaps this is an uncommon vernacular.
- Greg
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 1:37:20 PM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
Check the registry entries also (a different entry in the FAQ) to see they have not been clobbered.
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 2:30:16 PM
|
|
|
gk
Posts: 6
Joined: Nov. 23, '05,
Status: offline
|
If you are referring to this:
1.02 – Cannot connect to Interix subsystem, Interix will not start
I already edited the registry and have just now checked again to verify these settings:
HKLM->SYSTEM->CurrentControlSet\Control\Session Manager\SubSystems\Posix = "%SystemRoot%\system32\psxss.exe"
HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\SubSystems\Optional = "Posix"
However, the FAQ did not mention that I would actually have to CREATE the first key from scratch. Does the prior non-existence of this key in my system indicate that something is wrong?
I used regedit to create key:
HKLM->SYSTEM->CurrentControlSet\Control\Session Manager\SubSystems\Posix
I could not edit these default attributes of the key:
Name = (Default)
Type = REG_SZ
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 3:43:47 PM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
Given you were running before you shouldn't have needed to create the keys.
That the key is missing indicates something came along and removed it.
If things still aren't running after setting the registry, DEP and rebooting then
whatever mucked with the registry may have done more. The SFU installation includes
a Win32 program called "fileinfo". Try running that. It'll tell us the file version
info (and if the files are missing). It's in the C:\SFU\bin directory.
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 23, '05, 5:49:00 PM
|
|
|
gk
Posts: 6
Joined: Nov. 23, '05,
Status: offline
|
quote:
ORIGINAL: Rodney
Given you were running before you shouldn't have needed to create the keys.
I'm not sure what you mean by 'running'.
I have been running XP but I don't think SFU has ever been 'running'.
I don't think I'm running any SFU server components, such as NFS server, telnet server, etc.
I installed SFU 3.5 and the installer ended normally.
I tried running the 'Services for Unix Administration' tool and it seemed to work (didn't crash) but I didn't change anything or try to do anything with it.
The only other thing in SFU (other than fileinfo) that I've run successfully is telnet.exe (though I'm not sure if this is technically part of SFU, though I think the docs said that SFU install modified the original telnet.exe).
Here is my fileinfo output:
C:\SFU\bin>fileinfo
/dev/fs/C/WINDOWS/system32/PSXSS.EXE 8.0.1969.36
/dev/fs/C/WINDOWS/system32/PSXDLL.DLL 8.0.1969.36
/dev/fs/C/WINDOWS/system32/POSIX.EXE 8.0.1969.36
/dev/fs/C/WINDOWS/system32/PSXRUN.EXE 8.0.1969.36
/dev/fs/C/WINDOWS/system32/drivers/PSXDRV.SYS 8.0.1969.1
The only thing I want SFU for is to allow me to run some unix utilities on my local machine, specifically, rsync and bash - I have been using Cygwin for years and it is just too slow. SFU seemed like the best way to go.
Maybe my hardware is the problem. The only thing else I can think of is possibly the firewall, ZoneAlarm Suite - but I have tried turning that off and it doesn't seem to help SFU at all. I have scanned for viruses and nothing is found. I am scanning again now, just to be sure.
There is nothing I can think of that would disable SFU keys in the registry or delete keys, etc. (I don't think SFU installer ever created the SubSystems\Posix registry key in the first place.)
I really appreciate any help you can offer!
|
|
|
RE: posix.exe hangs - can't run any shell - Dec. 28, '05, 11:59:42 PM
|
|
|
gk
Posts: 6
Joined: Nov. 23, '05,
Status: offline
|
Well, no response from the forum so...
When in all else fails - re-install!
This fixed my problem. At least ksh runs :-)
I re-installed SFU. The differences from prior use:
0. DEP was already turned OFF, prior to the install
1. I enabled setuid at install time (previously I had enabled it after the install)
2. I re-evaluated the FAQ instructions on editing the registry and decided I may have misinterpreted it: I deleted the "Posix" Key I had created and replaced this with a new "Expandable String Value" (REG_EXPAND_SZ)
HKLM->SYSTEM->CurrentControlSet\Control\Session Manager\SubSystems\Posix = "%SystemRoot%\system32\psxss.exe"
3. I applied Hotfix 904358 (no other hotfixes applied). Rebooted.
Immediately upon reboot, I was heartened to see my firewall asking if SFU could access the internet, etc. - this had never happened in previous install (nothing had been working).
I hope this info may help some other hapless soul.
- Greg
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 12:12:56 AM
|
|
|
aleem
Posts: 5
Joined: Feb. 17, '06,
Status: offline
|
Hi gk:
I have the same problem. csh and ksh hang, and psxrun.exe (which is the startup system for psxss.exe) all hang and after some time report the error "cannot connect to Interix subsystem".
I had to *CREATE* the Posix key from scratch, as you said, and I had it set as REG_SZ.
My initial install included setuid, but DEP was not off at the time of install.
I have not reinstalled yet, and have had no success with the following:
1. Setting the Posix registry key to type REG_EXPAND_SZ
2. Setting DEP to off by modifying the boot.ini line
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /noexecute=AlwaysOff /fastdetect
I will post my findings after re-installing.
Where can I find hotfix 904358? Why did you install it? The windows KB article at:
http://support.microsoft.com/default.aspx?scid=kb;en-us;904358
says it is for something else.
Thanks for your help so far.
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 1:51:04 AM
|
|
|
aleem
Posts: 5
Joined: Feb. 17, '06,
Status: offline
|
I reinstalled (by selecting the "reinstall" option) with the above settings and it began to work.
Note that I did not need to install any hotfix.
My version information is as follows
aleem@L1244> fileinfo
/dev/fs/C/WINDOWS/system32/PSXSS.EXE 8.0.1969.2
/dev/fs/C/WINDOWS/system32/PSXDLL.DLL 8.0.1969.1
/dev/fs/C/WINDOWS/system32/POSIX.EXE 8.0.1969.1
/dev/fs/C/WINDOWS/system32/PSXRUN.EXE 8.0.1969.1
/dev/fs/C/WINDOWS/system32/drivers/PSXDRV.SYS 8.0.1969.1
Thanks for all your help!
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 1:54:16 AM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
> I had to *CREATE* the Posix key from scratch, ...
This indicates that another program (not from MS BTW) clobbered the registry.
Often a "security" program (which have varied over the years). What it was with gk I don't know.
The registry key information is in the FAQ section 1.02.
After any registry change you need to reboot.
DEP won't affect the subsytem starting. It affects programs built using gcc as the compiler.
Subsystem jewels versioned as 8.0.1969.36 is the latest hotfix. The hotfixes
are cumulative. There have been several hotfixes before. So while the KB article specifically
addresses "what's new in this hotfix", you have to read through all of the previous articles
to find what all of the changes are. You can get the latest hotfix from MS for free by bugging
support (aka PSS) by phone or e-mail. It's not in a common MS download site (no I don't know
why this is the policy). They may ask for a CC number, but they shouldn't charge you for it.
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 3:39:46 AM
|
|
|
aleem
Posts: 5
Joined: Feb. 17, '06,
Status: offline
|
Thanks Rodney:
I rebooted after each registry change.
In the end it was only the re-installation that fixed the problem.
As I said, I had made sure that all the Registry Keys were as outlined in the FAQ section 1.02.
I don't beleive you (yet) when you say that the Posix key would have existed in the windows registry from the start. Why would MS put a registry key named "Posix" on a windows fresh install?
Did you mean that the Windows Interix installer put the Posix key in, and then my security program (Trend Micro) deleted it?
Why then didn't this installer verify (and replace) the other registry keys during installation?
Overall, maybe the next version of the installer should verify and do the registry change for us.
To confirm if the Posix key exists there from the beginning or not, I will check on another PC and get back to you.
Overall though, this is a great product. Thanks
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 4:26:52 AM
|
|
|
aleem
Posts: 5
Joined: Feb. 17, '06,
Status: offline
|
OK Rodney:
It is as you said. Non "clobbered" systems have the two keys.
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 18, '06, 11:22:24 AM
|
|
|
markfunk
Posts: 673
Joined: Mar. 31, '03,
Status: offline
|
quote:
Why would MS put a registry key named "Posix" on a windows fresh install?
This registry key has been in all versions of Windows NT. It was there to support their POSIX subsystem.
Eventually MS removed their POSIX subsystem (but not the keys) from the default OS installs (I think this was true in WinXP) and they replaced it with the Interix subsystem available via MS Interix 2.2 and then SFU 3.5.
To satisfy US gov't security requirements, all software that wasn't taken through a security review process couldn't be part of a "secure" Windows system. There are programs that claim to make your Windows systems "secure" by eliminating any non-approved software. These programs typically removes these registry entries to ensure non-approved subsystems will not run on this type of secure Window's system.
Adding these registry entries, to get Interix to run, invalidates your "secure" system status (if you actually care about this sort of thing).
|
|
|
RE: posix.exe hangs - can't run any shell - Feb. 19, '06, 4:19:21 PM
|
|
|
aleem
Posts: 5
Joined: Feb. 17, '06,
Status: offline
|
Thanks markfunk.
I had no idea.
Perhaps, as I had suggested, the next version of the installer should check for the existence of these keys, and if they are missing, it would provide a security warning during installation to outline what you explained, asking the user to accept or reject this. If the user accepts, then the installer would add the registry keys before continuing. If the user rejects, the installer would abort and cleanup.
Thanks for a great set of tools. Feel free to move this post to the "wishlist" section.
|
|
|
RE: posix.exe hangs - can't run any shell - Mar. 20, '06, 5:03:41 PM
|
|
|
suchko
Posts: 1
Joined: Mar. 20, '06,
Status: offline
|
I had the same problem with the "cannot connect to Interix subsybsystem". FYI...I DID NOT need to reinstall SFU.
What I did do to get it working is ...
1) I obtained hotfix 904358 with the latest and greatest versions of all files since I read someplace that you needed all to be at least at versioo x.x.x.2 and some of mine were x.x.x.1 (this updated them to x.x.x.36), installed it and rebooted.
2) Added the Optional and Posix values to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\SubSystems in the registry as mentioned above. IT IS IMPORTANT TO USE REGEDT32 (not regedit) so as to add the proper type of string values for these (EXPAND for Posix the and MULTI for the Optional) otherwise these values will NOT work.
|
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
|
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts |
|
|
|