SlideShare une entreprise Scribd logo
1  sur  5
Télécharger pour lire hors ligne
ISSN: 2278 – 1323
            International Journal of Advanced Research in Computer Engineering & Technology
                                                                Volume 1, Issue 4, June 2012


      Device Driver Fault Simulation Using
                                                         KEDR
Shakti D Shekar                                  Prof. Dr. B B Meshram                      Prof. Varshapriya
VJTI, Mumbai                                     VJTI, Mumbai                               VJTI, Mumbai
shaktishekar10@gmail.com                         bbmeshram@vjti.org.in                      varshapriyajn@vjti.org.in

Abstract- The failure resilience of a system is very important       operations then server system must have
for availability and reliability. The systems like servers or
systems where reliability and availability is highly demanding       mechanism that should isolate or conceal this
data loss is unacceptable during failures. The study on              failure and can continue receiving or transmitting
system crash stated that most of the failures in operating
                                                                     operation as if there were no failures that is there
system environment are due to drivers failures. The device
driver failure is very important in kernel environment. Once         should be no data loss because of driver failure.
device driver failed detected system should cope with the            Thus such server system must have fault detection
failure and continue its operation for zero data loss. The
system availability and reliability during various types of          mechanism,      fault   isolation    and    recovery
driver faults can be tested using fault injection or fault           mechanism to make feel to the system that there
simulation tools. In this paper we discuss related work in           were no faults in the system. In this paper we have
resilience of drivers and we have simulated the faults using
free tool available under KEDR framework.                            discussed fault simulation mechanism using free
                                                                     tool available in KEDR frame work on Linux
Keywords- Availability, Reliability, Fault Simulation, KEDR
                                                                     platform. The paper is organized as follows:
1 Introduction                                                       section 2 deals with related work, section 3 deals
The device driver is a kernel module which allows                    with required architecture, section 4 deals with
kernel to access hardware. Mostly kernel crash is                    KDER frame work, section 5 deals with fault
due to failures of drivers. The reason behind                        simulation, section 6 deals with fault detection,
driver failure is that new devices available increase                section 7 deals with future work and finally we
the number of driver programs which are not come                     concluded in section 8.
with operating system code. Thus device driver
programmers are different form operating system                      2 Related Work
programmers. The small bug into device driver can                    The research have been done on device driver
crash whole system or makes system unstable and                      failures and there recovery mechanism.           For
unreliable. Sometimes rebooting of system can                        MINIX system a postmortem recovery procedure
cope with problem of failure, but this is not                        is given and continues normal operation in event
acceptable in case of need of high availability like                 of failures [1]. Here reincarnation server constantly
server system. So to make system highly available                    monitors system and if problem detected
faults need to be isolate with continuing its                        reincarnation server takes action for recovery
operation and to make system highly reliable zero                    procedure. Thus it provides failure resilience.
data loss need to be maintained in case of failure.                    The virtualized system like XEN adopts isolated
This means that once device drivers failures occurs                  I/O architecture which performs I/O device
there should be mechanism that conceals or isolate                   accesses. The switching mechanism provided to
the failures and with guarantee of no data loss.                     switch from faulted driver virtual machine to
Thus system should include module that can                           another one for fault tolerance [2]. In new XEN
bypass all operations of device driver in case of                    architecture driver domain is isolated from
failure detection with minimum delay and as if                       hypervisor and known as isolated driver domain
there was no failure inside the kernel and while                     (IDD). In [2], to detect faults of an IDD new
doing this data should not be lost. For example                      mechanism introduced named Driver VM Monitor
server is receiving or transmitting packets over                     which periodically decides the fault state of IDDs
network, if network device driver failed during



                                                                                                                     580
                                                All Rights Reserved © 2012 IJARCET
ISSN: 2278 – 1323
          International Journal of Advanced Research in Computer Engineering & Technology
                                                              Volume 1, Issue 4, June 2012

and also it does not require kernel or application            of GNU General Public License Version 2. The
level modification.                                           KEDR tools can work on kernel modules to detect
Another approach is Nooks [3] which provides                  memory leaks, perform fault simulation and more.
protected environment for driver execution. Nooks             It can operate on a kernel module chosen by the
wrap calls from the operating system kernel into              user as opposed to existing tools that usually
device drivers and from device drivers into the               operate on Linux kernel as a whole. We can work
kernel. In Nooks all drivers execute in kernel                with target module and at the same time we can
address space but within different protection                 run KEDR tools for monitoring the operations of
domains. In Nooks recovery is provided by                     modules, checking if it works correctly, doing fault
restarting the driver but it does not conceal the             simulation, doing future analysis based on traced
failure.                                                      output. The KEDR cannot detect call to kmalloc
                                                              because it is usually a micro or an inline function
Another approach is shadow driver [4] which is                but it can detect functions which kmalloc expands.
kernel agent which monitors device drivers and                At a time we can analyze only one kernel module.
transparently recovers from driver failures. It
conceals driver failure from its client while                 4.1 System Requirements
recovering from failure. The working of shadow                KEDR system can work on Linux Kernel version
driver is as follows: during normal operation                 2.6.31 or newer and only x86 and x86-64
shadow driver tracks the state of normal driver by            architectures are supported.
monitoring all communication between the kernel
and driver, when failure occurs, shadow insert                5 Fault Simulation [7]
itself temporarily in placed of failed driver                 From Linux kernel 2.6.20 fault injection framework
servicing request on its behalf. The shadow driver            is provided to injects failures in several layers in
includes Nooks and recovery system.                           kernel like kmalloc(), alloc_pages and disk IO
                                                              errors. By injecting faults on purpose we can test
                                                              behavior of kernel module after fault injection
