Solved

Order/timing of startup programs

Posted on 2004-04-20
8
275 Views
Last Modified: 2013-11-24
I have an iBook G4 1 GHz running OS X 10.3 and recently installed MSN Messenger for Mac and Virex from the .Mac service.  I have an Airport Extreme card for wireless networking with an older but perfectly functional Linksys 802.11b gateway router.  Intenet access is though Earthlink DSL.

On startup both Virex and MSN Messenger try to connect to the Internet before my Airport Extreme sets up a connection through the Linksys.  The result is that both report errors - Virex because it can't update and MSN Messenger because it can't contact the server.  I can tell both apps to retry almost immediately and they work fine - the connection is there moments after they fail.   Is there some way to adjust the timing of startup applications so that the network connection is established before Virex and MSN Messenger attempt to connect?

Thanks...  Bill
0
Comment
Question by:William Polymenakos
8 Comments
 
LVL 30

Expert Comment

by:weed
Comment Utility
If the apps are listed in the startup items section of the Accounts control panel, sure. Otherwise, no.

On a side note, there is no reason to run Virex on OS X. There are a grand total of 0 virii for OS X. Yep, 0.

You may be able to fix the problem by telling your Airport Base Station to maintain a connection and not "connect when needed". Then it's ALWAYS connected.
0
 

Expert Comment

by:holleron
Comment Utility
There are easier and harder ways to accomplish what you are looking for.
The more difficult methods can also give you more options for choosing schedules or if the application is triggered by an event.

There is an excellent article at http://www.macdevcenter.com/pub/a/mac/excerpt/runmacxpanther8/index.html

You may wish to look to a Mac OS X scheduling application like Cronnix or iBeeZz.

http://www.koch-schmidt.de/cronnix/
http://www.ibeezz.com/en/index.php
0
 
LVL 23

Expert Comment

by:brettmjohnson
Comment Utility
> You may be able to fix the problem by telling your Airport Base Station to maintain
> a connection and not "connect when needed". Then it's ALWAYS connected.

This is not the problem.  I've noticed that the Airport client and Base Station take 3-10
seconds to establish a connection (handshake, DHCP, DNS, etc).  I have a cable modem
"always on" connection, so establishing a [dial-up] connection is not the problem.  But
if any network aware software attempts to do anything before the 802.11 link is completely
established, I get errors similar to billpoly (especially when waking from sleep).
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 
LVL 30

Expert Comment

by:weed
Comment Utility
If you tell the ABS to maintain a connection, there is no connection to establish. It's already established permanently. The ABS maintains it. You CAN actually "log out" on a dsl or cable modem even if its "always on" and you'd get the same delays. But if you let the ABS force it to be active all the time, your machines wont have a delay.
0
 
LVL 1

Author Comment

by:William Polymenakos
Comment Utility
I have to agree with brettmjohnson - the problem isn't that the ABS (not what I'm using in this case, but an example nonetheless) needs to maintain a broadband connection.  The problem is that the CLIENT AirPort Extreme card needs to establish the connection (handshake, etc.) with the ABS during boot.  It is while this process is taking place that some network-aware applications will start and fail due to the lack of an established connection between the client AirPort Extreme in the iBook and the ABS.  Once the connection process between the two is completed then I can retry the network-aware apps and all works fine.  I'm looking for a way to have these apps wait (or be delayed) until after a network connection is established to attempt their connections.
0
 
LVL 23

Accepted Solution

by:
brettmjohnson earned 50 total points
Comment Utility
Since I don't use MSN Messenger or Virex, I don't know if they have true OS X  style StartupItems.
If so, you should find directories for them in the /Library/StartupItems folder.  

Inside each of those directories you should find a StartupParameters.plist file.
In the StartupParameters.plist file is a line called "Requires" which details which startup
services must already be running before this new service can start.

Network aware apps like Messenger obviously require the Network service to running.
On OS X this simply seems to mean the hardware is alive and a link is present.  Naming
services may be running, but an attempt to actually resolve a name may fail because the
Network may not yet have a route to the outside world.

I suggest creating a new service (WWWaccess) that tests for a route to the outside,
perhaps using dig to resolve the name of a well known site that is not likely to be cached locally.  
This will test that external DNS is working.  If that is working, then MSN Messenger should be
able to connect up to its service, so modify Messenger's StartupParameters.plist to Require the
WWWaccess service to be active before starting.

Now WWWaccess is not a true "Service" in the Unix daemon sense, but it just runs dig with a
short timeout recording its success or failure - possibly delaying the startup sequence by a
couple of seconds (I did say short timeout).

This is all theory.  I didn't try it out.  This also will only work for StartupItems.  It probably
won't help with wake from sleep issues at all.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

This article describes in detail how to set up the iPad in the Enterprise using iPCU aka iPhone Configuration Utility.  This could also be used for the iPhone although I have not detailed out any differences. Preparation as an iPad Administrator:…
How can this article save you time AND money?  In just a few minutes you may discover something you didn't know existed that is easy enough for you to fix yourself!
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

771 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now