Page 1 of 2 12>
Topic Options
#153434 - 2005-12-15 06:58 AM Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
Hi,

I m writing a script which will install patches on a number of machines. the patches will be kept on a server.
e.g. run \\Machine-Name\Folder-Name\Windows2000-KBXXXXXX-x86-ENU.EXE /s


for this i will have to create a scheduled task on all machines. This task will run kix32.exe (kept on server) for each machine.

Is it possible to have only one single scheduled task kept on the server. this will run the executable individually for each machine.
the problem is that run does not accept arguments for remote execution. i.e. i want to run Executable1 kept on Server1 using the script Kix1 (again on server1) for MACHINE1, something similar to SMS Push.

Thank you.

Top
#153435 - 2005-12-20 06:13 AM Re: Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
Hi,
It seems to me as if I have asked so dumb a question that nobody wants to answer it or is it that such activity (Installing on remote m/c) is just not possible ?
Please reply.

Top
#153436 - 2005-12-20 09:33 AM Re: Installing executables on a remote machine
Richard H. Administrator Offline
Administrator
*****

Registered: 2000-01-24
Posts: 4946
Loc: Leatherhead, Surrey, UK
Search the board for KSMS - it may do everything you need, and if not it will at least give you some ideas how to get started.
Top
#153437 - 2005-12-20 11:16 AM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
also search for RemoteExec. remember the issues of user context when working on remote machines, the local system account doesn't have network access, so you will either have to provide a domain user account with local admin, or push the file to the client pc, and then let a system account install it
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153438 - 2005-12-20 11:22 AM Re: Installing executables on a remote machine
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11616
Loc: CA
Was just going to suggest your UDF Rad.

Dang, 5:20 AM go back to bed, you're not in the Army anymore Rad.

Top
#153439 - 2005-12-20 12:55 PM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
naa, my daughter just discovered myspace.com, and 4am is the only time I can get to use my PC
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153440 - 2005-12-20 01:06 PM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
actually, I was looking into making a admin level patch install client for people whose users aren't local admin.

basically it would be something like a user app that checks the reg for patches installed vs. patches available in a network share, and then copies the exe to a folder on the PC

then a "service" polls that folder, looks for files, verifies it some way, installs it, and then prompts the user to restart.

