Ryna --

...and then Ryan A said...
% 
% Hey David,

Hiya!


% 
% % Is it possible to run a SSH command from php?
% >Sure; it's possible to run any command from php.  It may not work all
% >that well, though :-)
% 
% heheh, good one. As helpful as usual :-D

Always there for ya, man :-)


% 
% >Good enough.  What do you want to do?
% 
% Basically stop/restart apache when i make changes to the httpd.conf file.

There are ways to do that -- I personally would create a kick script
outside of the htdocs tree, give the apache user permission to run that,
and call that script from an https page with some authentication -- but
you always have to fall back to "if that script fails, then I need to log
in and use the shell" anyway.


% But then thinking of it I realize that if I stop apache from a script, once
% apache is stopped
% I cant run any php to restart it...right?

You certainly can't run any php web script :-)


% So I guess my question gets cut down to basically "any good place/program to
% learn/use SSH?"

As you've been shown, ssh is nothing magical; what you want to do is
learn how to use a *NIX shell.  Think DOS command prompt.  If you can
already use a command prompt, then try an ssh in and look around (ls,
chdir, pwd, ...).


HTH & HAND

:-D
-- 
David T-G                      * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/      Shpx gur Pbzzhavpngvbaf Qrprapl Npg!

Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to