Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Linux Timesaving Techniques For Dummies.pdf
Скачиваний:
59
Добавлен:
15.03.2015
Размер:
15.98 Mб
Скачать

302 Technique 41: Keeping an Eye on Your System

2. Enter the number of rows and columns you want in the new worksheet and then click OK.

Your new worksheet is created, ready for new sensors.

Drag multiple sensors onto a bar graph display to compare sensor values.

KDE System Guard has a few resizing issues. If a worksheet gets too full (or contains too many sensors), it likes to delete titles and/or hide the sensor browser selector. It’s nothing personal — it does that to everyone.

Creating system resource logs

You can use KDE System Guard to create system resource logs to your custom specifications. If the system seems slow at 1:00 p.m., when your users come back from lunch, you can create a custom resource log to help confirm your suspicions and track down the bottlenecks.

To create a custom resource log, follow these steps:

1. Click the New icon on the toolbar to create a new worksheet.

The Worksheet Properties dialog opens.

2. Enter a title for the worksheet and click OK.

A blank worksheet appears, ready for the new sensors.

3. Drag sensors onto the worksheet.

Here are some sensors you may want to include in a system usage log:

Free Physical Memory

Free Swap Memory

CPU Load

Disk Throughput

Throughout the day, watch the sensors that we mention and see how they change as your system load changes throughout the day. Watching how the sensors vary will help you identify resource bottlenecks. For example, if Disk Throughput is very high but CPU Load is low, you know that your computer is spending a lot of time waiting for the disk drive (and you may want to invest in some more drives to share the load).

As you add each sensor, here’s how to spot the bottlenecks:

1. Choose the Sensor Logger type from the pop-up menu.

The Sensor Logger dialog opens, as shown in Figure 41-21.

Figure 41-21: The Sensor Logger dialog.

2.Complete the Sensor Logger dialog for each sensor:

Enter the name of the file that you want to contain the sensor log.

Keeping an Eye on Resources with KDE System Guard 303

If you’d like the log to alert you to extreme drops in resources, check the Enable Alarm box in the Alarm for Minimum Value frame and enter a Lower Limit value in the activated field.

If you want the log to alert you to extreme spikes in resource usage, check the Enable Alarm box in the Alarm for Maximum Value frame, and enter an Upper Limit value in the activated field.

3.When you suspect a system slowdown, rightclick on each sensor and choose Start Logging to start the log files.

Keep an eye on your sensor logs. They can get really huge really fast (and eat up the resources you’re trying to preserve)!

4. When you suspect the system is returning to normal, right-click on the sensor and choose Stop Logging to stop the logs.

Most log files are written to the /var/log directory, but if you haven’t started KDE System Guard with superuser privileges, be sure to write the logs to a file you have the privileges to create.

If you’ve told System Guard to alert you when extreme values are reached, the worksheet changes the sensor name to red and notifies you based upon the settings in your Control Center. To customize your notification settings for KDE System Guard, follow these steps:

1. Open the Main Menu and choose Control

Center.

2. Expand the Sound and Multimedia entry in the

Index tree control.

3. Click System Notifications.

4. From the drop-down list at the top of the screen, choose KDE System Guard.

The System Notifications window opens, as shown in Figure 41-22. Use this dialog to customize system notifications for KDE System Guard and other tools on your system. Several options for alert customization are available. Experiment to find a combination that will help you get your work done, but not drive you nuts with whistles, klaxons, and pop-ups.

5. After you finish changing the System

Notifications, click Apply and then close the Control Center.

• Figure 41-22: The System Notifications window.

Displaying network resources

One really cool feature of KDE System Guard is its ability to monitor resources on other computers. System Guard supports a number of methods for establishing a remote connection, but the quickest (and most foolproof) is to use SSH.

Follow these steps to add sensors for another computer:

1. Click the Connect Host icon on the toolbar

(the icon looks like a plug and socket, plugged together).

The Connect Host dialog opens, as shown in Figure 41-23.

304 Technique 41: Keeping an Eye on Your System

Figure 41-23: The Connect Host dialog.

2.Enter a host name in the Host field, or choose a host from the drop-down list.

3.The ssh option button is chosen by default. If you don’t have an ssh connection to the other machine, click the Help button for information about other connection types.

Better yet, see Technique 33 for help setting up an SSH connection. ssh is easy to use and your best bet.

4. Click OK.

If you’ve configured public-key authentication for the remote host (see Technique 33), the computer name appears in the sensor list. If not, you have to enter a user name and password before the remote computer appears. Now you can create comparison worksheets showing computer against computer, as shown in Figure 41-24.

• Figure 41-24: System comparison worksheet — Kaga versus Kobe.

This is a great way to monitor network load and disk space. Set up signal-plotter graphs for each resource or use bar graphs to compare resources.

Create a bar graph by dragging the same resources from each machine on a network into a single sensor frame to compare resource usage on the fly. It’s easy to spot at a glance which system has resources to spare and which system needs help.

Taking the time to explore KDE System Guard can really add to your productivity levels. It’s a great timesaving tool that gives you the information in just about any configuration you could want.

Part VIII

Serving Up the Internet

and More

42 Keeping an Apache

Server in Top Form

Technique

Save Time By

Using Synaptic or your distribution’s installer to resolve Apache’s dependencies

Using OpenOffice.org Writer to set up a quick Web page

Using dynamic DNS to keep your server at home, but make your data available to the world

Using the HTTP Configuration tool to make easy changes to your Apache server

The Apache Web server is without a doubt the most popular Web server today. It’s easy to use, and it’s powerful. You can use Apache to serve up data to users on your own network or to locations

across the Web.

If your company is already bogged down with e-mail, using a Web server can be a great way to publish information to users on your network. You can create company newsletters and change important information quickly and easily with a WYSIWIG editor like OpenOffice.org. Users can easily browse to the company’s local site to find out what’s going on without your making the information available for the whole world to see.

If you do want to take your site public, you may or may not want to rent space on someone else’s host machine. Keeping a server up and running on your local network is a great idea if your site requires a lot of monitoring and upkeep. With dynamic DNS, you keep just a name and IP address registered on someone else’s server — your data stays home where you can take good care of it. Your IP address may change, but your host name never will. If your IP address changes, you update the new address to the name server. When customers or associates search for you by name across the Internet, the name server relays the current IP address to them to complete the search. You save the high cost of machine rental on someone else’s servers, and because your system is local, maintenance is quick and easy.

In this technique, we show you how to get your Apache server running at full speed in no time. We also show you a few quick tools you can use to populate and distribute your Web site and to keep it running in good condition. Serving up data is simple and quick with Apache.

Setting Up Apache — Quick!

The Apache Web server is easy to install, but it has quite a few dependencies (53!) that can really slow you down. The easiest (and quickest) way to install Apache is from disc (with your distribution’s installer) or by downloading and installing it with Synaptic.

Соседние файлы в предмете Операционные системы