Put in special for common now (like that we can do for vnx ;)
This commit is contained in:
Quentin Garnier 2014-09-18 15:40:06 +02:00
parent e63ca9f690
commit 3bd72cc0ea
20 changed files with 51 additions and 51 deletions

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::custom; package centreon::common::emc::navisphere::custom::custom;
use strict; use strict;
use warnings; use warnings;
@ -74,7 +74,7 @@ sub new {
"timeout:s@" => { name => 'timeout' }, "timeout:s@" => { name => 'timeout' },
}); });
} }
$options{options}->add_help(package => __PACKAGE__, sections => 'CLARIION OPTIONS', once => 1); $options{options}->add_help(package => __PACKAGE__, sections => 'NAVISPHERE OPTIONS', once => 1);
$self->{output} = $options{output}; $self->{output} = $options{output};
$self->{mode} = $options{mode}; $self->{mode} = $options{mode};
@ -221,13 +221,13 @@ __END__
=head1 NAME =head1 NAME
Clariion Navisphere
=head1 SYNOPSIS =head1 SYNOPSIS
my navisphere manage my navisphere manage
=head1 CLARIION OPTIONS =head1 NAVISPHERE OPTIONS
=over 8 =over 8
@ -258,7 +258,7 @@ To be used for set a file. (Need to change command and use 'cat' instead).
=item B<--hostname> =item B<--hostname>
Emc Clariion SP Hostname. Emc Clariion/VNX SP Hostname.
=item B<--secfilepath> =item B<--secfilepath>

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::cache; package centreon::common::emc::navisphere::mode::cache;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::controller; package centreon::common::emc::navisphere::mode::controller;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::disk; package centreon::common::emc::navisphere::mode::disk;
sub get_absolute { sub get_absolute {
my ($self, %options) = @_; my ($self, %options) = @_;

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::faults; package centreon::common::emc::navisphere::mode::faults;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::hbastate; package centreon::common::emc::navisphere::mode::hbastate;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -35,7 +35,7 @@
# Based on Apache Mode by Simon BOMM # Based on Apache Mode by Simon BOMM
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::listluns; package centreon::common::emc::navisphere::mode::listluns;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::portstate; package centreon::common::emc::navisphere::mode::portstate;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -33,21 +33,21 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::sp; package centreon::common::emc::navisphere::mode::sp;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);
use strict; use strict;
use warnings; use warnings;
use storage::emc::clariion::mode::spcomponents::fan; use centreon::common::emc::navisphere::mode::spcomponents::fan;
use storage::emc::clariion::mode::spcomponents::lcc; use centreon::common::emc::navisphere::mode::spcomponents::lcc;
use storage::emc::clariion::mode::spcomponents::psu; use centreon::common::emc::navisphere::mode::spcomponents::psu;
use storage::emc::clariion::mode::spcomponents::battery; use centreon::common::emc::navisphere::spcomponents::battery;
use storage::emc::clariion::mode::spcomponents::memory; use centreon::common::emc::navisphere::spcomponents::memory;
use storage::emc::clariion::mode::spcomponents::cpu; use centreon::common::emc::navisphere::spcomponents::cpu;
use storage::emc::clariion::mode::spcomponents::iomodule; use centreon::common::emc::navisphere::spcomponents::iomodule;
use storage::emc::clariion::mode::spcomponents::cable; use centreon::common::emc::navisphere::spcomponents::cable;
use storage::emc::clariion::mode::spcomponents::sp; use centreon::common::emc::navisphere::spcomponents::sp;
sub new { sub new {
my ($class, %options) = @_; my ($class, %options) = @_;
@ -86,33 +86,33 @@ sub component {
my ($self, %options) = @_; my ($self, %options) = @_;
if ($self->{option_results}->{component} eq 'all') { if ($self->{option_results}->{component} eq 'all') {
storage::emc::clariion::mode::spcomponents::fan::check($self); centreon::common::emc::navisphere::mode::spcomponents::fan::check($self);
storage::emc::clariion::mode::spcomponents::lcc::check($self); centreon::common::emc::navisphere::mode::spcomponents::lcc::check($self);
storage::emc::clariion::mode::spcomponents::psu::check($self); centreon::common::emc::navisphere::mode::spcomponents::psu::check($self);
storage::emc::clariion::mode::spcomponents::battery::check($self); centreon::common::emc::navisphere::mode::spcomponents::battery::check($self);
storage::emc::clariion::mode::spcomponents::cable::check($self); centreon::common::emc::navisphere::mode::spcomponents::cable::check($self);
storage::emc::clariion::mode::spcomponents::iomodule::check($self); centreon::common::emc::navisphere::mode::spcomponents::iomodule::check($self);
storage::emc::clariion::mode::spcomponents::memory::check($self); centreon::common::emc::navisphere::mode::spcomponents::memory::check($self);
storage::emc::clariion::mode::spcomponents::cpu::check($self); centreon::common::emc::navisphere::mode::spcomponents::cpu::check($self);
storage::emc::clariion::mode::spcomponents::sp::check($self); centreon::common::emc::navisphere::mode::spcomponents::sp::check($self);
} elsif ($self->{option_results}->{component} eq 'sp') { } elsif ($self->{option_results}->{component} eq 'sp') {
storage::emc::clariion::mode::spcomponents::sp::check($self); centreon::common::emc::navisphere::mode::spcomponents::sp::check($self);
} elsif ($self->{option_results}->{component} eq 'fan') { } elsif ($self->{option_results}->{component} eq 'fan') {
storage::emc::clariion::mode::spcomponents::fan::check($self); centreon::common::emc::navisphere::mode::spcomponents::fan::check($self);
} elsif ($self->{option_results}->{component} eq 'lcc') { } elsif ($self->{option_results}->{component} eq 'lcc') {
storage::emc::clariion::mode::spcomponents::lcc::check($self); centreon::common::emc::navisphere::mode::spcomponents::lcc::check($self);
} elsif ($self->{option_results}->{component} eq 'psu') { } elsif ($self->{option_results}->{component} eq 'psu') {
storage::emc::clariion::mode::spcomponents::psu::check($self); centreon::common::emc::navisphere::mode::spcomponents::psu::check($self);
} elsif ($self->{option_results}->{component} eq 'battery') { } elsif ($self->{option_results}->{component} eq 'battery') {
storage::emc::clariion::mode::spcomponents::psu::check($self); centreon::common::emc::navisphere::mode::spcomponents::psu::check($self);
} elsif ($self->{option_results}->{component} eq 'memory') { } elsif ($self->{option_results}->{component} eq 'memory') {
storage::emc::clariion::mode::spcomponents::memory::check($self); centreon::common::emc::navisphere::mode::spcomponents::memory::check($self);
} elsif ($self->{option_results}->{component} eq 'cpu') { } elsif ($self->{option_results}->{component} eq 'cpu') {
storage::emc::clariion::mode::spcomponents::cpu::check($self); centreon::common::emc::navisphere::mode::spcomponents::cpu::check($self);
} elsif ($self->{option_results}->{component} eq 'io') { } elsif ($self->{option_results}->{component} eq 'io') {
storage::emc::clariion::mode::spcomponents::iomodule::check($self); centreon::common::emc::navisphere::mode::spcomponents::iomodule::check($self);
} elsif ($self->{option_results}->{component} eq 'cable') { } elsif ($self->{option_results}->{component} eq 'cable') {
storage::emc::clariion::mode::spcomponents::cable::check($self); centreon::common::emc::navisphere::mode::spcomponents::cable::check($self);
} else { } else {
$self->{output}->add_option_msg(short_msg => "Wrong option. Cannot find component '" . $self->{option_results}->{component} . "'."); $self->{output}->add_option_msg(short_msg => "Wrong option. Cannot find component '" . $self->{option_results}->{component} . "'.");
$self->{output}->option_exit(); $self->{output}->option_exit();

View File

@ -33,7 +33,7 @@
# #
#################################################################################### ####################################################################################
package storage::emc::clariion::mode::spinfo; package centreon::common::emc::navisphere::mode::spinfo;
use base qw(centreon::plugins::mode); use base qw(centreon::plugins::mode);

View File

@ -48,17 +48,17 @@ sub new {
$self->{version} = '0.1'; $self->{version} = '0.1';
%{$self->{modes}} = ( %{$self->{modes}} = (
'cache' => 'storage::emc::clariion::mode::cache', 'cache' => 'centreon::common::emc::navisphere::mode::cache',
'controller' => 'storage::emc::clariion::mode::controller', 'controller' => 'centreon::common::emc::navisphere::mode::controller',
'disk' => 'storage::emc::clariion::mode::disk', 'disk' => 'centreon::common::emc::navisphere::mode::disk',
'sp' => 'storage::emc::clariion::mode::sp', 'sp' => 'centreon::common::emc::navisphere::mode::sp',
'faults' => 'storage::emc::clariion::mode::faults', 'faults' => 'centreon::common::emc::navisphere::mode::faults',
'list-luns' => 'storage::emc::clariion::mode::listluns', 'list-luns' => 'centreon::common::emc::navisphere::mode::listluns',
'sp-info' => 'storage::emc::clariion::mode::spinfo', 'sp-info' => 'centreon::common::emc::navisphere::mode::spinfo',
'port-state' => 'storage::emc::clariion::mode::portstate', 'port-state' => 'centreon::common::emc::navisphere::mode::portstate',
'hba-state' => 'storage::emc::clariion::mode::hbastate', 'hba-state' => 'centreon::common::emc::navisphere::mode::hbastate',
); );
$self->{custom_modes}{clariion} = 'storage::emc::clariion::custom'; $self->{custom_modes}{clariion} = 'centreon::common::emc::navisphere::custom::custom';
return $self; return $self;
} }