When you first login, the X server will look for the file ~/.xsession.[ARCH], where [ARCH] is one of: AIX, ULTRIX, OSF1, or IRIX, depending on the type of machine you are using. For example, if you login to an IBM workstation, the X server will first look for the file ~/.xsession.AIX and run it if it exists.
If the X server does not find the file ~/.xsession.[ARCH], it will look for the file ~/.xsession and run it. If it cannot find this file, then it will run a built-in default Xsession script.
So, if you want a different Xsession script run for each type of machine you use, then create seperate Xsession files with the appropirate [ARCH] extension. However, if you have an Xsession script which works on all machines, and you want to use the same script for all machines, then name this script ~/.xsession If you want to use the default setups, then remove all .xsession* files in your home directory (or rename them).
Many XTerminal problems, particularly inability to login, result from problems with the xsession file. The first thing to check when experiencing such problems is the file ~/.xsession-errors . This file may contain messages explaining the problem. Another thing to try is to rename or remove all your .xsession* files; this will force the Xserver to use its default startup script.