3 Architecture                                                because some errors do not occurs in all situations.
The system to make highly available and reliable              In MINIX operating system SWIFI (software
during failure, system must conceal failures and              implemented fault injection) is available for fault
start recovery procedure. To test system for                  injection [5]. In this paper we are using a free tool
availability and reliability firstly we should have           for fault simulation available under KEDR frame
fault injection frame work or fault simulation                work [9].
frame work to inject or simulate faults into kernel
modules manually and secondly we should have                  In kernel module sometimes some code paths
fault detection mechanism to detect faults into               rarely executes and to see behavior of kernel
kernel in case of successful fault injection and              module for such code path the fault simulation
thirdly very important component which conceals               provided by KEDR is useful. The KEDR can see
the faults and should take in charge of failed driver         such rare condition’s behavior of target module.
module to make feel to the system that there were             Here for target kernel module we have used driver
no faults. While switching operation of failed                module from examples provided in KEDR
driver to module who can take in charge of failed             example directory. KEDR provides special
component there should be minimum switching                   configuration file for fault simulation fsim.conf.
delay and zero data loss.                                     We have run KEDR on Ubuntu Linux 11.10 with
                                                              kernel 2.6.39.4.
4 KEDR Framework
                                                              5.1 Simulation for kmalloc
KEDR stands for Kernel Drivers in Runtime [6].
                                                              Fig. 1 shows how KEDR can be used for fault
KEDR framework provides the tools to perform
                                                              simulation. To use KEDR for fault simulation we
runtime analysis of kernel modules like devices
                                                              must have kernel module. First line shows make
drivers, file system modules, etc. KEDR framework
                                                              command to build .ko file, a kernel module. After
is free software and is distributed under the terms



                                                                                                              581
                                         All Rights Reserved © 2012 IJARCET
ISSN: 2278 – 1323
         International Journal of Advanced Research in Computer Engineering & Technology
                                                             Volume 1, Issue 4, June 2012

this we need to start KEDR (line no.11) for fault          no. 22. Next we need to set scenario common for
simulation using target module name and using              any fault simulation point. After this we have set
configuration file. Note that here we have used            value 1 to expression meaning that fail always.


 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# make
 make -C /lib/modules/3.0.0-12-generic/build M=`pwd` modules
 make[1]: Entering directory `/usr/src/linux-headers-3.0.0-12-generic'
   CC [M] /home/sony/Desktop/sample_target/cfake.o
   LD [M] /home/sony/Desktop/sample_target/kedr_sample_target.o
   Building modules, stage 2.
   MODPOST 1 modules
   CC /home/sony/Desktop/sample_target/kedr_sample_target.mod.o
   LD [M] /home/sony/Desktop/sample_target/kedr_sample_target.ko
 make[1]: Leaving directory `/usr/src/linux-headers-3.0.0-12-generic'
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# /usr/local/bin/kedr start
 kedr_sample_target -f fsim.conf
 Starting KEDR...
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr.ko target_name=kedr_sample_target
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fault_simulation.ko
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_cmm.ko
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_user_space_access.ko
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_capable.ko
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_mem_util.ko
 /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_vmm.ko
 KEDR started.
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod /usr/local/lib/modules/`uname -
 r`/misc/kedr_fsim_indicator_common.ko
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" >
 /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/current_indicator
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" >
 /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/expression
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko
 insmod: error inserting 'kedr_sample_target.ko': -1 Cannot allocate memory
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "0" >
 /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/expression
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko
 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target#


                                            Fig. 1



sample_target as an example from the examples              By doing this we have set the scenario that module
provided by KEDR and for configuration we have             will not get memory for target module loading
used fsim.conf, a configuration file provided by           operation. To check this we have executed insmod
KEDR. Now KEDR is loaded and connected with                for loading of target module and we got exactly
our sample kernel module. At this point KEDR               what we want. At line no. 29 we got an error
loads many fault simulation modules like                   message that cannot allocate memory. At next line
kedr_fault_simulation.ko, kedr_fsim_cmm.ko and             we have set value 0 to expression to make fault
so on. Now to make KEDR aware of all types of              simulation fail. This value is by default meaning
simulation    we    need    to    load    module           that never simulate the fault. At next line we have
kedr_fsim_indicator_common.ko as shown at line             executed insmod and this time no error message



                                                                                                          582
                                      All Rights Reserved © 2012 IJARCET
ISSN: 2278 – 1323
          International Journal of Advanced Research in Computer Engineering & Technology
                                                              Volume 1, Issue 4, June 2012

that means successful loading of target module                 13. Now to make these function always failed we
that is memory got allocated to target module.                 have set value 1 to expression file in both

...
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod /usr/local/lib/modules/`uname -
r`/misc/kedr_fsim_indicator_common.ko
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" >
/sys/kernel/debug/kedr_fault_simulation/points/copy_from_user/current_indicator
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" >
/sys/kernel/debug/kedr_fault_simulation/points/copy_to_user/current_indicator
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "This is fault simulation by KEDR" >
/dev/cfake0
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# cat /dev/cfake0
This is fault simulation by KEDR
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" >
/sys/kernel/debug/kedr_fault_simulation/points/copy_to_user/expression
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" >
/sys/kernel/debug/kedr_fault_simulation/points/copy_from_user/expression
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "This is fault simulation by KEDR to
make operation failed" > /dev/cfake0
bash: echo: write error: Bad address
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# cat /dev/cfake0
cat: /dev/cfake0: Bad address
root@sony-VPCEB14EN:/home/sony/Desktop/sample_target#



                                               Fig. 2


