Oracle®Solaris11.1Administration:Oracle SolarisZones,OracleSolaris10Zones,and ResourceManagement PartNo:E29024–04 May2013 Copyright©2004,2013,Oracleand/oritsaffiliates.Allrightsreserved. Thissoftwareandrelateddocumentationareprovidedunderalicenseagreementcontainingrestrictionsonuseanddisclosureandareprotectedbyintellectual propertylaws.Exceptasexpresslypermittedinyourlicenseagreementorallowedbylaw,youmaynotuse,copy,reproduce,translate,broadcast,modify,license, transmit,distribute,exhibit,perform,publish,ordisplayanypart,inanyform,orbyanymeans.Reverseengineering,disassembly,ordecompilationofthissoftware, unlessrequiredbylawforinteroperability,isprohibited. Theinformationcontainedhereinissubjecttochangewithoutnoticeandisnotwarrantedtobeerror-free.Ifyoufindanyerrors,pleasereportthemtousinwriting. IfthisissoftwareorrelateddocumentationthatisdeliveredtotheU.S.GovernmentoranyonelicensingitonbehalfoftheU.S.Government,thefollowingnoticeis applicable: U.S.GOVERNMENTENDUSERS.Oracleprograms,includinganyoperatingsystem,integratedsoftware,anyprogramsinstalledonthehardware,and/or documentation,deliveredtoU.S.Governmentendusersare"commercialcomputersoftware"pursuanttotheapplicableFederalAcquisitionRegulationand agency-specificsupplementalregulations.Assuch,use,duplication,disclosure,modification,andadaptationoftheprograms,includinganyoperatingsystem, integratedsoftware,anyprogramsinstalledonthehardware,and/ordocumentation,shallbesubjecttolicensetermsandlicenserestrictionsapplicabletothe programs.NootherrightsaregrantedtotheU.S.Government. Thissoftwareorhardwareisdevelopedforgeneraluseinavarietyofinformationmanagementapplications.Itisnotdevelopedorintendedforuseinanyinherently dangerousapplications,includingapplicationsthatmaycreateariskofpersonalinjury.Ifyouusethissoftwareorhardwareindangerousapplications,thenyoushall beresponsibletotakeallappropriatefail-safe,backup,redundancy,andothermeasurestoensureitssafeuse.OracleCorporationanditsaffiliatesdisclaimany liabilityforanydamagescausedbyuseofthissoftwareorhardwareindangerousapplications. OracleandJavaareregisteredtrademarksofOracleand/oritsaffiliates.Othernamesmaybetrademarksoftheirrespectiveowners. IntelandIntelXeonaretrademarksorregisteredtrademarksofIntelCorporation.AllSPARCtrademarksareusedunderlicenseandaretrademarksorregistered trademarksofSPARCInternational,Inc.AMD,Opteron,theAMDlogo,andtheAMDOpteronlogoaretrademarksorregisteredtrademarksofAdvancedMicro Devices.UNIXisaregisteredtrademarkofTheOpenGroup. Thissoftwareorhardwareanddocumentationmayprovideaccesstoorinformationoncontent,products,andservicesfromthirdparties.OracleCorporationand itsaffiliatesarenotresponsibleforandexpresslydisclaimallwarrantiesofanykindwithrespecttothird-partycontent,products,andservices.OracleCorporation anditsaffiliateswillnotberesponsibleforanyloss,costs,ordamagesincurredduetoyouraccesstooruseofthird-partycontent,products,orservices. Celogicieletladocumentationquil’accompagnesontprotégésparlesloissurlapropriétéintellectuelle.Ilssontconcédéssouslicenceetsoumisàdesrestrictions d’utilisationetdedivulgation.Saufdispositiondevotrecontratdelicenceoudelaloi,vousnepouvezpascopier,reproduire,traduire,diffuser,modifier,breveter, transmettre,distribuer,exposer,exécuter,publierouafficherlelogiciel,mêmepartiellement,sousquelqueformeetparquelqueprocédéquecesoit.Parailleurs,ilest interditdeprocéderàtouteingénierieinversedulogiciel,deledésassembleroudeledécompiler,exceptéàdesfinsd’interopérabilitéavecdeslogicielstiersoutelque prescritparlaloi. Lesinformationsfourniesdanscedocumentsontsusceptiblesdemodificationsanspréavis.Parailleurs,OracleCorporationnegarantitpasqu’ellessoientexemptes d’erreursetvousinvite,lecaséchéant,àluienfairepartparécrit. Sicelogiciel,ouladocumentationquil’accompagne,estconcédésouslicenceauGouvernementdesEtats-Unis,ouàtouteentitéquidélivrelalicencedecelogiciel oul’utilisepourlecompteduGouvernementdesEtats-Unis,lanoticesuivantes’applique: U.S.GOVERNMENTENDUSERS.Oracleprograms,includinganyoperatingsystem,integratedsoftware,anyprogramsinstalledonthehardware,and/or documentation,deliveredtoU.S.Governmentendusersare"commercialcomputersoftware"pursuanttotheapplicableFederalAcquisitionRegulationand agency-specificsupplementalregulations.Assuch,use,duplication,disclosure,modification,andadaptationoftheprograms,includinganyoperatingsystem, integratedsoftware,anyprogramsinstalledonthehardware,and/ordocumentation,shallbesubjecttolicensetermsandlicenserestrictionsapplicabletothe programs.NootherrightsaregrantedtotheU.S.Government. Celogicieloumatérielaétédéveloppépourunusagegénéraldanslecadred’applicationsdegestiondesinformations.Celogicieloumatérieln’estpasconçunin’est destinéàêtreutilisédansdesapplicationsàrisque,notammentdansdesapplicationspouvantcauserdesdommagescorporels.Sivousutilisezcelogicieloumatériel danslecadred’applicationsdangereuses,ilestdevotreresponsabilitédeprendretouteslesmesuresdesecours,desauvegarde,deredondanceetautresmesures nécessairesàsonutilisationdansdesconditionsoptimalesdesécurité.OracleCorporationetsesaffiliésdéclinenttouteresponsabilitéquantauxdommagescausés parl’utilisationdecelogicieloumatérielpourcetyped’applications. OracleetJavasontdesmarquesdéposéesd’OracleCorporationet/oudesesaffiliés.Toutautrenommentionnépeutcorrespondreàdesmarquesappartenantà d’autrespropriétairesqu’Oracle. InteletIntelXeonsontdesmarquesoudesmarquesdéposéesd’IntelCorporation.TouteslesmarquesSPARCsontutiliséessouslicenceetsontdesmarquesoudes marquesdéposéesdeSPARCInternational,Inc.AMD,Opteron,lelogoAMDetlelogoAMDOpteronsontdesmarquesoudesmarquesdéposéesd’AdvancedMicro Devices.UNIXestunemarquedéposéed’TheOpenGroup. Celogicieloumatérieletladocumentationquil’accompagnepeuventfournirdesinformationsoudesliensdonnantaccèsàdescontenus,desproduitsetdesservices émanantdetiers.OracleCorporationetsesaffiliésdéclinenttouteresponsabilitéougarantieexpressequantauxcontenus,produitsouservicesémanantdetiers.En aucuncas,OracleCorporationetsesaffiliésnesauraientêtretenuspourresponsablesdespertessubies,descoûtsoccasionnésoudesdommagescausésparl’accèsà descontenus,produitsouservicestiers,ouàleurutilisation. 130604@25097 Contents Preface...................................................................................................................................................23 PartI OracleSolarisResourceManagement.............................................................................................27 1 IntroductiontoResourceManagement ..........................................................................................29 ResourceManagementOverview......................................................................................................29 ResourceClassifications..............................................................................................................30 ResourceManagementControlMechanisms ..........................................................................31 ResourceManagementConfiguration ......................................................................................32 InteractionWithNon-GlobalZones .........................................................................................32 WhentoUseResourceManagement................................................................................................32 ServerConsolidation...................................................................................................................33 SupportingaLargeorVariedUserPopulation........................................................................33 SettingUpResourceManagement(TaskMap)...............................................................................34 2 ProjectsandTasks(Overview)...........................................................................................................37 ProjectandTaskFacilities ..................................................................................................................37 ProjectIdentifiers ................................................................................................................................38 DeterminingaUser'sDefaultProject........................................................................................38 SettingUserAttributesWiththeuseraddandusermodCommands....................................39 projectDatabase ........................................................................................................................39 PAMSubsystem............................................................................................................................40 NamingServicesConfiguration.................................................................................................40 Local/etc/projectFileFormat ...............................................................................................40 ProjectConfigurationforNIS ....................................................................................................42 ProjectConfigurationforLDAP................................................................................................42 TaskIdentifiers ....................................................................................................................................43 3 Contents CommandsUsedWithProjectsandTasks......................................................................................44 3 AdministeringProjectsandTasks.....................................................................................................47 AdministeringProjectsandTasks(TaskMap)................................................................................47 ExampleCommandsandCommandOptions ................................................................................48 CommandOptionsUsedWithProjectsandTasks.................................................................48 UsingcronandsuWithProjectsandTasks.............................................................................50 AdministeringProjects.......................................................................................................................50 ▼HowtoDefineaProjectandViewtheCurrentProject...........................................................50 ▼HowtoDeleteaProjectFromthe/etc/projectFile.............................................................53 HowtoValidatetheContentsofthe/etc/projectFile ........................................................54 HowtoObtainProjectMembershipInformation ...................................................................54 ▼HowtoCreateaNewTask ..........................................................................................................54 ▼HowtoMoveaRunningProcessIntoaNewTask ..................................................................55 EditingandValidatingProjectAttributes........................................................................................55 ▼HowtoAddAttributesandAttributeValuestoProjects........................................................55 ▼HowtoRemoveAttributeValuesFromProjects.....................................................................56 ▼HowtoRemoveaResourceControlAttributeFromaProject ..............................................56 ▼HowtoSubstituteAttributesandAttributeValuesforProjects ............................................57 ▼HowtoRemovetheExistingValuesforaResourceControlAttribute.................................57 4 ExtendedAccounting(Overview).....................................................................................................59 IntroductiontoExtendedAccounting..............................................................................................59 HowExtendedAccountingWorks ...................................................................................................60 ExtensibleFormat ........................................................................................................................61 exacctRecordsandFormat .......................................................................................................61 UsingExtendedAccountingonanOracleSolarisSystemwithZonesInstalled..................62 ExtendedAccountingConfiguration................................................................................................62 StartingandPersistentlyEnablingExtendedAccounting..............................................................62 Records .................................................................................................................................................63 CommandsUsedWithExtendedAccounting ................................................................................63 PerlInterfacetolibexacct................................................................................................................63 4 OracleSolaris11.1Administration:OracleSolarisZones,OracleSolaris10Zones,andResourceManagement • May2013 Contents 5 AdministeringExtendedAccounting(Tasks) .................................................................................67 AdministeringtheExtendedAccountingFacility(TaskMap)......................................................67 UsingExtendedAccountingFunctionality......................................................................................68 ▼HowtoActivateExtendedAccountingforFlows,Processes,Tasks,andNetwork Components .................................................................................................................................68 HowtoDisplayExtendedAccountingStatus...........................................................................69 HowtoViewAvailableAccountingResources ........................................................................69 ▼HowtoDeactivateProcess,Task,Flow,andNetworkManagementAccounting ...............70 UsingthePerlInterfacetolibexacct ..............................................................................................71 HowtoRecursivelyPrinttheContentsofanexacctObject..................................................71 HowtoCreateaNewGroupRecordandWriteIttoaFile .....................................................72 HowtoPrinttheContentsofanexacctFile............................................................................73 ExampleOutputFromSun::Solaris::Exacct::Object->dump()....................................73 6 ResourceControls(Overview)...........................................................................................................75 ResourceControlsConcepts..............................................................................................................75 ResourceLimitsandResourceControls ...................................................................................76 InterprocessCommunicationandResourceControls ...........................................................76 ResourceControlConstraintMechanisms ..............................................................................76 ProjectAttributeMechanisms....................................................................................................77 ConfiguringResourceControlsandAttributes...............................................................................77 AvailableResourceControls.......................................................................................................78 Zone-WideResourceControls ..................................................................................................81 UnitsSupport ...............................................................................................................................83 ResourceControlValuesandPrivilegeLevels .........................................................................84 GlobalandLocalActionsonResourceControlValues ..........................................................84 ResourceControlFlagsandProperties.....................................................................................86 ResourceControlEnforcement .................................................................................................88 GlobalMonitoringofResourceControlEvents.......................................................................88 ApplyingResourceControls..............................................................................................................88 TemporarilyUpdatingResourceControlValuesonaRunningSystem......................................89 UpdatingLoggingStatus.............................................................................................................89 UpdatingResourceControls......................................................................................................89 CommandsUsedWithResourceControls......................................................................................90 5 Contents 7 AdministeringResourceControls(Tasks)........................................................................................91 AdministeringResourceControls(TaskMap) ...............................................................................91 SettingResourceControls..................................................................................................................92 ▼HowtoSettheMaximumNumberofLWPsforEachTaskinaProject ...............................92 ▼HowtoSetMultipleControlsonaProject ...............................................................................93 UsingtheprctlCommand ...............................................................................................................94 ▼HowtoUsetheprctlCommandtoDisplayDefaultResourceControlValues .................94 ▼HowtoUsetheprctlCommandtoDisplayInformationforaGivenResourceControl .97 ▼HowtoUseprctltoTemporarilyChangeaValue.................................................................97 ▼HowtoUseprctltoLoweraResourceControlValue ..........................................................97 ▼HowtoUseprctltoDisplay,Replace,andVerifytheValueofaControlonaProject .....98 Usingrctladm .....................................................................................................................................98 HowtoUserctladm ....................................................................................................................98 Usingipcs............................................................................................................................................99 HowtoUseipcs ..........................................................................................................................99 CapacityWarnings............................................................................................................................100 ▼HowtoDetermineWhetheraWebServerIsAllocatedEnoughCPUCapacity ...............100 8 FairShareScheduler(Overview).....................................................................................................101 IntroductiontotheScheduler..........................................................................................................101 CPUShareDefinition .......................................................................................................................102 CPUSharesandProcessState..........................................................................................................103 CPUShareVersusUtilization..........................................................................................................103 CPUShareExamples ........................................................................................................................103 Example1:TwoCPU-BoundProcessesinEachProject ......................................................104 Example2:NoCompetitionBetweenProjects ......................................................................104 Example3:OneProjectUnabletoRun...................................................................................105 FSSConfiguration .............................................................................................................................105 ProjectsandUsers......................................................................................................................105 CPUSharesConfiguration .......................................................................................................106 FSSandProcessorSets......................................................................................................................107 FSSandProcessorSetsExamples.............................................................................................107 CombiningFSSWithOtherSchedulingClasses...........................................................................109 SettingtheSchedulingClassfortheSystem...................................................................................109 SchedulingClassonaSystemwithZonesInstalled ......................................................................110 6 OracleSolaris11.1Administration:OracleSolarisZones,OracleSolaris10Zones,andResourceManagement • May2013 Contents CommandsUsedWithFSS..............................................................................................................110 9 AdministeringtheFairShareScheduler(Tasks) ..........................................................................111 AdministeringtheFairShareScheduler(TaskMap)....................................................................111 MonitoringtheFSS ...........................................................................................................................112 ▼HowtoMonitorSystemCPUUsagebyProjects ...................................................................112 ▼HowtoMonitorCPUUsagebyProjectsinProcessorSets...................................................113 ConfiguringtheFSS ..........................................................................................................................113 ListingtheSchedulerClassesontheSystem...........................................................................113 ▼HowtoMakeFSStheDefaultSchedulerClass.......................................................................113 ▼HowtoManuallyMoveProcessesFromtheTSClassIntotheFSSClass ...........................114 ▼HowtoManuallyMoveProcessesFromAllUserClassesIntotheFSSClass ....................114 ▼HowtoManuallyMoveaProject'sProcessesIntotheFSSClass .........................................115 HowtoTuneSchedulerParameters ........................................................................................115 10 PhysicalMemoryControlUsingtheResourceCappingDaemon(Overview)..........................117 IntroductiontotheResourceCappingDaemon ...........................................................................117 HowResourceCappingWorks .......................................................................................................118 AttributetoLimitPhysicalMemoryUsageforProjects...............................................................118 rcapdConfiguration .........................................................................................................................119 UsingtheResourceCappingDaemononaSystemWithZonesInstalled .........................119 MemoryCapEnforcementThreshold ....................................................................................120 DeterminingCapValues...........................................................................................................120 rcapdOperationIntervals ........................................................................................................122 MonitoringResourceUtilizationWithrcapstat.........................................................................123 CommandsUsedWithrcapd..........................................................................................................124 11 AdministeringtheResourceCappingDaemon(Tasks) ..............................................................125 SettingtheResidentSetSizeCap.....................................................................................................125 ▼HowtoAddanrcap.max-rssAttributeforaProject...........................................................125 ▼HowtoUsetheprojmodCommandtoAddanrcap.max-rssAttributeforaProject .....126 ConfiguringandUsingtheResourceCappingDaemon(TaskMap).........................................126 AdministeringtheResourceCappingDaemonWithrcapadm ...................................................127 ▼HowtoSettheMemoryCapEnforcementThreshold ..........................................................127 7 Contents ▼HowtoSetOperationIntervals................................................................................................127 ▼HowtoEnableResourceCapping ...........................................................................................128 ▼HowtoDisableResourceCapping ..........................................................................................128 ▼HowtoSpecifyaTemporaryResourceCapforaZone.........................................................129 ProducingReportsWithrcapstat.................................................................................................129 ReportingCapandProjectInformation .................................................................................129 MonitoringtheRSSofaProject ...............................................................................................130 DeterminingtheWorkingSetSizeofaProject......................................................................131 ReportingMemoryUtilizationandtheMemoryCapEnforcementThreshold ................132 12 ResourcePools(Overview)...............................................................................................................133 IntroductiontoResourcePools .......................................................................................................134 IntroductiontoDynamicResourcePools ......................................................................................135 AboutEnablingandDisablingResourcePoolsandDynamicResourcePools..........................135 ResourcePoolsUsedinZones .........................................................................................................135 WhentoUsePools ............................................................................................................................136 ResourcePoolsFramework..............................................................................................................137 /etc/pooladm.confContents .................................................................................................138 PoolsProperties..........................................................................................................................138 ImplementingPoolsonaSystem.....................................................................................................139 project.poolAttribute ...................................................................................................................139 SPARC:DynamicReconfigurationOperationsandResourcePools..........................................139 CreatingPoolsConfigurations ........................................................................................................140 DirectlyManipulatingtheDynamicConfiguration .....................................................................141 pooldOverview .................................................................................................................................141 ManagingDynamicResourcePools ...............................................................................................141 ConfigurationConstraintsandObjectives ....................................................................................142 ConfigurationConstraints........................................................................................................142 ConfigurationObjectives..........................................................................................................143 pooldProperties.........................................................................................................................145 pooldFunctionalityThatCanBeConfigured ...............................................................................146 pooldMonitoringInterval........................................................................................................146 pooldLoggingInformation......................................................................................................147 LoggingLocation .......................................................................................................................149 LogManagementWithlogadm................................................................................................149 8 OracleSolaris11.1Administration:OracleSolarisZones,OracleSolaris10Zones,andResourceManagement • May2013 Contents HowDynamicResourceAllocationWorks ...................................................................................149 AboutAvailableResources........................................................................................................149 DeterminingAvailableResources............................................................................................149 IdentifyingaResourceShortage...............................................................................................150 DeterminingResourceUtilization...........................................................................................151 IdentifyingControlViolations.................................................................................................151 DeterminingAppropriateRemedialAction...........................................................................151 UsingpoolstattoMonitorthePoolsFacilityandResourceUtilization...................................152 poolstatOutput .......................................................................................................................152 TuningpoolstatOperationIntervals ....................................................................................153 CommandsUsedWiththeResourcePoolsFacility......................................................................153 13 CreatingandAdministeringResourcePools(Tasks)...................................................................155 AdministeringResourcePools(TaskMap) ...................................................................................155 EnablingandDisablingthePoolsFacility ......................................................................................157 ▼HowtoEnabletheResourcePoolsServiceUsingsvcadm.....................................................157 ▼HowtoDisabletheResourcePoolsServiceUsingsvcadm....................................................157 ▼HowtoEnabletheDynamicResourcePoolsServiceUsingsvcadm....................................157 ▼HowtoDisabletheDynamicResourcePoolsServiceUsingsvcadm...................................160 ▼HowtoEnableResourcePoolsUsingpooladm ......................................................................160 ▼HowtoDisableResourcePoolsUsingpooladm .....................................................................160 ConfiguringPools..............................................................................................................................160 ▼HowtoCreateaStaticConfiguration......................................................................................160 ▼HowtoModifyaConfiguration...............................................................................................162 ▼HowtoAssociateaPoolWithaSchedulingClass .................................................................164 ▼HowtoSetConfigurationConstraints....................................................................................166 ▼HowtoDefineConfigurationObjectives................................................................................166 ▼HowtoSetthepooldLoggingLevel ........................................................................................168 ▼HowtoUseCommandFilesWithpoolcfg ...........................................................................168 TransferringResources.....................................................................................................................169 ▼HowtoMoveCPUsBetweenProcessorSets..........................................................................169 ActivatingandRemovingPoolConfigurations.............................................................................170 ▼HowtoActivateaPoolsConfiguration...................................................................................170 ▼HowtoValidateaConfigurationBeforeCommittingtheConfiguration..........................170 ▼HowtoRemoveaPoolsConfiguration ...................................................................................170 9 Contents SettingPoolAttributesandBindingtoaPool................................................................................171 ▼HowtoBindProcessestoaPool...............................................................................................171 ▼HowtoBindTasksorProjectstoaPool..................................................................................172 ▼HowtoSettheproject.poolAttributeforaProject............................................................172 ▼HowtoUseprojectAttributestoBindaProcesstoaDifferentPool.................................172 UsingpoolstattoReportStatisticsforPool-RelatedResources................................................173 DisplayingDefaultpoolstatOutput......................................................................................173 ProducingMultipleReportsatSpecificIntervals...................................................................173 ReportingResourceSetStatistics .............................................................................................174 14 ResourceManagementConfigurationExample..........................................................................175 ConfigurationtoBeConsolidated ..................................................................................................175 ConsolidationConfiguration ..........................................................................................................176 CreatingtheConfiguration..............................................................................................................176 ViewingtheConfiguration...............................................................................................................177 PartII OracleSolarisZones..........................................................................................................................183 15 IntroductiontoOracleSolarisZones .............................................................................................185 ZonesOverview.................................................................................................................................186 AboutOracleSolarisZonesinThisRelease ...................................................................................187 Read-OnlysolarisNon-GlobalZones .........................................................................................189 AboutConvertingipkgZonestosolarisZones .........................................................................189 AboutBrandedZones .......................................................................................................................190 ProcessesRunninginaBrandedZone ....................................................................................190 Non-GlobalZonesAvailableinThisRelease..........................................................................191 WhentoUseZones ...........................................................................................................................191 HowZonesWork ..............................................................................................................................193 SummaryofZonesbyFunction ...............................................................................................194 HowNon-GlobalZonesAreAdministered............................................................................195 HowNon-GlobalZonesAreCreated ......................................................................................195 Non-GlobalZoneStateModel..................................................................................................196 Non-GlobalZoneCharacteristics............................................................................................199 UsingResourceManagementFeaturesWithNon-GlobalZones........................................199 10 OracleSolaris11.1Administration:OracleSolarisZones,OracleSolaris10Zones,andResourceManagement • May2013
Description: