# compaq (hp) Insight agents installation

## Ika7734

Has anyone tried this on a Compaq (HP) DL360?

I've managed to get the HP specific SNMP working, however, when I try to get the HPASM working I get a ton of /etc/rc.d/init.d/functions file not found.

the functions file appears to be redhat specific (that's the installs HP wants to use, binary RPMS).  Does anyone have a gentoo version of the functions file?  I'm no real script wizard and any help would be appreciated.

----------

## Ika7734

Well after a long time of not focusing on this, I'm back at it.

I successfully got insight to load and run, but I can't get it to start on boot.

I've done the rc-update but the boot process seems to ignore it.

If I'm logged in as root, I can simply run /etc/init.d/hpasm start and it fires up, but not at boot, I don't even see an attempt.

I don't know much about how rc-update works, so do I need to tweak the scripts in /etc/init.d to make rc-update happy?

----------

## veezi

Are you trying to manually install hpasm (downloaded from HP)? Or, are you talking about the version currently in portage (app-admin/hpasm)?

----------

## Ika7734

There's one in portage?! 

Aaack, silly me I thought it was proprietary crap.  I was trying to use the ones from HP's site and munging the stuff from the RedHat RPMS...

I'll give it a go with portage.  Thanks!

----------

## veezi

Keep in mind the one in portage is pretty old now (version 6.3), while hpasm is at 7.1 right now.

If I were you I'd try to make my own ebuild of 7.1 by copying what's in 6.3. If you get that to work you might want to file a bug report at bugs.gentoo.org, and get the developer to pumb the ebuild to the latest version.

Also, case you didn't know, HP has a linux version of hpsim (HP Systems Insight Manager). Very nice software for managing proliants. Check it out at http://www.hp.com/servers/manage.

Good luck!

----------

## Ika7734

I'm going to give the 6.3 in portage a try first.

I managed to get the hp supplied ones base installs to work from a manual start, except the storage agents, they validate the disto.  I just couldn't get them to start on boot.  Right now I know enough about Gentoo to be really dangerous, and haven't looked into making ebuilds just yet.

----------

## tuxus

I have writen new hpasm-7.1.0.145.1.ebuild and cmastor-7.1.0.12.1.ebuild

http://dev.gentoo.org/~tuxus/insight-tools/app-admin/

----------

## TuxFriend

 *tuxus wrote:*   

> I have writen new hpasm-7.1.0.145.1.ebuild and cmastor-7.1.0.12.1.ebuild
> 
> http://dev.gentoo.org/~tuxus/insight-tools/app-admin/

 

Yahoo!!!, thanks a lot, any plans to add this to the portage tree like the old version?

----------

## tweibley

Can someone please give me instructions on how to properly emerge these ebuilds?  Just download them with wget to where? Etc.

Thanks in advance,

--Taylor < ><

----------

## TuxFriend

 *tweibley wrote:*   

> Can someone please give me instructions on how to properly emerge these ebuilds?  Just download them with wget to where? Etc.
> 
> Thanks in advance,
> 
> --Taylor < ><

 

Please read this, if you are still unable to do it, post again.

http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=3&chap=5#doc_chap2

----------

## tweibley

/etc/init.d/hpasm start  --->

```

Enabling Advanced Server Management at Sat Nov 13 13:29:57 EST 2004 on Linux kernel:  2.6.7-gentoo-r9

The hp ProLiant Event Logging Driver is not available

for this Linux kernel:  2.6.7-gentoo-r9

Looking for sources to build 2.6.7-gentoo-r9

Sources for Linux kernel 2.6.7-gentoo-r9 have been located

Recompiling cpqevt for current Linux Kernel . . .

Creating directory "/opt/compaq/cpqhealth/cpqevt/2.6.7-gentoo-r9"

Replacing /opt/compaq/cpqhealth/cpqevt/2.6.7-gentoo-r9/cpqevt.o at Sat Nov 13 13:29:58 EST 2004 . . .

Custom cpqevt Driver installed  . . .

Reloading the hp ProLiant Advanced Server Management Event module . . .

insmod: error inserting '/opt/compaq/cpqhealth/cpqevt/2.6.7-gentoo-r9/cpqevt.o': -1 Invalid module format

WARNING!  The hpasm RPM is not compatible with this kernel.

          See /opt/compaq/cpqhealth/cpqhealth_boot.log for details.

          Hint:  Look for Compiler or Linker issues.

WARNING! The cpqhealth RPM has failed to install!

```

Any help?

PS This is the contents of the log file it says to look at.

PPS Can't figure out how to get to the webagent to work... this (google cached) page seems to have some info... http://64.233.179.104/search?q=cache:r0foNE6wFbgJ:h200002.www2.hp.com/bc/docs/support/SupportManual/c00067308/c00067308.pdf+hpwebsetup&hl=en

----------

## tuxus

hpasm-7.1.0.145.1.ebuild is only for 2.4 kernel

hpasm-7.2 is for 2.6 but not ready

----------

## veezi

 *tuxus wrote:*   

> hpasm-7.1.0.145.1.ebuild is only for 2.4 kernel
> 
> hpasm-7.2 is for 2.6 but not ready

 

Just wanted to say thank you tuxus for the great work.   :Very Happy: 

When will it hit portage?

----------

## tweibley

Yeah, thank you! I eventually gave up... glad I now know I just need to be patient for the right version to come out   :Wink: 

----------

## FLYLM

 *tuxus wrote:*   

> I have writen new hpasm-7.1.0.145.1.ebuild and cmastor-7.1.0.12.1.ebuild
> 
> http://dev.gentoo.org/~tuxus/insight-tools/app-admin/

 

I did not test it yet, but I say to you thank...

----------

## dledeaux

Which flavors of Proliants are these tools compatible with?  I perused HP's website but couldn't really come up with anything conclusive.  I'm working with a Compaq Proliant 2500.  If these tools work with the 2500, do they also have any functions for controlling the LCD screen?

----------

## lojack

 *tuxus wrote:*   

> hpasm-7.1.0.145.1.ebuild is only for 2.4 kernel
> 
> hpasm-7.2 is for 2.6 but not ready

 

Can I beg you to finish the 7.2 ebuild??? I'm dying to get SLES9 off of this Proliant DL320.

I'd be happy to test it!

TIA

Chris/cms

----------

## pitcrawler

From looking at the hpasm 7.1 and 7.2 packages, they look quite similar, so the 7.1 ebuild hopefully shouldn't take much modification.  I got the redhat x64_emt64 7.1 version of the package partially working on a DL380 server with gentoo before , but I may soon have a go at getting the new version to work soon.  I just don't want to mess anything up with the server as it's in almost constant use.

----------

## strolls

 *pitcrawler wrote:*   

> From looking at the hpasm 7.1 and 7.2 packages, they look quite similar, so the 7.1 ebuild hopefully shouldn't take much modification.

 

Holy frick! I'm glad someone thinks this'll be easy! I just took a look at the hpasm-7.1.0.145.1.ebuild & it looks murderous to me!

 *pitcrawler wrote:*   

> I got the redhat x64_emt64 7.1 version of the package partially working on a DL380 server with gentoo before , but I may soon have a go at getting the new version to work soon.  I just don't want to mess anything up with the server as it's in almost constant use.

 

Oooh! How soon? I've just installed Gentoo on my new Proliant 6500. If I'm right in thinking that these tools will enable me to set alerts when hard-drives are removed & suchlike, then this'd be a killer feature for me. I'm sure I'm not the  only person who'd be glad to help test.

Stroller.

----------

## pitcrawler

I just installed the hpasm-7.2.1-313.rhel4.x86_64.rpm package on my DL380 Dual Xeon EMT64 server using the standard rpm tools.  I can now run 'hpasmcli'  to get a command line interface to the server management tools.  Everything seems to work fine.  I can now experiment a bit and try and write an e-build for the package.

----------

## strolls

 *pitcrawler wrote:*   

> I just installed the hpasm-7.2.1-313.rhel4.x86_64.rpm package on my DL380 Dual Xeon EMT64 server using the standard rpm tools.  I can now run 'hpasmcli'  to get a command line interface to the server management tools.  Everything seems to work fine.  I can now experiment a bit and try and write an e-build for the package.

 

Well, you're getting further than I am! Did you `emerge rpm` & then just rpm the package? That was how I was expecting to do this in the first place, before I found this discussion.

I can't even get the previous ebuild to unpack, so I can take a look at how it works. I'm sure I must be doing something stupid.   :Embarassed: 

```

# ebuild unpack /usr/local/portage/app-admin/hpasm/hpasm-7.1.0.145.1.ebuild 

!!! Name error in : missing a version or name part.

!!! Error: PF is null ''; exiting.

# ls /usr/local/portage/app-admin/hpasm/

ChangeLog  files                      hpasm-6.40.0.16.ebuild    metadata.xml

Manifest   hpasm-6.30.0.12-r1.ebuild  hpasm-7.1.0.145.1.ebuild

# ls /usr/local/portage/app-admin/hpasm/files/

digest-hpasm-6.30.0.12-r1  functions  initlog

digest-hpasm-6.40.0.16     hpasm      initlog.conf

digest-hpasm-7.1.0.145.1   hppasswd   snmpd.conf

#

```

----------

## pitcrawler

I'm about to make an e-build for hpasm-7.2.1-313.rhel4.x86_64.rpm.  This is for servers with 64-bit processors and the 2.6 kernel.  Info on supported servers can be found at the bottom of this page.

The e-build will be based on the hpasm-6.30 ebuild which is currently in portage.

I'm only able to test it on a DL380 G4 server but it will most likely work with the other servers listed on that page.  I have no idea if this rpm also works with the 2.4 kernel. but I'm guessing it doesn't.  For that you would need the rhel3 version.

I did install it the way you mentioned, I did:

```
emerge rpm 

rpm -ivh hpasm-7.2.1-313.rhel4.x86_64.rpm
```

The hpasm ebuild that is currently in portage simply converts the rpm to a tar.gz using the rpm2targz tool.  Then it unpacks it,  deletes all the symlinks in there, copies the rest of the files to the correct places then recreates the symlinks.  Apparently you can't just unpack a symlink from an rpm because it just doesn't work.

----------

## strolls

 *pitcrawler wrote:*   

> I did install it the way you mentioned, I did:
> 
> ```
> emerge rpm 
> 
> ...

 

Ah! Many thanks. I think I'll be doing that myself, then. (Your ebuild won't be any good to me, as my Proliant is just an old PII).

 *pitcrawler wrote:*   

> The hpasm ebuild that is currently in portage simply converts the rpm to a tar.gz using the rpm2targz tool.  Then it unpacks it,  deletes all the symlinks in there, copies the rest of the files to the correct places then recreates the symlinks.  Apparently you can't just unpack a symlink from an rpm because it just doesn't work.

 

Hmmmn... I don't understand the need for the ebuild, in that case. Excuse me if I'm missing something, but isn't distributing binary files what RPM was designed for?

Stroller.

----------

## Magnum_

Will there be a similar e-build available for x86 please?

2.6 kernels are being used more & more frequently, and I just can't get it working... I tried rpm-installing the hpasm-7.3.0-58.ul10.i386.rpm, but it gives me dependency errors (needs /bin/sh & /bin/bash)...

I also tried the redhat package instead of unified linux...

----------

## strolls

 *Magnum_ wrote:*   

> ... I tried rpm-installing the hpasm-7.3.0-58.ul10.i386.rpm, but it gives me dependency errors (needs /bin/sh & /bin/bash)...

 

You already have /bin/bash installed; since it behaves mostly like `sh` when invoked that way you'll find that it's symlinked to /bin/sh on most systems. You just need to "force" the rpm installation - I think there's a -f flag.

----------

## pitcrawler

 *strolls wrote:*   

>  *Magnum_ wrote:*   ... I tried rpm-installing the hpasm-7.3.0-58.ul10.i386.rpm, but it gives me dependency errors (needs /bin/sh & /bin/bash)... 
> 
> You already have /bin/bash installed; since it behaves mostly like `sh` when invoked that way you'll find that it's symlinked to /bin/sh on most systems. You just need to "force" the rpm installation - I think there's a -f flag.

 

You don't need the -f flag, just pass the --nodeps flag and it will work.

----------

## tuxus

I have writen new hpasm-7.2.1.313.ebuild

http://dev.gentoo.org/~tuxus/insight-tools/app-admin/

----------

## superwutze

i tried to install that one but i get the error:

```
# emerge -av hpasm

These are the packages that I would merge, in order:

Calculating dependencies -

emerge: there are no ebuilds to satisfy "net-snmp-hp".
```

where can i get that one?

----------

## tuxus

I have writen new hpasm-7.3.0.58.ebuild (32 bit)

http://dev.gentoo.org/~tuxus/insight-tools/app-admin

----------

## tuxus

new hpasm home and new ebuilds for 2.6 (64bit)

http://www.tuxus.com/app-admin/hpasm/

----------

## toskala

first: thanks for the ebuild! but i seem to have some problems  :Smile: 

emergin app-admin/hpasm-7.3.0.58 works fine, but when i start the initscript following output is presented:

```
tweety ~ # /etc/init.d/hpasm start

 * Starting HPASM ...

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

Starting Foundation Agents (cmafdtn): cmathreshd cmahostd cmapeerd

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started Threshold agent (cmathreshd).

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started Host agent (cmahostd).

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started SNMP Peer (cmapeerd).

Starting Server Agents (cmasvr): cmastdeqd cmahealthd cmaperfd

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Starting Standard Equipment agent (cmastdeqd):/opt/compaq/foundation/etc/cmad: line 33: success: command not found

/opt/compaq/foundation/etc/cmad: line 33: failure: command not found

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Starting Health agent (cmahealthd):/opt/compaq/foundation/etc/cmad: line 33: success: command not found

/opt/compaq/foundation/etc/cmad: line 33: failure: command not found

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started Performance agent (cmaperfd).

Starting Storage Agents (cmastor): cmaeventd cmaidad cmafcad cmaided cmascsid

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started Storage Event Logger (cmaeventd).

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Already started IDA agent (cmaidad).

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Starting FCA agent (cmafcad):/opt/compaq/foundation/etc/cmad: line 33: success: command not found

/opt/compaq/foundation/etc/cmad: line 33: failure: command not found

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Starting IDE agent (cmaided):/opt/compaq/foundation/etc/cmad: line 33: success: command not found

/opt/compaq/foundation/etc/cmad: line 33: failure: command not found

/opt/compaq/foundation/etc/cmad: line 24: /etc/rc.d/init.d/functions: No such file or directory

   Starting SCSI agent (cmascsid):/opt/compaq/foundation/etc/cmad: line 33: success: command not found

/opt/compaq/foundation/etc/cmad: line 33: failure: command not found

hpasm:  Server Management is enabled                                                               [ ok ]
```

any hints on this?

cheerios,

toskala

----------

## skirk

I have exactly the same problem :| I've been googling around and haven't found anything too helpful so far. It looks like it *might* be some kind of function that is included in /etc/init.d/functions on redhat, but no such equivalent exists on gentoo.

Has anybody got any idea? I'm totally stuck at the moment - still trawling google and the forums...

----------

## tuxus

remove hpasm (delete hpasm files in /opt /var ...) and emerge hpasm

----------

## kybber

Thank you for this! hpasm seems to be working fine on my HP25p's  :Smile: 

But what's the deal with the dep on =net-snmp-hp-5.1.220? That package is not in portage. I have net-snmp

installed already, so I just removed the net-snmp-hp dep from the ebuild and installed hpasm with no problems.

Am I missing some functionality because of this? Or even worse: Have I screwed up the system rather royally?

----------

## tuxus

hp use a cmaX library , it is needed for Insightmanager (traps)

 i have written a ebuild 

http://www.tuxus.com/net-analyzer/

----------

## 029ah

Anoyne tried to install hpasm on 2.6.15 kernel?

After patching source of cmhp kernel module (removing inter_module_get call), I've got following error:

```
overflow in relocation type 10 val ffffffff8800df0e

`cmhp' likely not compiled with -mcmodel=kernel

```

----------

## tuxus

cmhp is "Memory Hot Plug interface" 

 I did not test it and never required

----------

## theruck

what is the dependency package "net-snmp-hp-5.1.220" ??

----------

## theruck

when i try to emerge it i get this error:

```

webserver net-snmp-hp # emerge /usr/local/portage/app-admin/hpasm/hpasm-7.3.0.58.ebuild

emerging by path implies --oneshot... adding --oneshot to options.

*** emerging by path is broken and may not always work!!!

Calculating dependencies ...done!

>>> emerge (1 of 1) app-admin/hpasm-7.3.0.58 to /

>>> md5 files   ;-) hpasm-7.3.0.58.ebuild

>>> md5 files   ;-) files/digest-hpasm-7.3.0.58

>>> md5 src_uri ;-) hpasm-7.3.0-58.rhel4.i386.rpm

 * You are running 2.6.15-gentoo-r1

>>> Unpacking source...

found gzip magic bytes

  trying to decompress with gzip...  OK

>>> Source unpacked.

>>> Test phase [not enabled]: app-admin/hpasm-7.3.0.58

>>> Install hpasm-7.3.0.58 into /var/tmp/portage/hpasm-7.3.0.58/image/ category app-admin

cp: cannot stat `/usr/local/portage/app-admin/hpasm/files/initlog.conf': No such file or directory

install: cannot stat `/usr/local/portage/app-admin/hpasm/files/functions': No such file or directory

!!! ERROR: app-admin/hpasm-7.3.0.58 failed.

!!! Function src_install, Line 63, Exitcode 1

!!! (no error message)

!!! If you need support, post the topmost build error, NOT this status message.

```

where can i get those 2 files?

----------

## Macindy

This ebuilds are great - all is working, but...

the cciss daemon starts and afterwards stops direct.

There is something like

```
modinfo: could not open /lib/modules/2.6.16-gentoo-r7/modules.dep

sh: rpm: command not found
```

in my cma.log

Any suggestions what to do?

----------

