PeopleSoft

PuTTY’s Network Connection Times Out Too Quickly

May 18, 2008 · Leave a Comment

Update the Windows Registry to create or change the TcpMaxDataRetransmissions

The problem of PuTTY or other SSH connections timing out too quickly when network connectivity is briefly lost is Windows problem and not an internal PuTTY problem. You can tweak the Windows Registry settings to try and change or address this issue.

For Windows NT, 2000, XP – the registry key to create or change is:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parmeters\TcpMaxDataRetransmissions

It must be of type DWORD. See Microsoft Knowledge Base articles 120642 and 314053 for more information. Set the key’s value to something like 10. This will cause Windows to try harder to keep connections alive instead of abandoning them.

Categories: PeopleTools · Windows Operating Systems

Creating / Removing a Windows Service (PuTTY pageant)

May 18, 2008 · 2 Comments

How to Create / Remove a Windows Service

You should NOT do this for any Windows Service that you did not create yourself. In previous posts I mentioned that you could create a Windows Service to start for example the PAGENT.exe (PuTTY SSH Key Forwarding Agent) but I didn’t give any examples of how to create a windows service. I

There used to be a great web site that hosted homegrown Windows Utilities that individuals had written to perform some integral System Administration functions. This software was available for free and the site name changed over time to reflect the evolution of the software and the entities who hosted the site, etc. At some point software was added that wasn’t free but the spirit of the original web site remained intact to an extent. Eventually Microsoft came along and somehow took ownership of this site and the software that was available on it. Some of the original tools are still available for free but the original intent and spirit that the original site was created in disappeared.

Some of the tools there were so simple and that was a tribute to the elegance of the software code, the simplicity of use (most were command line driven and as anyone who knows me will attest I am still stuck to an extent in a command line world, basically because I personally feel that as you use GUI tools more and more and over a longer period of time you will forget the underlying architecture, the commands the GUI tools invoke and in a crunch you wouldn’t be able to perform the same functions without the GUI interface. That’s just a personal opnion that probably holds no merit but oh well it is my onion).

I can’t remember the original site name but over time it became sysinternals.com and now it is part of Microsoft’s TechNet:

http://technet.microsoft.com/en-us/sysinternals/default.aspx

I’ll give Microsoft this – its a pretty site. You’ll still see references to the old Sysinternals, the utilities are grouped by function. You’ll find information here on the various Windows Kernels and the history of the Sysinternals web site actually appears on the home page. Sysinternals was created in 1996 by Mark Russinovich and Bryce Cogswell to host their advanced system utilities and technial information. Microsoft acquired Sysinternals in July 2006. I believe I discovered their site a few weeks after it went up and I’ve continued to visit their site to retreive software updates, check for new utilities and tools and to read anything new that was posted. Some of their tools helped me out in some real jams. I discovered some very simple looking command line toosl that let me remotely execute commands on Windows Servers that became unaccessible at least to Telnet, Remote Desktop and/or via System Administration remote access like ‘Connect to Server’ in the Computer Management console.

The Process Explorer is one of the tools available here and it is an awesome way to walk through or explore all running processes on a windows machine. Plus, you can terminate (kill) processes via this tool which may be necessary in those rare situations where you can not end a task any other way.

It turns out the programs needed to create and set a Windows Application to run as a service are available as part of Microsoft’s Resource Kits. The two can be downloaded together in a zip file from:

http://www.tacktech.com/display.cfm?ttid=197

Find the line in the top third of the page that reads – You can download both files here srvany.zip and download the zip file. The zip file includes three files. The two you need srvany.exe and instsrv.exe to install the services and also srvany.wri which documents everything you can do with the program.

Note: Make sure the Services Manager is closed while you are running these DOS commands.

You will need to put these files into a directory named reskit. At a MS-DOS command prompt (Start->Run->cmd.exe), type the following command:

<path>\reskit\INSTSRV.EXE “Service Name” <path>\reskit\SRVANY.EXE

This creates the service in the Services Manager and the registry keys to setup what program to execute.

instsrv.exe command

Next open regedit.exe by: Start->Run->regedit.exe

I have to put the standard warning by Microsoft here – Using Registry Editor incorrectly can cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk! That statement means everything it says so if you have used Registry Editor in the past you should really have someone help you with this until you feel comfortable and have enough confidence to understand the criticality of what you doing and the associated risks.

Regedit - Run Box

Next navigate to this registry key: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\service name

Registry Key - service name

From the Edit menu, click the Add Key and name it Parameters. Next from the Edit menu, click Add Value and type in this information:

Value Name: Application
Data Type: REG_SZ
String: <path>\<application.ext>
Service Test - Service

Now you can start your service from the Services Manager:

Services Manager - Service Test

With this same program you can remove the service also. Just run this command from the command prompt:

<path>\reskit\INSTSRV.EXE “Service Name” REMOVE

Remove Service

You should walk through the above example one time to familiarize yourself with the process and then do it for real. Instead of “Service Test” use a the name of the application you are creating a service entry for. To use PAGENT.EXE as an example I named my service – pagent – that way when I scroll through the service name listing in the Services Manager application I can find it very easily and it also is indicative of the real application’s name.

