Re: What is more detailled than $^O ?
- From: Yohan N Leder <ynl@xxxxxxxxxxx>
- Date: Tue, 7 Nov 2006 09:15:33 +0100
In article <g69k6281bu6.fsf@xxxxxxxxxxxx>, tzz@xxxxxxxxxxxx says...
In non-Perl terms, this information is often in /etc. The file
/etc/issue in particular is often useful.
It's almost always better to test for tools and features than
distributions anyhow. If you need package X, don't assume it's
installed, check. For a web server, Apache for example, there's tools
to tell you the version and compiled-in or loaded features. Perl
can't solve this problem in general terms AFAIK.
Yes, but I don't want to test what feature is available or not. The fact
is that some of the Perl CGI scripts we spread in our intranet and
extranet have to proceed with reports from proprietaries logs in
different trees depending of the specific linux distribution (actually :
Ubuntu, Debian, Red Hat Ent, Fedora and Suse, but more in future).
Also, some of these logs may have different signification depending of
the current distribution (so, we can't simply check for file presence
and deduct it's this or this distribution).
And, to facilitate the stuff, some of the servers may change from time
to time (I mean, change of linux ditribution from multi-boot or raw
change) and every admin has choice to keep of strip-out some parts of
the logs tree I told about ; this without notice, so I can't maintain a
simple database saying server #1 is under Debian, server #2 is under
Fedora, etc.
Well, because of this specific context, I have to determinate what is
the current linux ditribution (at least the 'main name' as said above,
even if I can't know the version) up front of all. Never mind what are
the available features or installed packages, it's not the information
I'm looking for and our packages will run whatever be the config.
.
- Follow-Ups:
- Re: What is more detailled than $^O ?
- From: Ted Zlatanov
- Re: What is more detailled than $^O ?
- References:
- What is more detailled than $^O ?
- From: Yohan N Leder
- Re: What is more detailled than $^O ?
- From: Abigail
- Re: What is more detailled than $^O ?
- From: Yohan N Leder
- Re: What is more detailled than $^O ?
- From: Ted Zlatanov
- What is more detailled than $^O ?
- Prev by Date: Posting Guidelines for comp.lang.perl.misc ($Revision: 1.7 $)
- Next by Date: Re: What is more detailled than $^O ?
- Previous by thread: Re: What is more detailled than $^O ?
- Next by thread: Re: What is more detailled than $^O ?
- Index(es):
Relevant Pages
|