5.2 Simulation       for   copy_from_user        and           copy_to_user and copy_from_user as shown at line
copy_to_user                                                   no. 15 and line no. 17. Now after doing read-write
Here in next example we have simulated faults for              operations on target module we got an error
copy_from_user and copy_to_user functions using                message “Bad address”. This means that fault got
same kernel module example provided by KEDR                    simulated.
example directory. In fig. 2 we have skipped the
output of make and starting KEDR using fsim.conf               6 Fault Detection
file because that will be same as before. After this           The fault detection can be done by looking at
again load the common fault simulation module of               errors from standard error output or by looking at
KEDR that is kedr_fsim_indicator.ko. Now to set                error log files or checking by return value from
fault simulation point set value “common” to                   target module operation.
current indicator in copy_from_user and
copy_to_user directories as shown at line no. 3 and            7 Future Work
line no.6 of the fig. 2. After this we have loaded the         The reliability and availability of system is very
target module. As here we have to simulate faults              important and for this continuous research is going
for the functions which copies data from and to                on. In case of failures due to kernel modules like
user for device drivers, we need to read data from             device drivers we must have mechanism to cope
or write data into loaded target module that is                with failures. To check system reliability and
device driver read-write operations. This is shown             availability we have proposed very generic
as successful operations at line no. 11 and line no.



                                                                                                              583
                                          All Rights Reserved © 2012 IJARCET
ISSN: 2278 – 1323
          International Journal of Advanced Research in Computer Engineering & Technology
                                                              Volume 1, Issue 4, June 2012