It isn't much code to write, ther is really only 3 or 4 elements to it.
* client to check reg and patches (user perms) and copy new one
* client to poll for patches copied to 'special folder' local admin (system acct)
* installer to create service (admin privledges, possibly pushed by admin tool)
* possibly a code section to configure reg keys for variables like source and dest folders, freq of checking, freq of prompts to user for rebooting, etc. (minor details)
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153441 - 2005-12-29 06:11 PM Re: Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
Hi All,
It really took me some time to atleast know a tip of KSMS. (It's too much for my brain )
I am currently trying Radimus's fnRemoteExec.
[CODE]
$computer = "inf-hw-25941a" ; Remote computer name
$rc = fnRemoteExec('regsvr32 c:\WINNT\KX95.dll /s', $computer)
[/CODE]

The dll is on my local machine in WINNT folder. When i run this script from my local m/c, it gives me unknown failure (8) error.
Am i missing anything?

Top
#153442 - 2005-12-29 06:18 PM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
the file needs to be on the remote machine

copy it to the remote PC.
the command that is executed must be as if you were typing it at the remote PC's console
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153443 - 2005-12-29 06:20 PM Re: Installing executables on a remote machine
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
and dont forget, KX95.dll isn't a DLL you can regsvr32 anyways.
Top
#153444 - 2005-12-29 06:30 PM Re: Installing executables on a remote machine
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Quote:

and dont forget, KX95.dll isn't a DLL you can regsvr32 anyways.



...and it certainly must NOT be put on any NT class machine!
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#153445 - 2005-12-30 06:35 AM Re: Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
I tried that too. This time i kept the executable on the remote machine, but it still gave the error 8.
Code:
  
$computer = "itl-hw-22254d" ;Remote machine
$rc = fnRemoteExec('c:\WINNT\yahoo.exe', $computer)

? $rc


One more thing, i m running the script from XP machine, while the remote machine has 2K Pro installed on it.

Top
#153446 - 2005-12-30 06:52 AM Re: Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
Quote:

the file needs to be on the remote machine

copy it to the remote PC.
the command that is executed must be as if you were typing it at the remote PC's console




If the file is to be copied to the remote m/c then the whole purpose of my script gets defeated. I wanted that the file & the script BOTH should be kept on the Server & should run from there itself.

I am getting a wild idea, using Radimus's fnRemoteExec, is it possible to copy the file on server location to the remote machine & then run the same.

Top
#153447 - 2005-12-30 08:04 AM Re: Installing executables on a remote machine
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11616
Loc: CA
Should be possible. Shawn has also recently released a new RUNNAS utility that might be able to do what you're wanting to do.
Top
#153448 - 2005-12-30 12:24 PM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
read the remarks of the RemoteExec() UDF.

The remoteexec process has NO NETWORK PERMISSIONS, it cam only execute local (to the remote machine)

Therefore, you will have to push all the necessary files to the remote PC and then execute with remoteexec
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153449 - 2005-12-31 07:47 AM Re: Installing executables on a remote machine
tylan Offline
Starting to like KiXtart

Registered: 2005-11-17
Posts: 115
Loc: Johnstown, PA
I noticed that the original post referenced a MS patch. If you are working with security patches it's well worth the effort to set up WSUS on a 2003 server. It's free, and it's a great MS patch management solution.

I do realize that this is a KiX board, but why reinvent the wheel? That is, if there's already a free wheel that does what you need! I apologize if this is way off of what you are looking for...

Top
#153450 - 2005-12-31 07:52 AM Re: Installing executables on a remote machine
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
The simplest answer is that you may not be allowed a win2k3 server or management doesn't want WSUS.

I work for a gov't agency and it would take the net admins 3 years of testing before they would attempt it... We still haven't upgraded all the desktops to XP yet... and there are still a few NT servers floating out there.

I'm sure it is great and all, but it isn't all things to all people
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#153451 - 2005-12-31 02:27 PM Re: Installing executables on a remote machine
tylan Offline
Starting to like KiXtart

Registered: 2005-11-17
Posts: 115
Loc: Johnstown, PA
And there is also the ever so slight chance that AstaaLavista has never heard of WSUS. I was just throwing it out there.

I know what you mean about management. When MS was going to discontinue support on SUS so many people complained. I couldn't figure out why when WSUS is clearly superior in every way. Like you pointed out... good old red tape. Who wants change when you have to fill out 'TPS report' after 'TPS report' and explain something technical to non-technical users! All just to install needed security patches.

I do appreciate that you didn't blast me for thinking outside the KiXtart 'box'.

Top
#153452 - 2005-12-31 04:10 PM Re: Installing executables on a remote machine
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11163
Loc: Boston, MA, USA
KSMS is based on utilizing the Task Scheduler, just take a look at the ScheduleTask() UDF.
_________________________
There are two types of vessels, submarines and targets.

Top
#153453 - 2006-01-01 07:49 AM Re: Installing executables on a remote machine
AstaaLavista Offline
Starting to like KiXtart

Registered: 2005-08-11
Posts: 111
Loc: Gujarat, India.
I agree with Radimus & Tylan.
I hadn't heard about WSUS, but when i have heard about it, i cant use it because the netadmins wont allow me to use it.
so i will have to write a kix script that will do the work for me.

Top
Page 1 of 2 12>


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 53 anonymous users online.
Newest Members
Janneman, standardbruker, maikoenig2001, Animade, baddog1229
17771 Registered Users

Generated in 0.045 seconds in which 0.012 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org