Click here to load reader

Lpi 101 study_guide

  • View
    662

  • Download
    3

Embed Size (px)

Text of Lpi 101 study_guide

  • 1. LPILevel1 Test101CertificationStudyGuideByVictorMendonaDetailedObjectives:http://www.lpi.org/eng/certification/the_lpic_program/lpic_1/exam_101_detailed_objectivesOctober22nd2007(UpdatedonJanuary2010)1

2. LicenseThisdocumentcomeswithnowarranty.ThesearemynotesfortheLPI101examandshouldnotbeusedastheonlymeanforpreparationforthistest.Thedocumentisopenfordistributionandchanges,aslongasitmentionsmynameastheinitialauthor.BibliographyOReillyLPILinuxCertificationinaNutshell,2ndEditionhttp://oreilly.com/catalog/9780596005283/index.htmlIBMLinuxProfessionalInstitute(LPI)examprepwww.ibm.com/developerworks/linux/lpi/StudyMaterialMCMCSEForumhttp://www.mcmcse.com/linux/lpic1.shtmlPracticeExamhttp://www.linuxpraxis.de/lpisim/lpi.htmlIRCirc.freenode.net#lpiErrataImwillingtomakemajorcorrections,howev[email protected]yahoo.cawiththefollowinginfo:Subject:LPI101correctionInclude:ContenttobecorrectedPageSourcethatprovesyouarerightThanks!!;)AuthorVictorMendonahttp://wazem.org 2 3. IndexTopic1.101HardwareandArchitectureObjective1ConfigureFundamentalBIOSSettings...........................................................................................Page4Objective3ConfigureModemsandSoundCards..............................................................................................Page6Objective4SetUpNonIDEDevices.................................................................................................................Page6Objective5SetUpDifferentPCExpansionCards.............................................................................................Page8Objective6ConfigureCommunicationsDevices...............................................................................................Page9Objective7ConfigureUSBDevices...................................................................................................................Page9Topic1.102LinuxInstallationandPackageManagementObjective1DesignaHardDiskLayout..............................................................................................................Page11Objective2InstallaBootManager.....................................................................................................................Page12Objective3MakeandInstallProgramsfromSource.........................................................................................Page16Objective4ManageSharedLibraries.................................................................................................................Page17Objective5UseDebianPackageManager..........................................................................................................Page19Objective6UseRedHatPackageManager........................................................................................................Page22Topic1.103GNUandUNIXCommandsObjective1WorkontheCommandLine............................................................................................................Page25Objective2ProcessTextStreamsUsingFilters.................................................................................................Page31Objective3PerformBasicFileManagement.......................................................................................................Page43Objective4UseUnixStreams,PipesandRedirects............................................................................................Page48Objective5Create,MonitorandKillProcesses..................................................................................................Page50Objective6ModifyProcessExecutionPriority..................................................................................................Page57Objective7SearchTextFilesUsingRegularExpressions..................................................................................Page58Objective8PerformBasicFileEditingOperationsUsingvi..............................................................................Page63Topic1.104Devices,LinuxFilesystems,andtheFilesystemHierarchyObjective1CreatePartitionsandFilesystems....................................................................................................Page66Objective2MaintaintheIntegrityofFilesystems..............................................................................................Page70Objective3ControlFilesystemMountingandUnmounting..............................................................................Page74Objective4ManagingDiskQuotas....................................................................................................................Page78Objective5UseFilePermissionstoControlAccesstoFiles.............................................................................Page84Objective6ManageFileOwnership...................................................................................................................Page87Objective7CreateandChangeHardandSymbolicLinks.................................................................................Page89Objective8FindSystemFilesandPlaceFilesintheCorrectLocation.............................................................Page91 3 4. Topic1.101HardwareandArchitectureObjective1:ConfigureFundamentalBIOSSettingsBIOSUsuallyincludessysteminitialization,testingmemory(andother)andlocatingOS.DateandtimeConfiguredintheBIOSandpassedontotheOS.ItcanalsobeconfiguredontheOS(eg:NTPserverordaemon)DisksandbootdevicesBootingchoices,NICbooting,configuringdevices,etc...BusesPCIPeripheralComponentInterconnect(8and16bitdevices)ISAIndustryStandardArchitecture(32bitdevices)Thefiles/proc/pcicontainsinformationsoncurrentsystemPCIdevices.Thisfileis(has)becomingobsoleteandbeingreplacedbythecommandlspci(/sbin/lspcionRedHat,/usr/bin/lspcionDebian)ResourceAssignmentsResourceassignmentscanbeidentifiedviabootmessages(dmesg),thespecific/proc/subsystemorotherutilitiesDMA(DirectMemoryAccess)ProvideshardwaredirectaccesstothememorybypassingCPUMostdevicesonlyrequestaDMAchannelwhenIOisactuallyhappeningSee/proc/dmaforcurrentsystemDMAassignments(usuallyempty,seepreviousstatement)I/ODevicesaddressesonCPUsmemorymapThefile/proc/ioportscontaininformationoncurrentsystemI/OassignmentsIRQ(InterruptRequests)InterruptprioritytotheCPU I/O,IRQandDMASee/proc/interruptsforcurrentsystemIRQassignmentsDeviceI/O IRQ DMATodaysdevicesshareIRQs ttyS0(COM1)3f84N/A ttyS1(COM2)2f83N/A ttyS2(COM3)3e84N/ANote:memorizeparallelandserialIRQs ttyS3(COM4)2e83N/A lp0(LPT1)37837f7N/A lp1(LPT2)27827f5N/A fd0,fd1 3f03f76 24 5. PlugAndPlayWasdevelopedtoallowaadevicetotellthesystemitsresourcerequirementsandallowtheBIOStotellthedevicewhichresourcestousePriortokernel2.4apackagecalledisapnptoolsalloweduserstoconfigurePnP.ThecommandpnpdumpscansPnPdevicesduringbootanddumpsalistofresourcesthatdevicesneedorwouldliketouseinaconfigurationfile(usually/etc/isapnp.conf).Userwouldeditthefileanduncommentthecommandsthehewouldliketouse.isapnpwouldreadtheconffileandconfigurethesystemAtoolcalledlspnpcanalsobeusedtodisplayinformationonPnPdevices(whichisthesameas/proc/bus/pnp)IDEHardDrivesIntegratedDriveElectronicsarethemostcommonnowadaysUsuallycomeintwoformats:.ATAttachmentATA.SerialATAttachmentSATADiskcapacitiesaremeasuredinpowersof10(not1024)SizeLimitationOriginalCHS(Cylinder,Head,Sector)designonlyallowsupto137GBLogicalBlockAddress(LBA)wasdesignedtoovercomethesizelimitsfromCHS.ThesystemignoresthegeometryandleavesittothedrivetofigureoutbyreferringtoaLBAinsteadofareallocationAnolderdevicethatdoesnothaveLBAsupportmightneedthebootfromwithinthethefirst1024cylinders1024CylinderLimitBootloaderonLinuxcanbeplacedeitheronMBRorontherootpartition.SomeBIOScannotreadoverthe1024thcylinder,whichcancauseaproblem.OlderversionofLILOrequirestheKerneltobewithinthefirst1024cylindersaswellLinuxDiskNamesThe/dev/filesystemisapseudofilesystem(justlike/proc/)Namingisdoneasthedevicesarefound:.Controller1MasterHD/dev/hda.Controller1SlaveHD/dev/hdb.Controller2MasterHD/dev/hdc.Controller2SlaveHD/dev/hddAdrivecanhaveupto4primarypartitionsandupto512logical(howevertheOSmightlimititto63)NowadaysUSBandSATAdevicesappearassdratherthanhd(alsotrueforharddrives)LegacyPeripheralsManysystemsdonotuseinterruptsforprinters,sotheIRQmayormaynotbeusedParallelportscanusualybeconfiguredwithdifferentsignalingmodes(bidirections,EPP,ECP):.EnhancedCapabilitiesPort(ECP)Designedtousewithprinters.EnhancedParallelPort(EPP)Devicesthatrequirealargeamountofdatatofloweitherway(CDROM,tape) 5 6. Objective3:ConfigureModemsandSoundCardsModemsAlsohavedigitalcompressionanderrorcorrectioncapabilitiesModemTypesModemsdiscussedintheexamareasynchronousmodems,wheredataistransmittedinindividualbytes(synchronousmodemstransmitdatainblocksofdata,liketheIPprotocol)Winmodemsarenocompatible(unlessaLinuxSpecificdriverisavailable)LinmodemsaresoftwareassistedmodemsthatworkunderLinux(linmodems.org)ModernHardwareResourcesExternalmodemsusuallyconnecttoportRS232(ttyS0andS1)PCImodemsusuallyshowasttyS2Theprogramsetserialcanbeusedtoviewmodemparametersthatwillbeusedwiththeserialdriver(itdoesnotprobethehardware,itonlytellstheserialdriverwhatparameterstouse)Somemodemsalsorequireflowcontrol,whichsendssignalfromeachendadvisingofthedevicetransmissionstate(CTSCleartosendandRTSReadytosend)BecarefulwhenconfiguringamodemmanuallyduetoIRQandI/OconflictsSoundDevicesDevicescancomewithdifferenttypesofconnectioninterface(evenUSB)I/Oportscanvarybetween0220022f,240,260or280IRQsvaryfrom2,5,7,10(5isusuallythedefault)SupportandConfigurationKernels2.4and2.6havesupportforavarietyofdriversbuiltinasmodulesOn2.4moduleconfigurationisstoredunder/etc/modules.conf,while2.6keepsitunder/etc/modprobe.confDrivers:.2.4andolderkernelsOpenSoundSystem(OSS).2.6AdvancedLinuxSoundArchitecture(ALSA)ForkernelswithOSSsupportatoolcalledsndconfigwasused.Theutilityprobesthesoundcard,playsasoundandupdates/etc/modules.confObjective4:SetUpNonIDEDevicesOverviewComparisonbetweenSCSIandIDE.Moreexpensive(23xmore),moreexpandability,flexibilityandthroughputSCSITypesSCSI1Origin