Tuesday, July 28, 2009

How to determine which unix distribution installed?

I'm puttying into EC2 instance which is running either fedora or debian unix distro. How to tell which one (and which ver)?

How to determine which unix distribution installed?
there should be a file in the /etc directory called "release", or some variation of it. if you cat that file, it'll tell you the distribution %26amp; the release info. for instance, in red hat, it's called /etc/redhat-release. in suse, it's /etc/SuSE-release. in solaris, it's just /etc/release. note: for suse, i don't remember if it's "suse" or "SuSE". you'll have to confirm. or, just type 'cat /etc/*release'.
Reply:uname
Reply:Typing in uname will give you the Linux kernel version, but it won't tell you whether it is fedora or debian.





On my SuSE box, I used the env command to see what was there. Try typing "echo $MACHTYPE" for the distro. On my machine it gave me "i686-suse-linux".





"env | grep MACHTYPE" may work too. Or you could also try "env | grep -i fedora" or "env | grep -i debian".





Your mileage may vary.

trading cards

No comments:

Post a Comment