Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Which distribution?

Status
Not open for further replies.

BIS

Technical User
Jun 1, 2001
1,893
NL
Hello,

Silly question probably, but is there a command that will show me which distribution of Linux I have installed (RedHat, Mandrake, Slackware) ?
 
Difficult one to answer, you could have a look at the /usr/src directory, if you see a directory called "redhat" then you know what it is.

On my Mandrake box I did a grep for "mandrake" in the /etc/ directory, found some files referring to it.

A uname -a revealed nothing.

Any other ideas? IBM Certified Confused - MQSeries
IBM Certified Flabbergasted - AIX 5 pSeries System Administration
 
Ha, got it, this is easy if telnet is enabled on your box.

Do a "telnet localhost", the login screen should reveal your distribution and version. IBM Certified Confused - MQSeries
IBM Certified Flabbergasted - AIX 5 pSeries System Administration
 
Thanks,

Looking in the /usr/src did the trick, this was indeed a redhat dist. Any quick idea on how to find which release? I have a feeling this is 7.3 but just to be sure....
 
and another note: If i telnet localhost I get access denied. Can i temporarily enable telnet just to check this command, then disable it again?

As the man said:
I think, therefore I am confused.
 
When you telnet to a machine, the greeting you see comes from the /etc/issue file.

[root@cp root]# cat /etc/issue
Red Hat Linux release 7.3 (Valhalla)
Kernel \r on an \m


The /proc/version file might be of interest also...

[root@cp root]# cat /proc/version
Linux version 2.4.18-3 (bhcompile@daffy.perf.redhat.com) (gcc version 2.96 20000731 (Red Hat Linux 7.3 2.96-110)) #1 Thu Apr 18 07:37:53 EDT 2002



If you still want to enable telnet anyway, modify the /etc/xinetd.d/telnet file....

[root@cp root]# cat /etc/xinetd.d/telnet
# default: on
# description: The telnet server serves telnet sessions; it uses # unencrypted username/password pairs for authentication.
service telnet
{
disable = yes
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/sbin/in.telnetd
log_on_failure += USERID
}




ChrisP
 
excellent info - many many thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top