Wavey Davey’s Stuff

Cygwin

What is Cygwin

In their own words:

Cygwin is a Linux-like environment for Windows. It consists of two parts:

  • A DLL (cygwin1.dll) which acts as a Linux API emulation layer providing substantial Linux API functionality.
  • A collection of tools which provide Linux look and feel.

Find out more and install it from from http://www.cygwin.com/

I love Cygwin because my professional background means I have a lot of experience with the UNIX/Linux command line and shell scripting. There are so many useful things you can do in a shell script that are difficult (at least for me) to achieve in DOS batch scripts.  With Cygwin installed you can apply the power of a bash or pdksh shell to your Windows system. Lovely.

Cygwin Tips and Tricks

rebaseall

If something isn’t working for you in cygwin, then rebaseall might just help.  It worked for me when:

  • I had Cygwin sshd installed as a Windows service, but it wouldn’t startup automatically at boot up – even though I had the service set to auto start.
  • I installed Apache under cygwin and it failed to start citing problems remapping DLLs

In both cases, rebaseall fixed the problem. In order to run this utility you need to have installed two things (run the Cygwin installer if you don’t have them)

  • Shells->ash
  • Utils->rebase

Then you need to:

  • Stop all Cygwin processes and services
  • From Windows Start->Run dialog, execute the command “C:\cygwin\bin\ash”   – without the quotes, and modifying the path depending on where you installed Cygwin
  • At the ash prompt, execute the command “/usr/bin/rebaseall”
  • After a delay of a minute or two it should return.

With any luck you’re problems are solved.

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: