Installing a UPS


Blackouts and power outages (and the data loss they can cause) can happen anywhere. While Windows XP Professional contains a backup utility that can be used to protect your data, and you may use a network drive that's backed up every night for your data, you should also be concerned about keeping power going to your PC during its normal operation between backups.

A battery backup unit (also called a UPS, which is short for Uninterruptible Power Supply) can provide battery power to your system for as much as ten to fifteen minutes, which is long enough for you to save your data and shut down your system. The UPS plugs into the wall (and can act as a surge suppressor) and your computer and monitor plug into outlets on the rear of the UPS.

Electronic circuitry in the UPS continually monitors the AC line voltages, and should the voltage rise above or dip below predefined limits or fail entirely, the UPS takes over, powering the computer with its built-in battery and cutting off the computer from the AC wall outlet.

As you might imagine, to prevent data loss, the system's response time has to be very fast. As soon as the AC power gets flaky, the UPS has to take over within a few milliseconds, at most. Many (but not all) UPS models feature a serial (COM) or USB cable, which attaches to the appropriate port on your system. The cable sends signals to your computer to inform it when the battery backup has taken over and to start the shutdown process; some units may also broadcast a warning message over the network to other computers. UPS units with this feature are often called intelligent UPS units.

TIP

If the UPS you purchase (or already own) doesn't come with Windows XP-specific drivers for the shutdown and warning features, contact the vendor of the UPS for a software update.


The Power Options applet in Control Panel can be found by clicking Start, Control Panel, Performance and Maintenance, Power Options. Figure 30.14 shows the UPS tab, which enables you to select the model of UPS that's connected to your system, set up signaling for models which support automatic shutdown, and inform you of the battery's condition and how long you can expect the system to work from battery (a factor often called the UPS runtime).

Figure 30.14. The UPS tab in Power Options after a UPS model has been selected, but before the UPS has been connected.


If your UPS doesn't have provisions for automatic shutdown, its alarm will notify you when the power has failed. Shut down the computer yourself after saving any open files, grab a flashlight, and relax until the power comes back on.

UPS Considerations for Windows XP Professional

