1SG_RMSN(8)                         SG3_UTILS                        SG_RMSN(8)
2
3
4

NAME

6       sg_rmsn - send SCSI READ MEDIA SERIAL NUMBER command
7

SYNOPSIS

9       sg_rmsn [--help] [--raw] [--readonly] [--verbose] [--version] DEVICE
10

DESCRIPTION

12       Send  a SCSI READ MEDIA SERIAL NUMBER command to DEVICE and outputs the
13       response.
14
15       This command is described in SPC-3 found at www.t10.org . It was origi‐
16       nally added to SPC-3 in revision 11 (2003/2/12). It is not an mandatory
17       command and the author has not seen any SCSI devices that support it.
18

OPTIONS

20       Arguments to long options are mandatory for short options as well.
21
22       -h, --help
23              output the usage message then exit.
24
25       -r, --raw
26              sends the serial number (if found) to stdout.  This  output  may
27              contain  non-printable  characters  (e.g.  the  serial number is
28              padded with NULLs at the end so its length is a multiple of  4).
29              The  default  action  is  to  print  the  serial  number  out in
30              ASCII-HEX with ASCII characters to the right. All error messages
31              are sent to stderr.
32
33       -R, --readonly
34              opens  the  DEVICE read-only rather than read-write which is the
35              default. The Linux sg driver needs  read-write  access  for  the
36              SCSI  READ  MEDIA SERIAL NUMBER command but other access methods
37              may require read-only access.
38
39       -v, --verbose
40              increase the level of verbosity, (i.e. debug output).
41
42       -V, --version
43              print the version string and then exit.
44

NOTES

46       Device identification information is also found in a  standard  INQUIRY
47       response and its VPD pages (see sg_vpd). The relevant VPD pages are the
48       "device identification page" (VPD page 0x83) and the "unit serial  num‐
49       ber" page (VPD page 0x80).
50
51       The  MMC-4  command set for CD/DVD/HD-DVD/BD drives has a "media serial
52       number" feature (0x109) [and a "logical unit serial  number"  feature].
53       These can be viewed with sg_get_config.
54

EXIT STATUS

56       The  exit  status  of sg_rmsn is 0 when it is successful. Otherwise see
57       the sg3_utils(8) man page.
58

AUTHORS

60       Written by Douglas Gilbert.
61

REPORTING BUGS

63       Report bugs to <dgilbert at interlog dot com>.
64
66       Copyright © 2005-2012 Douglas Gilbert
67       This software is distributed under a FreeBSD license. There is NO  war‐
68       ranty;  not  even  for MERCHANTABILITY or FITNESS FOR A PARTICULAR PUR‐
69       POSE.
70

SEE ALSO

72       sg_vpd(sg3_utils), sg_get_config(sg3_utils)
73
74
75
76sg3_utils-1.31                   November 2012                      SG_RMSN(8)
Impressum