📄 evms_aix.h
字号:
char boot_frag; /* Boot code fragmentation flag. Must*/ /* be 0 if no fragmentation allowed, */ /* else must be 0x01. */ char boot_emulation; /* ROS network emulation flag */ /* 0x0 => not an emul support image */ /* 0x1 => ROS network emulation code */ /* 0x2 => AIX code supporting ROS emul*/ char reserved3[2]; ushort basecn_length; /* Number of sectors for base */ /* customization. Normal mode. */ ushort basecs_length; /* Number of sectors for base */ /* customization. Service mode. */ unsigned int basecn_start; /* Starting PSN value for base */ /* customization. Normal mode. */ unsigned int basecs_start; /* Starting PSN value for base */ /* customization. Service mode. */ char reserved4[24]; unsigned int ser_code_length; /* Service code length in sectors. */ /* A 0 value implies no service code */ /* present. */ unsigned int ser_code_offset; /* Service code offset. Must be 0 if */ /* no service code is present, else */ /* contains byte offset from start of*/ /* service code to first instruction.*/ unsigned int ser_lv_start; /* Contains the PSN of the start of */ /* the SLV. */ unsigned int ser_prg_start; /* Service code start. Must be 0 if */ /* service code is not present, else */ /* contains the PSN of the start of */ /* service code. */ unsigned int ser_lv_length; /* SLV length in sectors. */ unsigned int ser_load_add; /* 512 byte boundary load address for*/ /* service code. */ char ser_frag; /* Service code fragmentation flag. */ /* Must be 0 if no fragmentation */ /* allowed, else must be 0x01. */ char ser_emulation; /* ROS network emulation flag */ /* 0x0 => not an emul support image */ /* 0x1 => ROS network emulation code */ /* 0x2 => AIX code supporting ROS emul*/ char reserved5[2]; unique_id pv_id; /* The unique identifier for this */ /* physical volume. */ char dummy[512 - 128 - sizeof(unique_id)];}AIXIPL_REC, *AIXIPL_REC_PTR;typedef struct AIXlvm_rec_s /* structure which describes the physical volume LVM record */ { long lvm_id; /* LVM id field which identifies whether the PV is a member of a volume group */#define AIX_LVM_LVMID 0x5F4C564D /* LVM id field of ASCII "_LVM" */ unique_id vg_id; /* the id of the volume group to which this physical volume belongs */ long lvmarea_len; /* the length of the LVM reserved area */ long vgda_len; /* length of the volume group descriptor area */ daddr_t vgda_psn [2]; /* the physical sector numbers of the beginning of the volume group descriptor area copies on this disk */ daddr_t reloc_psn; /* the physical sector number of the beginning of a pool of blocks */ /* (located at the end of the PV) which are reserved for the relocation of bad blocks */ long reloc_len; /* the length in number of sectors of the pool of bad block relocation blocks */ short int pv_num; /* the physical volume number within the volume group of this physical volume */ short int pp_size; /* the size in bytes for the partition, expressed as a power of 2 (i.e., the partition size is 2 to the power pp_size) */ long vgsa_len; /* length of the volume group status area */ daddr_t vgsa_psn [2]; /* the physical sector numbers of the beginning of the volume group status area copies on this disk */ short int version; /* the version number of this volume group descriptor and status area */#define LVM_VERSION_1 1 /* first version - AIX 3.0 */#define LVM_STRIPE_ENHANCE 2 /* version with striped lv's - AIX 4.1 */#define LVM_1024_PPSIZE 3 /* ppsizes of 512 and 1024 */#define LVM_GT_1016 4 /* version with support for > 1016 pps/pv */#define LVM_MAX_VERSION LVM_GT_1016 /* max version # */ char res1 [450]; /* reserved area */ } AIXlvm_rec_t;/* II.Volume Group Descriptor Area */typedef struct _vgsa_area{ timestruc_t b_tmstamp; /* Beginning timestamp */ unsigned int pv_missing [(LVM_MAXPVS + (NBPI -1)) / NBPI]; /* Bit per PV */ unsigned char stalepp [LVM_MAXPVS] [VGSA_BT_PV]; short factor; char resv[10]; /* Padding */ timestruc_t e_tmstamp; /* Ending timestamp */} vgsa_area;typedef struct _vg_header{ timestruc_t vg_timestamp; /* time of last update */ unique_id vg_id; /* unique id for volume group */ short numlvs; /* number of lvs in vg */ short maxlvs; /* max number of lvs allowed in vg */ short pp_size; /* size of pps in the vg */ short numpvs; /* number of pvs in the vg */ short total_vgdas; /* number of copies of vg */ /* descriptor area on disk */ short vgda_size; /* size of volume group descriptor */ short bigvg; short quorum; short auto_varyon; int checksum; int bigda_size; } vg_header; typedef struct _lv_entries { short lvname; /* name of LV */ short res1; /* reserved area */ int maxsize; /* maximum number of partitions allowed */ char lv_state; /* state of logical volume */ char mirror; /* none,single, or double */ short mirror_policy; /* type of writing used to write */ int num_lps; /* number of logical partitions on the lv */ /* base 1 */ char permissions; /* read write or read only */ char bb_relocation; /* specifies if bad block */ /* relocation is desired */ char write_verify; /* verify all writes to the LV */ char mirwrt_consist; /* mirror write consistency flag */ unsigned short stripe_exp; /* stripe size in exponent value */ unsigned short striping_width; /* stripe width */ unsigned short lv_avoid; unsigned short child_minor_num; char res4[4]; /* reserved area on disk */ } lv_entries; typedef struct _pv_header { unique_id pv_id; /* unique identifier of PV */ unsigned short pp_count; /* number of physical partitions */ /* on PV */ char pv_state; /* state of physical volume */ char res1; /* reserved area on disk */ daddr_t psn_part1; /* physical sector number of 1st pp */ short pvnum_vgdas;/* number of vg descriptor areas */ /* on the physical volume */ short pv_num; /* PV number */ long res2; /* reserved area on disk */ } pv_header; typedef struct _pp_entries { short lv_index; /* index to lv pp is on */ short res_1; /* reserved area on disk */ long lp_num; /* log. part. number */ char copy; /* the copy of the logical partition */ /* that this pp is allocated for */ char pp_state; /* current state of pp */ char fst_alt_vol; /* pv where partition allocation for*/ /* first mirror begins */ char snd_alt_vol; /* pv where partition allocation for*/ /* second mirror begins */ short fst_alt_part; /* partition to begin first mirror */ short snd_alt_part; /*partition to begin second mirror */ double res_3; /* reserved area on disk */ double res_4; /* reserved area on disk */ } pp_entries;typedef struct _namelist{ char name[LVM_MAXLVS][LVM_NAMESIZ];} namelist; typedef struct _vg_trailer{ timestruc_t timestamp; /* time of last update */ short concurrency; /* MS Nibble = concurrent capable */ /* LS Nibble = concurrent auto-varyon */ short res_2; int res_3; /* reserved area on disk */ double res_4; /* reserved area on disk */ double res_5; /* reserved area on disk */} vg_trailer;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -