Subscribe by Email


Showing posts with label Utilization. Show all posts
Showing posts with label Utilization. Show all posts

Saturday, June 15, 2013

What is CPU Scheduling Criteria?

Scheduling is an essential concept that serves in the multitasking, multiprocessor and distributed systems. There are several schedulers available for this purpose. But these schedulers also require a criterion up on which they can decide how to schedule the processes. In this article we discuss about these scheduling criteria. Today a number of scheduling algorithms are available and all these have different properties. This is why these may work up on different scheduling criteria. Also the chosen algorithm may favor one class of processes more than the other.

What Criteria is used by algorithms for Scheduling?


Below mentioned are some of the criteria used by these algorithms for scheduling:
1. CPU utilization:
- It is a property of a good system to keep the CPU as busy as possible all the time.
- Thus, this utilization ranges from 0 percent to 100 percent.
- However, in the systems that are loaded lightly, the range is around 40 percent and for the systems heavily loaded it ranges around 90 percent.

2. Throughput:
- The work is said to be done if the CPU is busy with the execution of the processes.
- Throughput is one measure of CPU performance and can be defined as the number of processes being executed completely in a certain unit of time.
- For example, in short transactions throughput might range around like 10 processes per second.
- In longer transactions this may range around only one process being executed in one hour.

3. Turnaround time:
- This is an important criterion from the point of view of a process.
- This tells how much time the processor has taken for execution of  a processor.
- The turnaround time can be defined as the time duration elapsed from the submission of the process till its completion.

4. Waiting time:
- The amount of time taken for the process for its completion is not affected by the CPU scheduling algorithms.
- Rather, these algorithms only affects the time when the process is in waiting state.
- The time for which the process waits is called the waiting time.

5. Response time:
- The turnaround is not a good criterion in all the situations.
- The response time is favorable in the case of the interactive systems.
- It happens many a times that a process is able to produce the output in a fairly short time compared to the expected time.
- This process then can continue with the next instructions.
- The time taken for a process from its submission till production of the first response is calculated as the response time and is another criterion for the CPU scheduling algorithms.

All these are the primary performance criteria out of which one or more can be selected by a typical CPU scheduler. These criteria might be ranked by the scheduler depending up on their importance. One common problem in the selection of performance criteria is the possibility of conflict ion between them.
For example, increasing the number of active processes will increase the CPU utilization but at the same time will decrease the response time. This is often desirable to produce reduction in waiting time and turnaround time also. In a number of cases the average measure is optimized. But there are certain cases also where it is more beneficial to optimize the maximum or the minimum values.
It is not necessary that a scheduling algorithm that maximizes the throughput will decrease the turnaround time. Out of a mix of short and long jobs, if a scheduler runs only the short jobs, it will produce the best throughput. But at the same time the turnaround time for the long jobs will be so high which is not desirable.


Friday, April 26, 2013

What is the cause of thrashing? How does the system detect thrashing? Once it detects thrashing, what can the system do to eliminate this problem?


- Thrashing takes place when the sub-system of the virtual memory of the computer system is involved in a state of paging constantly.
- It rapidly exchanges data in the memory with the data available on the disk excluding level of processing of most of the applications. 
- Thrashing leads to the degradation of the performance of the computer or may even cause it to collapse. 
- The problem may further worsen until the issue is identified and addressed. 
- If there are not enough pages available for the job, it becomes very likely that your system will suffer from thrashing since it’s an activity involving high paging. 
- This also leads to high rate of page fault. 
- This in turn cuts down the utilization of the CPU. 
- Modern systems utilize the concept of the paging system for executing many programs.
- However, this is what makes them prone to thrashing. 
- But this occurs only if the system does not have at present sufficient memory as required by the application or if the disk access time is too long. 

- Thrashing is also quite common in the communication systems where the conflicts concerning the internal bus access is common. 
- The order of magnitude or degree by which the latency and throughput of a system might degrade depends up on the algorithms and the configuration that is being used. 
- In systems making use of virtual memory systems, workloads and programs presenting insufficient locality of reference may lead to thrashing. 
- Thrashing occurs when the physical memory of the system is not able to contain in itself the workload or the program. 
- Thrashing can also be called as the constant data swapping.
- Older systems were low end computers i.e., the RAM they had was insufficient to be employed in modern usage patterns. 
- Thus, when their memory was increased they became noticeably faster. 
- This happened because of the availability of more memory which reduce the amount of swapping and thus increased the processing speed. 
- IBM system/ 370 (mainframe computer) faced this kind of situation. 
- In it a certain instruction consisted of an execute instruction pointing over to another move instruction. 
- Both of these instructions crossed the page boundary and also the source from which the data has to be moved and the destination where it was to be placed both crossed the page boundary. 
- Thus, this particular instruction altogether required 8 pages and that too at the same time in memory. 
- Now if the operating system allocated less than 8 pages, a page fault is sure to occur. 
- This page fault will lead to thrashing of all the attempts of restarting the failing instruction. 
- This may even reduce the CPU utilization to almost zero!

How can a system handle thrashing?

For resolving the problem of thrashing, the following things can be done:
1. Increasing the amount of main memory i.e., the RAM in the system. This is the best ever solution for this and will be helpful for a long term also.
2. Decreasing the number of programs to be executed by the system.
3. Replacing the programs that utilize heavy memory with their less memory utilizing equivalents.
4. Making improvements in the spatial locality.

- Thrashing can also occur in cache memory i.e., the faster storage space that is used for speeding up the data access. 
- Then it is called cache thrashing. 
- It occurs when the cache is accessed in a way that it leaves it of no benefit. 
When this happens many main memory locations compete with each other for getting the same cache lines that it turn leads to a large number of cache misses.


Friday, February 10, 2012

What are installation/ uninstallation testing? What are some tips for installation testing?

Installation testing comes under the category of quality assurance aspects. It is concerned with the procedure that the user has to follow in order to install that software. Installation may be of any type like partial, full or it might be an installation of an upgrade of the software.

SOME IMPORTANT FACTS ABOUT INSTALLATION TESTING
- Installation testing is carried out by the lead tester and configuration manager.
- Before carrying out installation testing, implementation testing is performed outside the testing environment.
- This is done to minimize the corruption of the software code.
- Usually for installing software, its package software or set up is run.
- The set up is actually a multi-configuration program.
- It plays a great role in the installation of software on a computer system.
- Every phase in the installation of software must be tested before it released to the public.
- In rare cases of distributed systems, it is some times required to change the database schemas and installation process of that particular software.
- For such situations a back up deployment plan is also prepared which can be implemented in case the release is unsuccessful.
- The deployment plan should also be tested as if it is a live plan.
- This kind of procedure for installation testing is called a “dry run”.
Installation testing and implementation testing are very closely related and in fact sometimes they are considered to be the same.
- The installation should be done as such that the installed program is able to cooperate with the other programs that are already installed on the computer system.
- If the program is installed successfully, it’s ok.
But, what if it doesn’t?
- It can cause considerable damage to the system.
- The user may need to format the whole system and reinstall everything again.
- The installation process should be tested both manually and automatically with all the possible configurations.
- Installation testing is a very time consuming process.
- Tests cases require much time to execute.

Un-installation testing also follows the same procedure.

TIPS FOR EFFECTIVE INSTALLATION AND UN-INSTALLATION TESTING

1. List all the configurations that you want to test.

2. Format one of the drives on the system and use it as the base for your testing.

3. Every time you have to execute a configuration, you can create a ghost of the basic images that will be required. This will save your time. This is the only automation that can be done in an installation or uninstallation testing.

4. You can attempt to install software on one operating system many times. Every time you uninstall the software, you can prepare the base for installation of the next configuration.

5. Always keep the flow chart of the whole testing process handy with you. With a flow chart you can how much you have progressed in the testing.

6. If previously you have installed the compact version of the software, then for the next test case install the full version.

7. If you are going according to the flow chart for installation process, then follow the same flow chart bottom up for the un-installation testing.

8. You can even use the flow chart to design automated test cases.

9. Check the amount of space that the software requires. Make sure that only that much is utilized and not more than that or less than that.

10. Always carry out installation and un-installation testing in a distributed testing environment. This helps you in managing many test cases simultaneously. You no need to manage different systems.

11. Try crashing the installation and un-installation process in between.


Sunday, December 25, 2011

What are different characteristics of endurance testing?

The term endurance defines the stamina, durability, resilience and the sufferance of something and its ability to perform actively and exert itself for a long period of time.

