In Windows 3.02 64-bit system, when cygwin is used to run the liunux program, the following error occurs: Bash-$:
The reason is:
In the 64-bit operating system, the 32 program and the 64-bit program read the location registry key, in the 64-bit Registry Editor, HKEY_LOCAL_MACHINE \ SOFTWARE corresponds to the registry key of the 64-bit program, and the 32-bit registry key is mapped to HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node. If both versions are required to take effect, you must modify the table items in both versions.
References: http://www.cnblogs.com/TianFang/archive/2011/08/07/2129872.html
So save the following content and save it as a. reg file. Then double-click it to solve the problem:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions]
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin]
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin \ mounts V2]
"Cygdrive prefix" = "/cygdrive"
"Cygdrive flags" = DWORD: 00000022
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin \ mounts V2 \/]
"Native" = "C: \ cygwin"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin \ mounts V2 \/usr/bin]
"Native" = "C: \ cygwin/bin"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin \ mounts V2 \/usr/lib]
"Native" = "C: \ cygwin/lib"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ Cygnus solutions \ cygwin \ Program Options]
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions]
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin]
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin \ mounts V2]
"Cygdrive prefix" = "/cygdrive"
"Cygdrive flags" = DWORD: 00000022
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin \ mounts V2 \/]
"Native" = "C: \ cygwin"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin \ mounts V2 \/usr/bin]
"Native" = "C: \ cygwin/bin"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin \ mounts V2 \/usr/lib]
"Native" = "C: \ cygwin/lib"
"Flags" = DWORD: 0000000a
[HKEY_LOCAL_MACHINE \ SOFTWARE \ wow6432node \ Cygnus solutions \ cygwin \ Program Options]