find redhat

how to find out the Red hat version using uname -a command.

If you want to know what version of Redhat you are running:

cat /etc/redhat-release

$cat /etc/redhat-release
Red Hat Enterprise Linux AS release 4 (Nahant Update 7)

the redhat-release has rel 4. but it does not display 4 anywhere.. in the output of uname -r
$ red-devl:/home/sudhirsb> uname -r
2.6.9-78.0.8.ELsmp

what actually does uname -r display.

man uname

what is the difference between the redhat release 4 and kernel version ? is kernel version a kind of sub-release number ?

No, the kernel version is the release number of the kernel / the OS. The RedHat release number is a counter defined by RedHat to differentiate between their releases of software bundled together with the OS.

i have a user with umask settings 0027. but when i touch the file it creates it with a perm 640.

First, how does that relate to the rest of the thread?
Second, umask is working correctly. Effective permissions are 0666 (0777 for directories) minus the umask, so 0666 - 0027 = 0640. Why, what did you expect?