• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 610
  • Last Modified:

Detect that user is on a slow link

I would like to be able to run a command-line utility at the start of my domain logon script to determine whether a user is connected to the network over a slow link ("slow" being a configurable parameter). A value would be returned (via errorlevel?) which would allow me to tailor what else runs from the logon script.

Example: LAN-connected users would download and execute a virus scan program from the server. Users connected by modem would bypass this step, as it might take as long as 20 minutes to complete depending on modem speed and line quality.

It has been suggested before that I use NETSPEED, which comes with SMS, but I have not been able to find sufficient information even in the SMS Resource Kit, to apply it.

I would be grateful for a reference either to some other utility I could use for this function, or for sufficient information to be able to use NETSPEED.
0
wclemens
Asked:
wclemens
1 Solution
 
wclemensAuthor Commented:
Edited text of question
0
 
wclemensAuthor Commented:
Edited text of question
0
 
otCommented:
It would be much simpler to set an environment variable on the modem-connected PC's, and base scanning on this variable.

0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
wclemensAuthor Commented:
(1) Corporate environment with many non-technical users. I cannot depend on them either to set an environment variable or not screw it up even if it were originally set correctly by IS group. Even if this could be overcome, ...
(2) Many users have notebook computers which sometimes are connected to the LAN and sometimes dial in. The solution must adjust to dynamic conditions.
0
 
bcookCommented:
I do s aimilar thing to work out which site I'm on.

When I log in, I run a bit of perl script, which does and
ipconfigure, and fings the TCP/IP number from that.
This IP number tells me where I am.

If you have a predetermined set of IP numbers allocated for
remote login, this could be used to work it out.

If IP numbers are a problem for you, then you could use 'dumpevt' from the NT resource kit to dump a small section of the event log.  You could then see what type of login occured for this user most recently.  This may be a bit too slow though.

The other thing to do is to log the user in on both, and see
if there's a consistant env variable that's different between
the sessions (Slim change in this case)
0
 
wclemensAuthor Commented:
Interesting, but back to the original question: Is there an already-existing utility I can use to determine, from a command line, that a user is on a slow link? Or can someone provide sufficient information about NETSPEED, which I already have as part of SMS, to be able to apply it independently?

Using IPCONFIG to determine IP address is something I have considered before, and if I could reliably detect the existence of IP address in one of several particular ranges, that would be a step in the right direction although, for a variety of reasons, it is not a complete solution to my problem. Parsing the IPCONFIG response into a "slow" or "not slow" is a missing piece. The variety of ways that users access our corporate LAN now and in the future would make the IP ranges a moving target. Also, the same script needs to run on Windows for Workgroups, Windows 95, and Windows NT clients.

0
 
uliCommented:
- http://www.microsoft.com/kb/
- search for 'netspeed'
- 3 articles about how-to/limitations/gotchas.
0
 
wclemensAuthor Commented:
Already viewed these three articles before posting the question. The information there gives some hints but only in a full SMS context of using NETSPEED. Since we have not yet rolled out SMS, modifying SMS registry settings as suggested is not applicable to my situation. I don't know, in fact, if NETSPEED can even be used effectively on a stand-alone basis.
0
 
pgjCommented:
The ICMP protocol (basis of the ping utility) records the round-trip time of a packet.  All you need to do is run a script that: 1) pings a known machine on the corporate net; 2) saves the results into a file; 3) compares the result to a threshold for deciding whether it's a remote machine or not.  In my experience, a ping across a PPP link will take over 100 ms, a ping across a T-1 under 40ms, and a ping across a LAN under 10.  Averaging several pings would be a good idea.  ping is a standard utility on NT and W95.  Here's a sample of the output of the ping command:

C:\>ping netcom.com > a.tmp

C:\>cat a.tmp

Pinging netcom.com [192.100.81.100] with 32 bytes of data:

Reply from 192.100.81.100: bytes=32 time=10ms TTL=249
Reply from 192.100.81.100: bytes=32 time=24ms TTL=249
Reply from 192.100.81.100: bytes=32 time=26ms TTL=249
Reply from 192.100.81.100: bytes=32 time=11ms TTL=249

This approach has the advantage of being based on actual round-trip times, satisfying your "dynamic" criteria.  A perl script to extract and average the "time=" values should be trivial.


0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now