Font Size: a A A

Study And Implementation Of Fault Injection For LINUX Drivers Testing

Posted on:2018-08-12Degree:MasterType:Thesis
Country:ChinaCandidate:Syeda Huma JabeenFull Text:PDF
GTID:2348330512482130Subject:COMPUTER TECHNOLOGY
Abstract/Summary:PDF Full Text Request
Linux kernel based Operating systems(OS)are widely used in the world.About more than 90%of the most powerful supercomputer are based on that.There is an increasing opportunity to use Linux in enterprise systems,where the users expect very high reliability.To achieve the need of the time it is important to test how Linux kernel module behaves in a fault situation.To test that various scientist has tried to inject fault by creating an artificial environment by different techniques.Fault injection is an important application area for Linux kernel module.The main purpose is to see the behavior of kernel component under abnormal situations.In this thesis,we have analyzed various fault injection frameworks over Linux kernel.Frameworks used in these experiments were LTP,KEDR,LFI and SCSI for injecting various fault types on Linux kernel module and to justify the Linux kernel behavior under the faulty kernel.Most of the framework used in these experiments were concatenating with kernel fault injection framework(LFI)as provided by Linux version 2.6.20.Each framework has its own specialty with respect to fault type and behavior while injecting a fault on Linux kernel.For LTP(Linux Testing Project)we performed three tests under the faulty kernel,probability percentage and numbers of loops varied each time.Firstly,I test the mm(memory management)it runs successfully under the faulty kernel without any error message or failure.But in the case of dma-threat-dio under the faulty kernel which got failed.Out of 49,only 7 tests get passed and 42 were failed(85.7%failure occur).In third test mmap stress(memory mappings stress)under the faulty kernel also get failed.Memory mapping stress 04 failed completely but memory mapping stress 02 give a warning message.KEDR tool was used to study fault simulation and detection of memory leaks over built in the module(Kedr-sample-target)and custom kernel module(Example LKM).Results of fault simulation were same for both modules "cannot allocate memory" and for device drivers(cfakeOlcafakel)Fault simulation result was same for both modules"bad address".Detection memory leaks result varied for each module,for kedr sample target "allocation 3 and possible leak 2" but for custom kernel module Example LKM"allocation 2 possible leak 0".These results were further verified under the debugfs directory(sys/kernel/debug/kedr-fault-simulation/cat last fault).SCSI tool was used to inject fault under the RAID1,the mdadm approach was used to create RAID1.It consists of sdc and sdb hard disk.The type of fault chooses to inject was "read correctable error".Once the fault has been injected successfully over the dev/md127 device it shows " SCSI-decide-decomposition major=8 minor =16 scmd=4122759912" in the middle of SCSI script after reading it from syslog.Once a fault is injected,the sdb will be recovered because the fault-injected sdb was corrected and md127 also get recovered automatically due to its association with sdb.
Keywords/Search Tags:Custom kernel modules, Device Drivers, Fault simulation, KEDR, Linux, LTP, LFI, Memory leak, SCSI Fault Injector
PDF Full Text Request
Related items