Ideally, all your workstations assigned to serious tasks (what work isn't serious?) should have UPS protection of some sort. Although it's true that well-designed programs such as Microsoft Office have auto-backup options that help to restore files in progress if the power goes out, they are not always reliable. Crashes and weird performance of applications and operating systems are enough to worry about, without adding power loss on top. And if the power fails during a disk write, you might have a rude awakening because the hard disk's filesystem could be corrupted, which is far worse than having a lost file or two.

My advice is that you guard against the ravages of power outages at all reasonable costs. With the ever-increasing power and plummeting cost of notebook computers, one of the most economically sensible solutions is to purchase notebook computers instead of desktop computers, especially for users who change locations frequently. They take up little space, they are easier to configure because the hardware complement cannot be easily altered, and they have UPSs built in. When the power fails, the battery takes over.

TIP

When you're using laptops, be sure your batteries are still working, though. With time, they can lose their capacity to hold a charge. You should cycle them once in a while to check out how long they will run. If necessary, replace them. Also, you should set up the power options on a laptop to save to disk (hibernate) in case of impending power loss. You'll typically want to set hibernation to kick in when 5 to 10 percent of battery power is remaining, just to ensure that the hard disk can start up (if sleeping) and write out the system state onto disk.


If you are using Windows XP Professional systems as servers, you'll certainly want UPS support, as discussed in the networking section of this book. Windows XP Professional can alert any connected workstation users of impending system shutdown as the UPS battery begins to drain if their UPS units are equipped with suitable software drivers. Users are warned to save their work and shut down (assuming they are running on a power source that is also functional, of course).

Before shelling out your hard-earned dough for UPS systems, you should check to see which ones are supported by Windows XP Professional. Consult the Hardware Compatibility List on the Microsoft site. Also, consider this checklist of questions:

  • Do you want to purchase a separate UPS for every workstation or one larger UPS that can power a number of computers from a single location?

  • What UPS capacity do you need for each computer? The answer depends on the power draw of the computer box, the size of the monitor, and whether you want peripherals to work on battery, too. To fully protect your network, you should also install a UPS on network devices such as routers, hubs, bridges, modems, telephones, printers, and any other network equipment. Check the real-world specs for the UPS. The capacity is also determined by how long you want the UPS to be able to operate after a complete power outage. If you just want enough time for you or another user to save work, a relatively small UPS will do. If you want to be able to get through a day's work doing stock trades, you'll need a hefty unit.

    TIP

    Network hardware and modems should be powered by the UPS, but printers should not be. Laser printers, in particular, have such high power requirements that your actual runtime for a given UPS unit will be just a fraction of what it would be if the laser printer were left off the UPS circuit. Because systems can store print jobs as temporary files until a printer is available to take them, there's no need to waste precious battery power to keep any type of printer running through a blackout.


  • What software support do you want? Do you need to keep a log of UPS activity during the day for later analysis? What about utilities that test the UPS on a regular basis to ensure it's working?

  • As I mentioned previously, Windows XP Professional has services built in for responding to a UPS's signal that an outage has occurred. They can be configured to alert users, automatically shut down the system, and/or execute a program of your choice. Automatic and graceful shutdown of the system is important in case a power failure lasts long enough to deplete the UPS batteries. In addition to connected users being warned of an impending shutdown, new users can be prevented from connecting to such a server.

TIP

In some cases, UPS vendors provide software for configuring their devices. You can use them instead of the one provided in Windows XP.


Installing and Configuring the Windows XP UPS Service

If you are going to use a UPS that doesn't support signaling to the computer via a data cable, you don't have to worry about installing or configuring the Windows XP UPS service. It won't make any difference and isn't needed.

You can install the UPS according the manufacturer's instructions or, if it's a Plug-and-Play device, follow standard procedures for installing new hardware. Typically, you connect the UPS to the power source, the computer to the UPS, and the serial cable between the UPS and the computer.

CAUTION

Be aware that normal serial cables do not cut the mustard for connecting a UPS to a Windows XP Professional machine. UPS serial cables, even between models from the same manufacturer, use different pin assignments. You're best off using the cable supplied by the maker of the UPS.


Another way to install the driver for a particular UPS model is to go to the Control Panel and run the Power Options applet, as shown in Figure 30.14. Click Select, and choose the UPS make and model you have and the COM port the UPS data cable is on, if any. The COM port is used to receive signals from the UPS about its charge level and the state of the AC power source.

If your UPS isn't listed, choose Generic Make, select Custom, and make sure to check the signal polarity settings in Table 30.6. For listed UPS devices, the polarities are preset for you.

After you select the type of UPS, return to the UPS tab of the Power Options Properties dialog, and click Configure to set up what you want Windows XP Professional to do in the event of a power interruption. The UPS Configuration dialog is shown in Figure 30.15.

Figure 30.15. Here, you can set the UPS and system behavior for cases of power outage.


Editable items on the tab differ, depending on what UPS you have installed, but they fall into the following categories:

  • The conditions that trigger the UPS device to send a signal, such as regular power supply failure, low battery power, and remote shutdown by the UPS device

  • The time intervals for maintaining battery power, recharging the battery, and sending warning messages after power failure

  • An optional executable program specified to run when power outage is sensed

  • Final behavior of Windows in case of complete discharge of the UPS backup battery (typically a graceful shutdown)

You can use Table 30.5 when you're considering the settings.

Table 30.5. The UPS Configuration Dialog Box

Option

Description

Enable All Notifications

Check this box if you want notifications of impending power failure failure to appear on the users' screens and sent to users currently connected to the computer over the LAN. The message is broadcast over the local node. It doesn't cross a router.

Seconds Between Power Failure and First Notification

Set how much time elapses between the power failure and when the power failure signal is sent to the computer. This figure is subtracted from the total expected battery life to determine when the system should begin shutdown. The range is 0 to 120 seconds.

Time Between Subsequent Power Failure Notifications

If the UPS can keep the system messages going for some time, set this time to determine how often (5 to 300 seconds) the user should be notified of impending doom. Too-frequent messages can be annoying and can unnecessarily alarm users in the case of regularly occurring power fluctuations. Messages sent too seldom can be overlooked.

Minutes on Battery Before Critical Alarm

Set how long after the UPS kicks in a critical notification and/or alarm should sound be issued, warning of imminent system shutdown. Base this setting on the capacity of the UPS and the power load of your system complement. A smart UPS might be able to signal the computer to indicate a critical state. If not, estimate on the conservative side, based on the manufacturer's manual.

When the Alarm Occurs, Run This Program

When the critical alarm goes off, you can optionally choose to run a program of no more than 30 seconds in execution time. (See the next option.)

Next, Instruct the Computer To

Set what should happen after a critical alarm goes off and an optional program runs. You can choose Shutdown or Hibernate. Hibernate allows the machine to return to the previous state after resumption of power.


Setting Polarities for a Generic UPS

For a smart UPS, serial data lines are used to communicate with the UPS. For a generic UPS, though, the data lines are ignored, and Windows uses the COM port's modem-status signaling lines. AC and battery status are received from the UPS using two of these lines, and a third line, the DTR signal, goes from the computer to the UPS. This signal can tell the UPS to turn itself off when Windows XP Professional has finished shutting down. This capability helps extend the life of the UPS batteries by avoiding a full discharge.

If your UPS isn't listed among those supported and you don't have Windows XP-compatible drivers you can install, Windows XP Professional doesn't know what your UPS is capable of and how it sends signals to the computer, if at all. When you choose Generic and then choose Custom, you see a Next button. Clicking it brings up the dialog box shown in Figure 30.16.

Figure 30.16. Here, you can set custom polarities for a UPS that Windows XP Professional doesn't know how to preconfigure.


Assuming the UPS has a serial link to the computer, you can set the port and fill in the blanks as necessary. Turn off all the options if the UPS has no serial link to a COM port. As the dialog box warns, you should consult the manufacturer or manual to ensure the settings are correct.

Table 30.6 describes the salient settings in the UPS polarities.

Table 30.6. UPS Polarities

Setting

Description

Power Fail/On Battery

Can the UPS send a power failure signal on the CTS (clear-to-send) pin of the serial link? If so, check this box, and indicate which voltage polarity (+ or ) signals the failure. These interface voltages indicate the active state for the signal. For example, if you select a negative interface voltage for the power failure signal, the normally positive signal becomes negative when a power failure occurs.

Low Battery

Can the UPS send a low-battery signal on the DCD (data-carrier-detect) pin of the serial link? If so, check this box and set the polarity.

UPS Shutdown

Can the UPS receive a signal from the Windows XP machine on the DTR (data-terminal-ready) pin of the serial link? (This signal is used to tell the UPS when the battery power is no longer needed either because the AC source was revived or because the computer shuts off.) If so, check the box, and indicate which voltage polarity (+ or ) signals the cessation of battery power need.


Running a Command When the Power Fails

The UPS Configuration dialog box has an option for running an executable file when a power failure is detected. It is an option only. Warning messages are sent out (assuming those options are supported and turned on) regardless of whether you choose this option. However, you might want to run a specific executable before the computer is shut down.

If you use this option, make sure the program or script you choose can execute in 30 seconds or less. Failure to complete execution in 30 seconds jeopardizes the safe shutdown of your Windows computer.

Do the following to declare and set up the executable file:

1.

In the UPS Configuration dialog box, select the When the Alarm Occurs, Run This Program check box, and then click Configure.

2.

In the resulting UPS System Shutdown Program dialog box, select the Task tab.

3.

Type the name of the file in the Run field.

4.

If you want the scheduled task to run at a specified time, select the Enabled (Scheduled Task Runs at Specified Time) check box, and continue this procedure.

5.

Select the Schedule tab, and then select the frequency and start time of the task.

6.

You can make additional schedule settings by clicking the Settings tab.

7.

Set any additional options you want in the Scheduled Task Completed, Idle Time, and Power Management areas of the Settings tab; then click OK.

8.

In the Set Account Information dialog box, type the Run As and password information, and then click OK.

TIP

The command file must reside in your %SystemRoot%\System32 folder and have a filename extension, such as .EXE, .COM, .BAT, or .CMD.


To learn more details about the Run As setting, p. 1065.


Testing Your UPS Configuration

Testing your UPS configuration from time to time is wise, just to make sure you aren't let down when a real emergency occurs. Follow these steps to do so:

1.

Close any open documents or programs.

2.

Simulate a power failure by disconnecting the power to the UPS device. Check to see that, after disconnecting the power to the UPS device, the computer and peripherals connected to the UPS device continue operating and that a warning message appears on the screen.

3.

Wait until the UPS battery reaches a low level, at which point a system shutdown should occur.

4.

If the UPS service is configured to run a command file, check to see that it executes in under 30 seconds.

5.

Restore power to the UPS device.

6.

Check the system log in the Event Viewer to ensure that all actions were logged and that no errors occurred.



Special Edition Using Microsoft Windows XP Professional
Special Edition Using Microsoft Windows XP Professional (3rd Edition)
ISBN: 0789732807
EAN: 2147483647
Year: 2003
Pages: 450

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net