Up Prev Next
From: "David LANDGREN" <dlandgre at bpinet dot com>
Subject: Re: Naming one's hostname for sp_who
Date: Oct 9 2001 4:54PM
|kiruna (8:56AM):1 > perl -MSybase::DBlib -e 'my $dbh = new Sybase::DBlib
|(yeah - I've still got the null sa password :-) and I get:
Hmm. And I thought I was the only one :)
|So this sets it correctly for me.
|Maybe your gethostname() (or whatever) call doesn't work right?
| > Rats. I cleared the source of the machine a few weeks ago. I'll
| > again and tell you how it went.
Our mails crossed. I think gethostname() is working ok. I running this code
from the same server that Sybase is running on, so it's normal that it
returns the name of the server.
However, I have lots of different scripts that tend to eat CPU when we're
not watching, so I need to be able to differentiate between them.
This was easy to do with the older scripts that are dreadful shell hacks
that talk to isql, because I was able to override the hostname column with
the -H flag of isql, which makes it possible to identify them. I would like
to emulate doing that via the more recent scripts that use Sybase::DBlib to