MOON
Server: Apache/2.2.31 (Unix) mod_ssl/2.2.31 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4
System: Linux csr818.wilogic.com 2.6.18-419.el5xen #1 SMP Fri Feb 24 22:50:37 UTC 2017 x86_64
User: digitals (531)
PHP: 5.4.45
Disabled: NONE
Upload Files
File: //proc/self/root/scripts.20110531.215904.25158/whichrpm
#!/usr/bin/perl
# cpanel - whichrpm                               Copyright(c) 2010 cPanel, Inc.
#                                                           All rights Reserved.
# copyright@cpanel.net                                         http://cpanel.net
# This code is subject to the cPanel license. Unauthorized copying is prohibited

BEGIN { unshift @INC, '/scripts', '/usr/local/cpanel'; }

$| = 1;

use cPanelRPM;

my $rpm = cPanelRPM->new;

if ( $ARGV[0] eq "--install" ) {
    shift(@ARGV);
    $install = 1;
}
if ( $0 =~ /getrpmfor/i ) {
    $install = 1;
}

$item = $rpm->whatprovides( $ARGV[0] );

print "${item}\n";

if ( $install && $item ne "" ) {
    $rpm->install($item);
}

sub safeaprestart {
    if ( -x "/usr/local/cpanel/bin/safeapacherestart" ) {
        system("/usr/local/cpanel/bin/safeapacherestart");
    }
    else {
        if ( -x "/usr/bin/killall" ) {
            system( "/usr/bin/killall", "-USR1", "httpd" );
        }
        elsif ( -x "/usr/sbin/killall" ) {
            system( "/usr/sbin/killall", "-USR1", "httpd" );
        }
        elsif ( -x "/sbin/killall" ) {
            system( "/sbin/killall", "-USR1", "httpd" );
        }
        elsif ( -x "/bin/killall" ) {
            system( "/bin/killall", "-USR1", "httpd" );
        }
        elsif ( -x "/usr/local/bin/killall" ) {
            system( "/usr/local/bin/killall", "-USR1", "httpd" );
        }
        elsif ( -x "/usr/local/sbin/killall" ) {
            system( "/usr/local/sbin/killall", "-USR1", "httpd" );
        }
    }
}