Re: Check the linux type?



On 2007-03-30 02:22, Moe Trin wrote:
On 29 Mar 2007, in the Usenet newsgroup alt.os.linux, in article
<1175167247.049377.216050@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>, SamG wrote:

How do i check what linux type am i using from a script.

No guaranteed standard way. Many distributions include a release or
version file in /etc/ - so you can look for /etc/*release and then
/etc/*version. If the distribution is following the Linux System
Base standard, there should be a command 'lsb_release'

lsb_release -- print distribution specific information

Like ubuntu

Debian derivative - has a useless /etc/debian-version file but the real
information is available from the 'lsb_release' command

or suse

cat /etc/SuSE-release

or fedora.

/etc/fedora-release (also has or had /etc/redhat-release)

Old guy

Solaris has a file called just /etc/release ,
why can't this be a standard?, it just sux one must know
which distribution it is before one can figure out the name of the file
that will tell me which distribution it is.

/birre
.



Relevant Pages

  • Re: how to find all transactions in a queue
    ... I am familiar with an architecture of replication for many years already on ... What i think is that one has to be able to browse queue generaly and see the ... I will try the command you gave me. ... the log that is then delivered to the subscriber by the distribution agent. ...
    (microsoft.public.sqlserver.replication)
  • Re: Check the linux type?
    ... If the distribution is following the Linux System ... Base standard, there should be a command 'lsb_release' ...
    (alt.os.linux)
  • Re: Book for Linux
    ... Beginning the Linux Command Line ... IMHO books tend to be quite distribution bound and I wouldn't be ... You do have quite a lot of documentation installed on your Linux as it ...
    (alt.os.linux)
  • Re: Stop the Linux kernel madness
    ... of the kernel OSS drivers are mostly our work. ... Equally well it's going to be usefull to have a standardized command (say ... Nothing prevents the distribution maintainers from optimizing that command ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: command to print Linux/UNIX version?
    ... This works on CentOS, Fedora and SuSE. ... said to type "uname -a". ... In your command output dump, ... does not show you the distribution name. ...
    (comp.os.linux.misc)