Note: If you use or have spaces and backslashes in your Service Name(s) you will not be able to remove the Service unless you specify the exact name as it appears in the Registry and which you can visually see via the Services Manager. The first image below shows an example of Service Names that contain both spaces and backslashes:

Service Manager Listing - Dev Server

The next image shows the individual Service and you’ll notice the name that Microsoft uses for the Service Name has underscores in it. Microsoft replaces the spaces and backslashes with underscore (_) characters and that is how you need to specify the service name when removing it.

Service box

Image of DOS commands used to remove services no longer needed:

Service Removal

I’ll paste a series of screen shots illustrating how to set up the PuTTY PAGEANT (Key Forwarding Agent) as a Windows Service:

Setting up the PuTTY Agent to run as a service is no big deal but in order to have it load your private key(s) when it starts requires using the parameter option of the Registry Key that is generated by the process. I’ve pasted an image below that shows the value of my parameter setting:

Pageant Parameter Settings

The value of the Parameters Registry Key in my instance is: D:\tools\pageant.exe D:\tools\psprod1dsa.ppk

I use D:\tools as the directory to hold all of my SSH programs and keys. The first part of the line is simply the location and name of the executable followed by a space and then the location (path) of my DSA private key file. You can load more than one private key by entering a space after each one and listing all of the private keys you need to load at start time.

Personally I use an Apple Mac Book Pro but I occasionally have a need to use a Windows application that doesn’t have a Mac OS X version or substitute so I boot up Windows XP Pro in a Virtual Machine and I also use Remote Desktop quite a bit to connect to our PeopleSoft and Hyperion Windows Servers.

So to wrap up this post I started off telling you about Sysinternals and ended up with the Microsoft Resource Kit so I actually touched on two Microsoft sites that are useful.

One last note in the above example I used sample path of: <path>\reskit\….. If you actually created a directory structure like that you would need to make sure it was contained within your Windows Environment variable %PATH%. You can add it to %PATH% by using the Control Panel->System app or you can just put the executable(s) into a directory that already is in your %PATH% like C:\Windows\system32. I use that location for some of my executable(s) but I also created a Tools directory (C:\Tools) and I put the majority of my non-standard Windows or rather non-delivered Windows programs there and I’ve added C:\Tools to my %PATH%).

One last last note. Back to Sysinternals. There is complete zip file available for download that is available at:

http://technet.microsoft.com/en-us/sysinternals/bb545027.aspx

Categories: PeopleTools · Windows Operating Systems · Windows Server · Windows XP

Beta Beyond Compare

May 18, 2008 · 2 Comments

Beta Version of Beyond Compare

Scooter Software home of Beyond Compare has a Beta version of their popular Beyond Compare software application available, there a three flavors available for download – Normal Debug Build, Full Debug Build and Optimized Build. Build data for WIndows is May 6, 2008 (the version that is available to the public for testing). If you decide to download the beta version you should go with the Normal Debug Build so you can assist in the testing effort. If the software crashes or has flakly behaviour you can send this information to them. They recommend that you use one of the debug builds. However, if you aren’t interested or willing to help them out you can download the Optimized Build.

The beta version runs on Linux now which is awesome and I’m looking forward to testing it out on my Apple to see if I can get it to work on OS X. The other good news is the support for SSH. I’ve included a few screen shots below to give you an idea of the what the new User Interface looks like as well as the Authentication tab.

I’ve installed it and I will be testing out the SSH capability later this afternoon. If the SSH feature set works then there will no longer be a need to use the Bitvise Tunnelier to establish a Tunnel between your Windows machine and a remote Unix server. Now that Beyond Compare includes the capability to communicate with Unix servers within the application there isn’t any need to use another application to create the tunnel and map the remote directories to the established local end point.

Beyond Compare UI

The Authentication Tab Screenshot:

Beyond Compare UI - Authentication Tab

I’ll post a review later today on my experiences using the builtin SSH capability.

I’m using Beyond Compare on Windows, either booting up Parallels Desktop or having to connect to a Windows Server in order to use this tool. No news on a Mac version, although Scooter Software is shipping versions for Red Hat Enterprise Linux 4, 5; Fedora Core 4 – 9, Novell Suse Linux Enterprise Desktop 10, openSUSE 10.3, 11 and Ubuntu 6.06 – 8.04. Their site has a note that it isn’t compatible with Red Hat Enteprise Linux 3 and it isn’t test on any 64-bit Linux kernel.

I’ve sent an email to the Development Team asking about the possibility of a beta for OS X and I’ll post a follow-up comment when I hear back. I hate having to boot Windows on my Mac Book Pro just to run BC3, I’ve tried Crossover and I just don’t have the patience to run a Windows app in that mode. Parallels Version 4 has boosted performance some for Vista but I still think XP was faster in that type of environment than using VIsta.

I’ve been using KDIFF which runs on OS X and isn’t too bad and I’m going to check out Switchback this evening.

http://sourceforge.net/projects/kdiff3 is the link to download the kdiff3 software which runs on
Windows, OS X, Linux, etc.

Categories: Oracle · PeopleTools