Troubleshooting Problems When You Have Cygwin Installed

The following problems might be related to your Cygwin installation. Refer to the related FAQs for help on troubleshooting these:

Useful Troubleshooting Tools

If you have problems with starting services or connecting to your target board, examine the .log files in the /var/log directory for more information, particularly the xinetd.log file. The Event Viewer allows you to check services log information using a graphical interface.

The cygcheck and cygpath utilities are also useful for troubleshooting problems while using Cygwin.

Event Viewer

The Windows Event Viewer monitors events recorded in the Application, Security, and System logs. You can use this to make sure a mount worked correctly. To access the Event Viewer, right-click on My Computer and select Manage. You can then click on Event Viewer in the left-hand panel, and select the information in which you are interested (in this example, the Application log):

To view more information about an item, double-click on it. Be sure to scroll to the bottom of the message if it fills up the entire text area:

cygcheck

The cygcheck utility is an all-purpose diagnostic utility.

  • The -c option allows you to check the presence and status of any packages installed on Cygwin.
$ cygcheck -c
Cygwin Package Information
Package            Version      Status
_vendor-timesys    1.0.0-1      Incomplete
a2ps               4.13-1       OK
agetty             2.1-1        OK
alternatives       1.3.20a-2    OK
antiword           0.34-2       OK
apache             1.3.33-2     Incomplete
apache2            2.0.55-1     OK
apache2-devel      2.0.55-1     OK
apache2-manual     2.0.55-1     OK
apr                0.9.7-1      OK
... 
  • The -s option allows you to check diagnostic system information:
$ cygcheck -s
Cygwin Configuration Diagnostics
Current System Time: Tue Jul 25 15:35:23 2006

Windows XP Professional Ver 5.1 Build 2600 Service Pack 2

Path: C:\Cygwin\usr\local\bin
C:\Cygwin\bin
C:\Cygwin\bin
C:\Cygwin\usr\X11R6\bin
c:\WINDOWS\system32
c:\WINDOWS
c:\WINDOWS\system32\WBEM
C:\Cygwin\bin
C:\Cygwin\opt\timesys
C:\Cygwin\opt\timesys\bin
C:\Cygwin\lib\lapack

Output from C:\Cygwin\bin\id.exe (nontsec)
UID: 1006(Liz) GID: 513(None)
0(root) 513(None) 544(Administrators) 545(Users)

Output from C:\Cygwin\bin\id.exe (ntsec)
UID: 1006(Liz) GID: 513(None)
0(root) 513(None) 544(Administrators) 545(Users)

SysDir: C:\WINDOWS\system32
WinDir: C:\WINDOWS

USER = 'juser'
PWD = '/home/juser'
HOME = '/home/juser'
MAKE_MODE = 'unix'

Use '-r' to scan registry

c: hd NTFS 60000Mb 76% CP CS UN PA FC ComputerName
d: hd FAT32 4987Mb 88% CP UN SHARED
e: cd N/A N/A
f: hd N/A N/A
g: net NTFS 100037Mb 94% CP CS UN PA FC Data
h: net NTFS 100037Mb 94% CP CS UN PA FC Data
i: net NTFS 100037Mb 94% CP CS UN PA FC Data
j: hd FAT 39Mb 5% CP UN TCVOLUME

C:\Cygwin / system binmode
C:\Cygwin/bin /usr/bin system binmode
...

cygpath

The cygpath utility translates between Cygwin-style and Windows-style paths.

  • Use the -w option to translate a Cygwin path into a Windows path.
# cygpath -w /cygdrive/c
c:\
  • Use the -u option to translate a Windows path into a Cygwin (UNIX) path.
# cygpath -u “c:\”
/cygdrive/c