mechanism that will cope with various types of                mechanism for important operations of device
failures in kernel due to device drivers.                     drivers that is memory allocation and device driver
                                                              read-write operations. Thus to simulate the faults
                                                              into dynamic kernel modules KEDR is very useful.

                                                              REFREENCES
                                                              [1] Jorrit N. Herder, Herbert Bos, Ben Gras, Philip Homburg,
                                                              and Andrew S. Tanenbaum. “Failure Resilience for Device
                                                              Drivers” 37th Annual IEEE/IFIP International Conference on
                                                              Dependable Systems and Networks (DSN'07).
                                                              [2] Heeseung Jo, Hwanju Kim, Jae-Wan Jang, Joonwon Lee,
                                                              and Seungryoul Maeng. “Transparent Fault Tolerance of
                                                              Device      Drivers    for   Virtual   Machines”       IEEE
                                                              TRANSACTIONS ON COMPUTERS, VOL. 59, NO. 11,
                                                              NOVEMBER 2010
                                                              [3] Michael M. Swift, Steven Martin, Henry M. Levy, and
                                                              Susan J. Eggers “Nooks: An Architecture for Reliable Device
                                                              Drivers” Proceedings of the Tenth ACM SIGOPS European
                                                              Workshop, Saint-Emilion, France, Sept. 2002.
                                                              [4] Michael M. Swift, Muthukaruppan Annamalai, Brian N.
                                                              Bershad, and Henry M. Levy “Recovering Device Drivers”
                                                              Proceedings of the 6th ACM/USENIX Symposium on
                                                              Operating Systems Design and Implementation, San
                                                              Francisco, CA, Dec. 2004. .
                                                              [5]http://nooks.cs.washington.edu/
                                                              [6]http://kedr.berlios.de/
                                                              [7]http://kedr.berlios.de/kedrdoc/
                                                                 kedr_manual_getting_stared.html



                       Fig. 3

Fig. 3 shows that there are four modules in the
kernel, first the KEDR which is for fault simulation,
second device drivers, third fault detection module
which will continuously monitors device drivers
operations using return value and if it success in
failure detection then it will trigger forth module
recovery module. The recovery module will have
mechanism to cope with failures and while doing
this work we need to maintain minimum delay
and no data loss.

8 Conclusion
The operating system is reliable and available only
when it can cope with failures and make its
services continue without affecting. The device
driver failures concealing and recovering
mechanism with zero data loss can improve
operating system reliability and availability. The
KEDR frame work can be used to simulate faults
into kernel modules. In this paper we have
discussed and showed the KEDR fault simulation



                                                                                                                     584
                                         All Rights Reserved © 2012 IJARCET

Contenu connexe

Tendances

Comp tia a+_session_03
Comp tia a+_session_03Comp tia a+_session_03
Comp tia a+_session_03
Niit Care
 
Safety control systems: Some essential considerations
Safety control systems: Some essential considerationsSafety control systems: Some essential considerations
Safety control systems: Some essential considerations
Optima Control Solutions
 
Semper Continuity Suite Product Profile V6
Semper Continuity Suite   Product Profile V6Semper Continuity Suite   Product Profile V6
Semper Continuity Suite Product Profile V6
mlulham
 
Pcm600 v2.5 installation guide
Pcm600 v2.5 installation guidePcm600 v2.5 installation guide
Pcm600 v2.5 installation guide
faqrelion
 
09 intel v_tune_session_13
09 intel v_tune_session_1309 intel v_tune_session_13
09 intel v_tune_session_13
Niit Care
 
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
faqrelion
 
Comp tia a+_session_09
Comp tia a+_session_09Comp tia a+_session_09
Comp tia a+_session_09
Niit Care
 
Comp tia a+_session_02
Comp tia a+_session_02Comp tia a+_session_02
Comp tia a+_session_02
Niit Care
 
Comp tia a+_session_05
Comp tia a+_session_05Comp tia a+_session_05
Comp tia a+_session_05
Niit Care
 
Comp tia a+_session_14
Comp tia a+_session_14Comp tia a+_session_14
Comp tia a+_session_14
Niit Care
 

Tendances (19)

Chaudhari thesis-2014
Chaudhari thesis-2014Chaudhari thesis-2014
Chaudhari thesis-2014
 
DYNAMIC ROOT OF TRUST AND CHALLENGES
DYNAMIC ROOT OF TRUST AND CHALLENGESDYNAMIC ROOT OF TRUST AND CHALLENGES
DYNAMIC ROOT OF TRUST AND CHALLENGES
 
Intel speed-select-technology-base-frequency-enhancing-performance
Intel speed-select-technology-base-frequency-enhancing-performanceIntel speed-select-technology-base-frequency-enhancing-performance
Intel speed-select-technology-base-frequency-enhancing-performance
 
Comp tia a+_session_03
Comp tia a+_session_03Comp tia a+_session_03
Comp tia a+_session_03
 
UVM BASED REUSABLE VERIFICATION IP FOR WISHBONE COMPLIANT SPI MASTER CORE
UVM BASED REUSABLE VERIFICATION IP FOR WISHBONE COMPLIANT SPI MASTER COREUVM BASED REUSABLE VERIFICATION IP FOR WISHBONE COMPLIANT SPI MASTER CORE
UVM BASED REUSABLE VERIFICATION IP FOR WISHBONE COMPLIANT SPI MASTER CORE
 
PCM600
PCM600PCM600
PCM600
 
Safety control systems: Some essential considerations
Safety control systems: Some essential considerationsSafety control systems: Some essential considerations
Safety control systems: Some essential considerations
 
Ispe Article
Ispe ArticleIspe Article
Ispe Article
 
Semper Continuity Suite Product Profile V6
Semper Continuity Suite   Product Profile V6Semper Continuity Suite   Product Profile V6
Semper Continuity Suite Product Profile V6
 
Pcm600 v2.5 installation guide
Pcm600 v2.5 installation guidePcm600 v2.5 installation guide
Pcm600 v2.5 installation guide
 
09 intel v_tune_session_13
09 intel v_tune_session_1309 intel v_tune_session_13
09 intel v_tune_session_13
 
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
1 mrg002586 configuration_migration_for_670_series_in_pcm600_user_manual
 
Guia instalação PCM600 ABB
Guia instalação PCM600 ABBGuia instalação PCM600 ABB
Guia instalação PCM600 ABB
 
Comp tia a+_session_09
Comp tia a+_session_09Comp tia a+_session_09
Comp tia a+_session_09
 
VTU 5TH SEM CSE SOFTWARE ENGINEERING SOLVED PAPERS - JUN13 DEC13 JUN14 DEC14 ...
VTU 5TH SEM CSE SOFTWARE ENGINEERING SOLVED PAPERS - JUN13 DEC13 JUN14 DEC14 ...VTU 5TH SEM CSE SOFTWARE ENGINEERING SOLVED PAPERS - JUN13 DEC13 JUN14 DEC14 ...
VTU 5TH SEM CSE SOFTWARE ENGINEERING SOLVED PAPERS - JUN13 DEC13 JUN14 DEC14 ...
 
Comp tia a+_session_02
Comp tia a+_session_02Comp tia a+_session_02
Comp tia a+_session_02
 
08 Midlet Basic
08 Midlet Basic08 Midlet Basic
08 Midlet Basic
 
Comp tia a+_session_05
Comp tia a+_session_05Comp tia a+_session_05
Comp tia a+_session_05
 
Comp tia a+_session_14
Comp tia a+_session_14Comp tia a+_session_14
Comp tia a+_session_14
 

En vedette (7)

Total Browser Pwnag3 V1.0 Public
Total Browser Pwnag3   V1.0 PublicTotal Browser Pwnag3   V1.0 Public
Total Browser Pwnag3 V1.0 Public
 
Tu sitio de encuentro
Tu sitio de encuentroTu sitio de encuentro
Tu sitio de encuentro
 
Volume 2-issue-6-2077-2080
Volume 2-issue-6-2077-2080Volume 2-issue-6-2077-2080
Volume 2-issue-6-2077-2080
 
Agm Slideshow 3.09
Agm Slideshow 3.09Agm Slideshow 3.09
Agm Slideshow 3.09
 
Leyla Presentation At Sogeti![1]
Leyla Presentation At Sogeti![1]Leyla Presentation At Sogeti![1]
Leyla Presentation At Sogeti![1]
 
Sem 27 02 09 4
Sem 27 02 09 4Sem 27 02 09 4
Sem 27 02 09 4
 
357 366
357 366357 366
357 366
 

Similaire à 580 584

Joanna Rutkowska Subverting Vista Kernel
Joanna Rutkowska   Subverting Vista KernelJoanna Rutkowska   Subverting Vista Kernel
Joanna Rutkowska Subverting Vista Kernel
guestf1a032
 
Embedded os
Embedded osEmbedded os
Embedded os
chian417
 

Similaire à 580 584 (20)

Java remote control for laboratory monitoring
Java remote control for laboratory monitoringJava remote control for laboratory monitoring
Java remote control for laboratory monitoring
 
FAILURE FREE CLOUD COMPUTING ARCHITECTURES
FAILURE FREE CLOUD COMPUTING ARCHITECTURESFAILURE FREE CLOUD COMPUTING ARCHITECTURES
FAILURE FREE CLOUD COMPUTING ARCHITECTURES
 
Failure Free Cloud Computing Architectures
Failure Free Cloud Computing ArchitecturesFailure Free Cloud Computing Architectures
Failure Free Cloud Computing Architectures
 
SIMULATION-BASED APPLICATION SOFTWARE DEVELOPMENT IN TIME-TRIGGERED COMMUNICA...
SIMULATION-BASED APPLICATION SOFTWARE DEVELOPMENT IN TIME-TRIGGERED COMMUNICA...SIMULATION-BASED APPLICATION SOFTWARE DEVELOPMENT IN TIME-TRIGGERED COMMUNICA...
SIMULATION-BASED APPLICATION SOFTWARE DEVELOPMENT IN TIME-TRIGGERED COMMUNICA...
 
lecture 1 (Part 2) kernal and its categories
lecture 1 (Part 2) kernal and its categorieslecture 1 (Part 2) kernal and its categories
lecture 1 (Part 2) kernal and its categories
 
how-to-bypass-AM-PPL
how-to-bypass-AM-PPLhow-to-bypass-AM-PPL
how-to-bypass-AM-PPL
 
Linux Assignment 3
Linux Assignment 3Linux Assignment 3
Linux Assignment 3
 
Joanna Rutkowska Subverting Vista Kernel
Joanna Rutkowska   Subverting Vista KernelJoanna Rutkowska   Subverting Vista Kernel
Joanna Rutkowska Subverting Vista Kernel
 
Kernel and its Types
Kernel and its TypesKernel and its Types
Kernel and its Types
 
cloud computing:Types of virtualization
cloud computing:Types of virtualizationcloud computing:Types of virtualization
cloud computing:Types of virtualization
 
ITT Project Information Technology Basic
ITT Project Information Technology BasicITT Project Information Technology Basic
ITT Project Information Technology Basic
 
LDTT : A Low Level Driver Unit Testing Tool
LDTT : A Low Level Driver Unit Testing Tool LDTT : A Low Level Driver Unit Testing Tool
LDTT : A Low Level Driver Unit Testing Tool
 
Factors Affecting the System Safety || Linux
Factors Affecting the System Safety || LinuxFactors Affecting the System Safety || Linux
Factors Affecting the System Safety || Linux
 
Ch13.pptx
Ch13.pptxCh13.pptx
Ch13.pptx
 
IRJET- Development of Uncrackable Software
IRJET- Development of Uncrackable SoftwareIRJET- Development of Uncrackable Software
IRJET- Development of Uncrackable Software
 
Kernels and its types
Kernels and its typesKernels and its types
Kernels and its types
 
Embedded multiple choice questions
Embedded multiple choice questionsEmbedded multiple choice questions
Embedded multiple choice questions
 
Embedded os
Embedded osEmbedded os
Embedded os
 
Studienarb linux kernel-dev
Studienarb linux kernel-devStudienarb linux kernel-dev
Studienarb linux kernel-dev
 
www.ijerd.com
www.ijerd.comwww.ijerd.com
www.ijerd.com
 

Plus de Editor IJARCET

Volume 2-issue-6-2205-2207
Volume 2-issue-6-2205-2207Volume 2-issue-6-2205-2207
Volume 2-issue-6-2205-2207
Editor IJARCET
 
Volume 2-issue-6-2195-2199
Volume 2-issue-6-2195-2199Volume 2-issue-6-2195-2199
Volume 2-issue-6-2195-2199
Editor IJARCET
 
Volume 2-issue-6-2200-2204
Volume 2-issue-6-2200-2204Volume 2-issue-6-2200-2204
Volume 2-issue-6-2200-2204
Editor IJARCET
 
Volume 2-issue-6-2190-2194
Volume 2-issue-6-2190-2194Volume 2-issue-6-2190-2194
Volume 2-issue-6-2190-2194
Editor IJARCET
 
Volume 2-issue-6-2186-2189
Volume 2-issue-6-2186-2189Volume 2-issue-6-2186-2189
Volume 2-issue-6-2186-2189
Editor IJARCET
 
Volume 2-issue-6-2177-2185
Volume 2-issue-6-2177-2185Volume 2-issue-6-2177-2185
Volume 2-issue-6-2177-2185
Editor IJARCET
 
Volume 2-issue-6-2173-2176
Volume 2-issue-6-2173-2176Volume 2-issue-6-2173-2176
Volume 2-issue-6-2173-2176
Editor IJARCET
 
Volume 2-issue-6-2165-2172
Volume 2-issue-6-2165-2172Volume 2-issue-6-2165-2172
Volume 2-issue-6-2165-2172
Editor IJARCET
 
Volume 2-issue-6-2159-2164
Volume 2-issue-6-2159-2164Volume 2-issue-6-2159-2164
Volume 2-issue-6-2159-2164
Editor IJARCET
 
Volume 2-issue-6-2155-2158
Volume 2-issue-6-2155-2158Volume 2-issue-6-2155-2158
Volume 2-issue-6-2155-2158
Editor IJARCET
 
Volume 2-issue-6-2148-2154
Volume 2-issue-6-2148-2154Volume 2-issue-6-2148-2154
Volume 2-issue-6-2148-2154
Editor IJARCET
 
Volume 2-issue-6-2143-2147
Volume 2-issue-6-2143-2147Volume 2-issue-6-2143-2147
Volume 2-issue-6-2143-2147
Editor IJARCET
 
Volume 2-issue-6-2119-2124
Volume 2-issue-6-2119-2124Volume 2-issue-6-2119-2124
Volume 2-issue-6-2119-2124
Editor IJARCET
 
Volume 2-issue-6-2139-2142
Volume 2-issue-6-2139-2142Volume 2-issue-6-2139-2142
Volume 2-issue-6-2139-2142
Editor IJARCET
 
Volume 2-issue-6-2130-2138
Volume 2-issue-6-2130-2138Volume 2-issue-6-2130-2138
Volume 2-issue-6-2130-2138
Editor IJARCET
 
Volume 2-issue-6-2125-2129
Volume 2-issue-6-2125-2129Volume 2-issue-6-2125-2129
Volume 2-issue-6-2125-2129
Editor IJARCET
 
Volume 2-issue-6-2114-2118
Volume 2-issue-6-2114-2118Volume 2-issue-6-2114-2118
Volume 2-issue-6-2114-2118
Editor IJARCET
 
Volume 2-issue-6-2108-2113
Volume 2-issue-6-2108-2113Volume 2-issue-6-2108-2113
Volume 2-issue-6-2108-2113
Editor IJARCET
 
Volume 2-issue-6-2102-2107
Volume 2-issue-6-2102-2107Volume 2-issue-6-2102-2107
Volume 2-issue-6-2102-2107
Editor IJARCET
 

Plus de Editor IJARCET (20)

Electrically small antennas: The art of miniaturization
Electrically small antennas: The art of miniaturizationElectrically small antennas: The art of miniaturization
Electrically small antennas: The art of miniaturization
 
Volume 2-issue-6-2205-2207
Volume 2-issue-6-2205-2207Volume 2-issue-6-2205-2207
Volume 2-issue-6-2205-2207
 
Volume 2-issue-6-2195-2199
Volume 2-issue-6-2195-2199Volume 2-issue-6-2195-2199
Volume 2-issue-6-2195-2199
 
Volume 2-issue-6-2200-2204
Volume 2-issue-6-2200-2204Volume 2-issue-6-2200-2204
Volume 2-issue-6-2200-2204
 
Volume 2-issue-6-2190-2194
Volume 2-issue-6-2190-2194Volume 2-issue-6-2190-2194
Volume 2-issue-6-2190-2194
 
Volume 2-issue-6-2186-2189
Volume 2-issue-6-2186-2189Volume 2-issue-6-2186-2189
Volume 2-issue-6-2186-2189
 
Volume 2-issue-6-2177-2185
Volume 2-issue-6-2177-2185Volume 2-issue-6-2177-2185
Volume 2-issue-6-2177-2185
 
Volume 2-issue-6-2173-2176
Volume 2-issue-6-2173-2176Volume 2-issue-6-2173-2176
Volume 2-issue-6-2173-2176
 
Volume 2-issue-6-2165-2172
Volume 2-issue-6-2165-2172Volume 2-issue-6-2165-2172
Volume 2-issue-6-2165-2172
 
Volume 2-issue-6-2159-2164
Volume 2-issue-6-2159-2164Volume 2-issue-6-2159-2164
Volume 2-issue-6-2159-2164
 
Volume 2-issue-6-2155-2158
Volume 2-issue-6-2155-2158Volume 2-issue-6-2155-2158
Volume 2-issue-6-2155-2158
 
Volume 2-issue-6-2148-2154
Volume 2-issue-6-2148-2154Volume 2-issue-6-2148-2154
Volume 2-issue-6-2148-2154
 
Volume 2-issue-6-2143-2147
Volume 2-issue-6-2143-2147Volume 2-issue-6-2143-2147
Volume 2-issue-6-2143-2147
 
Volume 2-issue-6-2119-2124
Volume 2-issue-6-2119-2124Volume 2-issue-6-2119-2124
Volume 2-issue-6-2119-2124
 
Volume 2-issue-6-2139-2142
Volume 2-issue-6-2139-2142Volume 2-issue-6-2139-2142
Volume 2-issue-6-2139-2142
 
Volume 2-issue-6-2130-2138
Volume 2-issue-6-2130-2138Volume 2-issue-6-2130-2138
Volume 2-issue-6-2130-2138
 
Volume 2-issue-6-2125-2129
Volume 2-issue-6-2125-2129Volume 2-issue-6-2125-2129
Volume 2-issue-6-2125-2129
 
Volume 2-issue-6-2114-2118
Volume 2-issue-6-2114-2118Volume 2-issue-6-2114-2118
Volume 2-issue-6-2114-2118
 
Volume 2-issue-6-2108-2113
Volume 2-issue-6-2108-2113Volume 2-issue-6-2108-2113
Volume 2-issue-6-2108-2113
 
Volume 2-issue-6-2102-2107
Volume 2-issue-6-2102-2107Volume 2-issue-6-2102-2107
Volume 2-issue-6-2102-2107
 

Dernier

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Dernier (20)

Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 

580 584

  • 1. ISSN: 2278 – 1323 International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 4, June 2012 Device Driver Fault Simulation Using KEDR Shakti D Shekar Prof. Dr. B B Meshram Prof. Varshapriya VJTI, Mumbai VJTI, Mumbai VJTI, Mumbai shaktishekar10@gmail.com bbmeshram@vjti.org.in varshapriyajn@vjti.org.in Abstract- The failure resilience of a system is very important operations then server system must have for availability and reliability. The systems like servers or systems where reliability and availability is highly demanding mechanism that should isolate or conceal this data loss is unacceptable during failures. The study on failure and can continue receiving or transmitting system crash stated that most of the failures in operating operation as if there were no failures that is there system environment are due to drivers failures. The device driver failure is very important in kernel environment. Once should be no data loss because of driver failure. device driver failed detected system should cope with the Thus such server system must have fault detection failure and continue its operation for zero data loss. The system availability and reliability during various types of mechanism, fault isolation and recovery driver faults can be tested using fault injection or fault mechanism to make feel to the system that there simulation tools. In this paper we discuss related work in were no faults in the system. In this paper we have resilience of drivers and we have simulated the faults using free tool available under KEDR framework. discussed fault simulation mechanism using free tool available in KEDR frame work on Linux Keywords- Availability, Reliability, Fault Simulation, KEDR platform. The paper is organized as follows: 1 Introduction section 2 deals with related work, section 3 deals The device driver is a kernel module which allows with required architecture, section 4 deals with kernel to access hardware. Mostly kernel crash is KDER frame work, section 5 deals with fault due to failures of drivers. The reason behind simulation, section 6 deals with fault detection, driver failure is that new devices available increase section 7 deals with future work and finally we the number of driver programs which are not come concluded in section 8. with operating system code. Thus device driver programmers are different form operating system 2 Related Work programmers. The small bug into device driver can The research have been done on device driver crash whole system or makes system unstable and failures and there recovery mechanism. For unreliable. Sometimes rebooting of system can MINIX system a postmortem recovery procedure cope with problem of failure, but this is not is given and continues normal operation in event acceptable in case of need of high availability like of failures [1]. Here reincarnation server constantly server system. So to make system highly available monitors system and if problem detected faults need to be isolate with continuing its reincarnation server takes action for recovery operation and to make system highly reliable zero procedure. Thus it provides failure resilience. data loss need to be maintained in case of failure. The virtualized system like XEN adopts isolated This means that once device drivers failures occurs I/O architecture which performs I/O device there should be mechanism that conceals or isolate accesses. The switching mechanism provided to the failures and with guarantee of no data loss. switch from faulted driver virtual machine to Thus system should include module that can another one for fault tolerance [2]. In new XEN bypass all operations of device driver in case of architecture driver domain is isolated from failure detection with minimum delay and as if hypervisor and known as isolated driver domain there was no failure inside the kernel and while (IDD). In [2], to detect faults of an IDD new doing this data should not be lost. For example mechanism introduced named Driver VM Monitor server is receiving or transmitting packets over which periodically decides the fault state of IDDs network, if network device driver failed during 580 All Rights Reserved © 2012 IJARCET
  • 2. ISSN: 2278 – 1323 International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 4, June 2012 and also it does not require kernel or application of GNU General Public License Version 2. The level modification. KEDR tools can work on kernel modules to detect Another approach is Nooks [3] which provides memory leaks, perform fault simulation and more. protected environment for driver execution. Nooks It can operate on a kernel module chosen by the wrap calls from the operating system kernel into user as opposed to existing tools that usually device drivers and from device drivers into the operate on Linux kernel as a whole. We can work kernel. In Nooks all drivers execute in kernel with target module and at the same time we can address space but within different protection run KEDR tools for monitoring the operations of domains. In Nooks recovery is provided by modules, checking if it works correctly, doing fault restarting the driver but it does not conceal the simulation, doing future analysis based on traced failure. output. The KEDR cannot detect call to kmalloc because it is usually a micro or an inline function Another approach is shadow driver [4] which is but it can detect functions which kmalloc expands. kernel agent which monitors device drivers and At a time we can analyze only one kernel module. transparently recovers from driver failures. It conceals driver failure from its client while 4.1 System Requirements recovering from failure. The working of shadow KEDR system can work on Linux Kernel version driver is as follows: during normal operation 2.6.31 or newer and only x86 and x86-64 shadow driver tracks the state of normal driver by architectures are supported. monitoring all communication between the kernel and driver, when failure occurs, shadow insert 5 Fault Simulation [7] itself temporarily in placed of failed driver From Linux kernel 2.6.20 fault injection framework servicing request on its behalf. The shadow driver is provided to injects failures in several layers in includes Nooks and recovery system. kernel like kmalloc(), alloc_pages and disk IO errors. By injecting faults on purpose we can test behavior of kernel module after fault injection 3 Architecture because some errors do not occurs in all situations. The system to make highly available and reliable In MINIX operating system SWIFI (software during failure, system must conceal failures and implemented fault injection) is available for fault start recovery procedure. To test system for injection [5]. In this paper we are using a free tool availability and reliability firstly we should have for fault simulation available under KEDR frame fault injection frame work or fault simulation work [9]. frame work to inject or simulate faults into kernel modules manually and secondly we should have In kernel module sometimes some code paths fault detection mechanism to detect faults into rarely executes and to see behavior of kernel kernel in case of successful fault injection and module for such code path the fault simulation thirdly very important component which conceals provided by KEDR is useful. The KEDR can see the faults and should take in charge of failed driver such rare condition’s behavior of target module. module to make feel to the system that there were Here for target kernel module we have used driver no faults. While switching operation of failed module from examples provided in KEDR driver to module who can take in charge of failed example directory. KEDR provides special component there should be minimum switching configuration file for fault simulation fsim.conf. delay and zero data loss. We have run KEDR on Ubuntu Linux 11.10 with kernel 2.6.39.4. 4 KEDR Framework 5.1 Simulation for kmalloc KEDR stands for Kernel Drivers in Runtime [6]. Fig. 1 shows how KEDR can be used for fault KEDR framework provides the tools to perform simulation. To use KEDR for fault simulation we runtime analysis of kernel modules like devices must have kernel module. First line shows make drivers, file system modules, etc. KEDR framework command to build .ko file, a kernel module. After is free software and is distributed under the terms 581 All Rights Reserved © 2012 IJARCET
  • 3. ISSN: 2278 – 1323 International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 4, June 2012 this we need to start KEDR (line no.11) for fault no. 22. Next we need to set scenario common for simulation using target module name and using any fault simulation point. After this we have set configuration file. Note that here we have used value 1 to expression meaning that fail always. root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# make make -C /lib/modules/3.0.0-12-generic/build M=`pwd` modules make[1]: Entering directory `/usr/src/linux-headers-3.0.0-12-generic' CC [M] /home/sony/Desktop/sample_target/cfake.o LD [M] /home/sony/Desktop/sample_target/kedr_sample_target.o Building modules, stage 2. MODPOST 1 modules CC /home/sony/Desktop/sample_target/kedr_sample_target.mod.o LD [M] /home/sony/Desktop/sample_target/kedr_sample_target.ko make[1]: Leaving directory `/usr/src/linux-headers-3.0.0-12-generic' root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# /usr/local/bin/kedr start kedr_sample_target -f fsim.conf Starting KEDR... /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr.ko target_name=kedr_sample_target /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fault_simulation.ko /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_cmm.ko /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_user_space_access.ko /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_capable.ko /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_mem_util.ko /sbin/insmod /usr/local/lib/modules/3.0.0-12-generic/misc/kedr_fsim_vmm.ko KEDR started. root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod /usr/local/lib/modules/`uname - r`/misc/kedr_fsim_indicator_common.ko root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" > /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/current_indicator root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" > /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/expression root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko insmod: error inserting 'kedr_sample_target.ko': -1 Cannot allocate memory root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "0" > /sys/kernel/debug/kedr_fault_simulation/points/kmalloc/expression root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# Fig. 1 sample_target as an example from the examples By doing this we have set the scenario that module provided by KEDR and for configuration we have will not get memory for target module loading used fsim.conf, a configuration file provided by operation. To check this we have executed insmod KEDR. Now KEDR is loaded and connected with for loading of target module and we got exactly our sample kernel module. At this point KEDR what we want. At line no. 29 we got an error loads many fault simulation modules like message that cannot allocate memory. At next line kedr_fault_simulation.ko, kedr_fsim_cmm.ko and we have set value 0 to expression to make fault so on. Now to make KEDR aware of all types of simulation fail. This value is by default meaning simulation we need to load module that never simulate the fault. At next line we have kedr_fsim_indicator_common.ko as shown at line executed insmod and this time no error message 582 All Rights Reserved © 2012 IJARCET
  • 4. ISSN: 2278 – 1323 International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 4, June 2012 that means successful loading of target module 13. Now to make these function always failed we that is memory got allocated to target module. have set value 1 to expression file in both ... root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod /usr/local/lib/modules/`uname - r`/misc/kedr_fsim_indicator_common.ko root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" > /sys/kernel/debug/kedr_fault_simulation/points/copy_from_user/current_indicator root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "common" > /sys/kernel/debug/kedr_fault_simulation/points/copy_to_user/current_indicator root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# insmod kedr_sample_target.ko root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "This is fault simulation by KEDR" > /dev/cfake0 root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# cat /dev/cfake0 This is fault simulation by KEDR root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" > /sys/kernel/debug/kedr_fault_simulation/points/copy_to_user/expression root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "1" > /sys/kernel/debug/kedr_fault_simulation/points/copy_from_user/expression root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# echo "This is fault simulation by KEDR to make operation failed" > /dev/cfake0 bash: echo: write error: Bad address root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# cat /dev/cfake0 cat: /dev/cfake0: Bad address root@sony-VPCEB14EN:/home/sony/Desktop/sample_target# Fig. 2 5.2 Simulation for copy_from_user and copy_to_user and copy_from_user as shown at line copy_to_user no. 15 and line no. 17. Now after doing read-write Here in next example we have simulated faults for operations on target module we got an error copy_from_user and copy_to_user functions using message “Bad address”. This means that fault got same kernel module example provided by KEDR simulated. example directory. In fig. 2 we have skipped the output of make and starting KEDR using fsim.conf 6 Fault Detection file because that will be same as before. After this The fault detection can be done by looking at again load the common fault simulation module of errors from standard error output or by looking at KEDR that is kedr_fsim_indicator.ko. Now to set error log files or checking by return value from fault simulation point set value “common” to target module operation. current indicator in copy_from_user and copy_to_user directories as shown at line no. 3 and 7 Future Work line no.6 of the fig. 2. After this we have loaded the The reliability and availability of system is very target module. As here we have to simulate faults important and for this continuous research is going for the functions which copies data from and to on. In case of failures due to kernel modules like user for device drivers, we need to read data from device drivers we must have mechanism to cope or write data into loaded target module that is with failures. To check system reliability and device driver read-write operations. This is shown availability we have proposed very generic as successful operations at line no. 11 and line no. 583 All Rights Reserved © 2012 IJARCET
  • 5. ISSN: 2278 – 1323 International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 4, June 2012 mechanism that will cope with various types of mechanism for important operations of device failures in kernel due to device drivers. drivers that is memory allocation and device driver read-write operations. Thus to simulate the faults into dynamic kernel modules KEDR is very useful. REFREENCES [1] Jorrit N. Herder, Herbert Bos, Ben Gras, Philip Homburg, and Andrew S. Tanenbaum. “Failure Resilience for Device Drivers” 37th Annual IEEE/IFIP International Conference on Dependable Systems and Networks (DSN'07). [2] Heeseung Jo, Hwanju Kim, Jae-Wan Jang, Joonwon Lee, and Seungryoul Maeng. “Transparent Fault Tolerance of Device Drivers for Virtual Machines” IEEE TRANSACTIONS ON COMPUTERS, VOL. 59, NO. 11, NOVEMBER 2010 [3] Michael M. Swift, Steven Martin, Henry M. Levy, and Susan J. Eggers “Nooks: An Architecture for Reliable Device Drivers” Proceedings of the Tenth ACM SIGOPS European Workshop, Saint-Emilion, France, Sept. 2002. [4] Michael M. Swift, Muthukaruppan Annamalai, Brian N. Bershad, and Henry M. Levy “Recovering Device Drivers” Proceedings of the 6th ACM/USENIX Symposium on Operating Systems Design and Implementation, San Francisco, CA, Dec. 2004. . [5]http://nooks.cs.washington.edu/ [6]http://kedr.berlios.de/ [7]http://kedr.berlios.de/kedrdoc/ kedr_manual_getting_stared.html Fig. 3 Fig. 3 shows that there are four modules in the kernel, first the KEDR which is for fault simulation, second device drivers, third fault detection module which will continuously monitors device drivers operations using return value and if it success in failure detection then it will trigger forth module recovery module. The recovery module will have mechanism to cope with failures and while doing this work we need to maintain minimum delay and no data loss. 8 Conclusion The operating system is reliable and available only when it can cope with failures and make its services continue without affecting. The device driver failures concealing and recovering mechanism with zero data loss can improve operating system reliability and availability. The KEDR frame work can be used to simulate faults into kernel modules. In this paper we have discussed and showed the KEDR fault simulation 584 All Rights Reserved © 2012 IJARCET