[Spacewalk-list] Problems with remote commands on some systems

Edward Dore edward.dore at freethought-internet.co.uk
Tue Nov 2 00:43:43 UTC 2010


I've finally had some time to fire up a couple of test cPanel virtual machines and found exactly the same result on both machines. These are 64-bit CentOS 5.5 machines with a fairly stripped down install.

After installing the machine, I registered it with our Spacewalk 1.1 server and I can run remote commands via OSAD without any problems, but after then subsequently installing cPanel the remote commands silently fail in the same way as before.

Are any of the parts of Spacewalk that handle the remote command feature written in Perl or use something else which cPanel has replaced? I can provide you remote access to a test system with cPanel installed Mike if you want to have a poke around?

The remote command that I was trying to run for the test was simply:

> echo "test"

So it seems to me that it isn't a problem with the remote command itself, but whichever part of the Spacewalk codebase is responsible for picking up and processing remote commands is objecting to something that cPanel does when it is installed.
I have no idea where to even start looking in the Spacewalk code base and even if I found which area was responsible for remote actions, I likely wouldn't know what to do with it!

When installing cPanel, it installs it's own versions of the following binaries in /usr/local/bin so that they take precedence on the PATH:

-bash-3.2# ls /usr/local/bin
a2p            cpandb       enc2xs      imgsize    lwp-download  pear       perlcc      piconv     pod2usage   ptar        sa-update     spfquery  ttree
bdf2gdfont.pl  crc32        find2perl   instmodsh  lwp-dump      peardev    perldoc     pl2pm      podchecker  ptardiff    shasum        splain    xsubpp
c2ph           dbilogstrip  findrule    ip2cc      lwp-mirror    pecl       perlivp     pod2html   podselect   pwhich      spamassassin  srs
chartex        dbiprof      graph-easy  ipcount    lwp-request   perl       php         pod2latex  prove       s2p         spamc         srsc
config_data    dbiproxy     h2ph        iptab      lwp-rget      perl5.8.8  php-config  pod2man    psed        sa-compile  spamd         stty.pl
cpan           dprofpp      h2xs        libnetcfg  oscartest     perlbug    phpize      pod2text   pstruct     sa-learn    spfd          tpage

Edward Dore 
Freethought Internet 

> On 4 Oct 2010, at 13:53, Edward Dore wrote:
> 
> Mike,
> 
> Yeah, if I run the scripts manually from bash via SSH then they run as intended and give the expected output (they are the initial system configuration scripts scheduled by dell-satellite-sync to work out which channels to subscribe a system to, but even if I schedule a simple echo command then it fails with the same 256 return code and no output).
> 
> SELinux is set to permissive mode, so shouldn't be interfering with anything.
> 
> Generally all of the working and non-working systems are near identical. They are all kickstarted off the same config file and are kept vaguely similar to each other. The only difference I can think of is cPanel, which is only installed on the three that aren't working.
> 
> I will spin up a blank machine to test before and after installing cPanel when I get a chance.
> 
> Edward Dore
> 
> ----- Original Message -----
> From: "Michael Mraka" <michael.mraka at redhat.com>
> To: spacewalk-list at redhat.com
> Sent: Monday, 4 October, 2010 12:31:55 PM
> Subject: Re: [Spacewalk-list] Problems with remote commands on some systems
> 
> Edward Dore wrote:
> % Mike,
> % 
> % Ah, that's better, much more verbose! Output at
> % http://pastebin.com/s7nW1YLp It doesn't mean a great deal more to me,
> % doesn't look to have much more in the way of details, but hopefully it
> % will mean something to you :)
> % 
> % I've just kicked my brain in to gear and realised that the common
> % thing between these three servers is that they are running cPanel
> % which likes to compile it's own perl from scratch and install it over
> % the top of the one provided in the RHEL/CentOS RPM!
> 
> That's good to know but I'm affraid there is something more different as
> none of scripts in the log above touches perl.
> 
> Does the scripts do what they are supposed to when run manually?
> Another thing -  Is selinux enabled? Are there any AVC denials in
> audit.log?
> 
> The strange thing is
> 
>   Sending back response (1, 'Script failed', {'output': '', ...
> 
> because rpm -q should output something either on installed or missing key.
> 
> Regards,
> 
> --
> Michael Mráka
> Satellite Engineering, Red Hat
> 
> _______________________________________________
> Spacewalk-list mailing list
> Spacewalk-list at redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
> 
> _______________________________________________
> Spacewalk-list mailing list
> Spacewalk-list at redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
> 




More information about the Spacewalk-list mailing list