Solved

system setups - nt

Posted on 2000-03-08
4
194 Views
Last Modified: 2010-03-05
Just a little example, not too little, to get me started please.

How do you get to NT system setups via perl scripts.  For example,
I need to set up the peer services and tcp and would like to run
a script to do it.   AND, aside,  is it possible to run a perl distribution off
a floppy?  If not, I can make a CDROM.

I'll head over to activeware and poke around but would still like an
example.  Thanks.
0
Comment
Question by:hank1
  • 3
4 Comments
 
LVL 5

Expert Comment

by:PC_User321
ID: 2597659
If you can do it from the command line, you can do it with perl.


 Directory of A:\

CW3230MT DLL       319,488  08-10-97 11:11a cw3230mt.dll
PERL     DLL       561,152  08-10-97 11:11a perl.dll
PERL     EXE         8,192  08-10-97 11:11a perl.exe
         3 file(s)        888,832 bytes
         0 dir(s)         568,832 bytes free
0
 
LVL 5

Accepted Solution

by:
PC_User321 earned 50 total points
ID: 2599098
Here is a simple example of using ARP:-



`arp -s 200.20.180.144 23-45-67-9a-bc-de`;
@Arps = `arp -a`;
$HostNumber = 1;
foreach $Line (@Arps) {
   if( $Line =~ /^\s*[0-9]+\.[0-9]+/) {
      $HostHash{$HostNumber} = $Line;
      print "$HostNumber. $Line";
      $HostNumber++;
   } else {
      print "  $Line";
   }
}
print "Which host would you like to delete?   ";
chomp($ToDelete = <>);
if (defined($HostHash{$ToDelete})) {
   @Words = split ' ', $HostHash{$ToDelete};
   print "Going to do arp -d $Words[0]\n";
   `arp -d $Words[0]`;
   print "\nResult:-\n";
   print `arp -a`;
}

0
 

Expert Comment

by:KuznesofAA
ID: 2604366
Although not as powerfull, you can do quite a number of things with vbscript and the footprint is a bit lighter.

Follow this link:

http://cwashington.netreach.net/main_site/default.asp?topic=news

for a good site on vbscript.

If you want to use Perl install the ActiveState distribution www.activestate.com and

look at the Win32 options, in particular:

Win32::NetAdmin
Win32::NetResource

Hope that helps.
0
 
LVL 5

Expert Comment

by:PC_User321
ID: 6869183
0

Featured Post

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
In the distant past (last year) I hacked together a little toy that would allow a couple of Manager types to query, preview, and extract data from a number of MongoDB instances, to their tool of choice: Excel (http://dilbert.com/strips/comic/2007-08…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question