- Endurance also stands for the ability of the thing to resist, recover from and withstand.
- It also gives the degree of immunity of a thing towards trauma, fatigue or wounds.
- For software systems or applications, endurance testing has been developed to check the endurance of the software system or applications.
- Endurance testing is also known as soak testing.
- It is carried out to determine if the concerned software system or application can sustain the expected continuous load.
- The memory utilization is monitored during the endurance testing.
- This is done so as to check the potential memory leaks.
- The endurance is checked during the endurance testing but quite often, performance degradation is overlooked.
- The good response times and throughput are ensured throughout the life of the software system or application i.e., from the beginning of the usage of the software system or application to the last time of usage.

The endurance testing is aimed at testing the sustainability of a software system or application. Its goal is to check how the system behaves or responds under the prolonged significant pressure or load for an extended and significant period of time.

- It aims to test how the software system or application behaves under the sustained use.
- Endurance testing checks for the problems that may occur as a result of prolonged execution of the software program.
- It tests the application or the system under heavy loads of data for a desired period of time which is typically more than the normal usage time.
- Endurance testing is usually carried out to identify the problems that the software system or applications face under the prolonged execution.
- It also aims at identifying the buffer flows and memory leaks which are otherwise not identifiable without carrying out the endurance testing.
- The testing for the behavior of the program under significant load over a significant period of time is done with normal ramp down and ramp up time.

This can be illustrated with the following example:

- Always some memory is allocated to the objects of the program.
- In some cases it happens that the allocated memory is not de- allocated and thus remains occupied.
- This leads to a situation of over consumption of memory in which a chunk of memory is again and again taken away by the program whenever it is executed.

- Eventually the software program reaches a point when the leftover memory is not sufficient for the program to execute.
- At this point, the program crashes and is reported to have a breakdown. Such a situation is called a memory leak.
- Endurance testing is a part of performance testing.
- The other types of testings under performance testing include load testing, volume testing, and stress testing.
- The basic aim of the endurance is to check and correct the performance related problems being faced by the software system or application.
- Those problems appear only after the software system or application has been running for a long time under some significant load or stress.
- Some of the endurance test cases are available for free and have been checked into repository.
- It is recommended to include a report argument so that you visualize the usage of memory during the test and share it.
- The endurance tests create a real world model which employs a normal and high load pattern of usage for the software system or application to determine its potential and problems.


Tuesday, December 14, 2010

How to set up a Load Test using LoadRunner?

The important thing to understand in executing such a load test is that the load is generated at a protocol level, by the load generators, that are running scripts that are developed with the VUGen tool. Transaction times derived from the VUGen scripts do not include processing time on the client PC, such as rendering (drawing parts of the screen) or execution of client side scripts such as JavaScript.The WinRunner PC(s) is utilized to measure end user experience response times. Most load tests would not employ a WinRunner PC to measure actual response times from the client perspective but is highly recommended where complex and variable processing is performed on the desktop after data has been delivered to the client.

The LoadRunner controller is capable of displaying real-time graphs of response times as well as other measures such as CPU utilization on each of the components behind the firewall. Internal measures from products such as Oracle, Websphere are also available for monitoring during test execution.
After completion of a test, the analysis engine can generate a number of graphs and correlations to help locate any performance bottlenecks.

In simplified load test, the controller communicates directly to a load generator that can communicate directly to the load balancer. No WinRunner PC is utilized to measure actual user experience. The collection of statistics from various components is simplified as there is no firewall between the controller and the web components being measured.


Friday, October 22, 2010

Validation phase - System Testing - Performance Testing - Utilization

Utilization refers to the usage level of different system resources, such as the server's CPU, memory, network bandwidth and do forth. It is usually measured as a percentage of the maximum available level of the specific resources.

Utilization usually increases proportionally to increasing user load. However, it will top off and remain at a constant when the load continues to build up. If the specific system resource tops off at 100 percent utilization, it is very likely that this resource has become the performance bottleneck of the site. Upgrading the resource with higher capacity would allow greater throughput and lower latency thus better performance. If the measured resource does not top off close to 100 percent utilization, it is probably because one or more of the other system resources have already reached their maximum usage levels. They have become the performance bottleneck of the site.

To locate the bottleneck, there is a need to go through a long and painstaking process of running performance tests against each of the suspected resources, and then verifying if performance is improved by increasing the capacity of the resources. In many cases, performance of the site will start deteriorating to an unacceptable level well before the major system resources, such as CPU and memory, are maximized.


Facebook activity