1lsm_local_disk_serial_num_gLeitb(s3t)oragemgmt C APIlMsamn_ulaolcal_disk_serial_num_get(3)
2
3
4

NAME

6       lsm_local_disk_serial_num_get - Query serial number.
7

SYNOPSIS

9       int   lsm_local_disk_serial_num_get   (const   char   *disk_path,  char
10       **serial_num, lsm_error **lsm_err);
11

ARGUMENTS

13       disk_path   String. The path of disk path, example "/dev/sdb".
14
15       serial_num  Output pointer of SCSI  VPD80  serial  number.   NULL  when
16                   error. Memory should be freed by free.
17
18       lsm_err     Output   pointer  of  lsm_error.  Error  message  could  be
19                   retrieved via lsm_error_message_get. Memory should be freed
20                   by lsm_error_free.
21

VERSION

23       1.4
24

DESCRIPTION

26       Query  the serial number of specified disk path.  For SCSI/SAS/SATA/ATA
27       disks, it will be extracted from SCSI VPD 0x80 page.
28

RETURN

30       Error code as enumerated by 'lsm_error_number':
31           * LSM_ERR_OK
32               On success or not found.
33           * LSM_ERR_INVALID_ARGUMENT
34               When any argument is NULL
35           * LSM_ERR_NO_MEMORY
36               When no memory.
37           * LSM_ERR_LIB_BUG
38               When something unexpected happens.
39           * LSM_ERR_NOT_FOUND_DISK
40               When provided disk path not found.
41
42
43
44May 2018                 lsm_local_disk_serial_lnsumm__lgoectal_disk_serial_num_get(3)
Impressum