Skip to content
Snippets Groups Projects
Commit 3f02f05c authored by chrfranke's avatar chrfranke
Browse files

smartctl: Add option '-x, --xall' to print all info.

git-svn-id: https://smartmontools.svn.sourceforge.net/svnroot/smartmontools/trunk@2820 4ea69e1a-61f1-4043-bf83-b5c94c648137
parent 5ce5706c
No related branches found
No related tags found
No related merge requests found
CHANGELOG for smartmontools CHANGELOG for smartmontools
$Id: CHANGELOG,v 1.816 2009/07/05 17:16:38 chrfranke Exp $ $Id: CHANGELOG,v 1.817 2009/07/05 17:52:46 chrfranke Exp $
The most recent version of this file is: The most recent version of this file is:
http://smartmontools.cvs.sourceforge.net/smartmontools/sm5/CHANGELOG?view=markup http://smartmontools.cvs.sourceforge.net/smartmontools/sm5/CHANGELOG?view=markup
...@@ -41,6 +41,9 @@ NOTES FOR FUTURE RELEASES: see TODO file. ...@@ -41,6 +41,9 @@ NOTES FOR FUTURE RELEASES: see TODO file.
<DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE> <DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE>
[CF] smartctl: Add option '-x, --xall' to print all info including
extended SMART logs and non-SMART info.
[CF] smartctl: Add '-l xerror,error' and '-l xselftest,selftest' to print [CF] smartctl: Add '-l xerror,error' and '-l xselftest,selftest' to print
the old logs if the extended logs are not supported. the old logs if the extended logs are not supported.
......
.ig .ig
Copyright (C) 2002-9 Bruce Allen <smartmontools-support@lists.sourceforge.net> Copyright (C) 2002-9 Bruce Allen <smartmontools-support@lists.sourceforge.net>
$Id: smartctl.8.in,v 1.132 2009/07/05 17:16:38 chrfranke Exp $ $Id: smartctl.8.in,v 1.133 2009/07/05 17:52:46 chrfranke Exp $
This program is free software; you can redistribute it and/or modify it This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free under the terms of the GNU General Public License as published by the Free
...@@ -181,8 +181,20 @@ and for SCSI, this is equivalent to ...@@ -181,8 +181,20 @@ and for SCSI, this is equivalent to
.nf .nf
\'\-H \-i \-A \-l error \-l selftest\'. \'\-H \-i \-A \-l error \-l selftest\'.
.fi .fi
Note that for ATA disks this does \fBnot\fP enable the \'\-l Note that for ATA disks this does \fBnot\fP enable the non-SMART options
directory\' option. and the SMART options which require support for 48-bit ATA commands.
.TP
.B \-x, \-\-xall
Prints all SMART and non-SMART information about the device. For ATA
devices this is equivalent to
.nf
\'\-H \-i \-c \-A \-l xerror,error \-l xselftest,selftest \-l selective
\-l directory \-l scttemp \-l sataphy\'.
.fi
and for SCSI, this is equivalent to
.nf
\'\-H \-i \-A \-l error \-l selftest \-l background \-l sasphy\'.
.fi
.TP .TP
.B RUN\-TIME BEHAVIOR OPTIONS: .B RUN\-TIME BEHAVIOR OPTIONS:
...@@ -1753,7 +1765,7 @@ these documents may be found in the References section of the ...@@ -1753,7 +1765,7 @@ these documents may be found in the References section of the
.SH .SH
CVS ID OF THIS PAGE: CVS ID OF THIS PAGE:
$Id: smartctl.8.in,v 1.132 2009/07/05 17:16:38 chrfranke Exp $ $Id: smartctl.8.in,v 1.133 2009/07/05 17:52:46 chrfranke Exp $
.\" Local Variables: .\" Local Variables:
.\" mode: nroff .\" mode: nroff
.\" End: .\" End:
...@@ -63,7 +63,7 @@ extern const char *os_solaris_ata_s_cvsid; ...@@ -63,7 +63,7 @@ extern const char *os_solaris_ata_s_cvsid;
extern const char *cciss_c_cvsid; extern const char *cciss_c_cvsid;
#endif #endif
extern const char *atacmdnames_c_cvsid, *atacmds_c_cvsid, *ataprint_c_cvsid, *knowndrives_c_cvsid, *os_XXXX_c_cvsid, *scsicmds_c_cvsid, *scsiprint_c_cvsid, *utility_c_cvsid; extern const char *atacmdnames_c_cvsid, *atacmds_c_cvsid, *ataprint_c_cvsid, *knowndrives_c_cvsid, *os_XXXX_c_cvsid, *scsicmds_c_cvsid, *scsiprint_c_cvsid, *utility_c_cvsid;
const char* smartctl_c_cvsid="$Id: smartctl.cpp,v 1.201 2009/07/05 17:16:44 chrfranke Exp $" const char* smartctl_c_cvsid="$Id: smartctl.cpp,v 1.202 2009/07/05 17:52:46 chrfranke Exp $"
ATACMDS_H_CVSID ATAPRINT_H_CVSID CONFIG_H_CVSID EXTERN_H_CVSID INT64_H_CVSID KNOWNDRIVES_H_CVSID SCSICMDS_H_CVSID SCSIPRINT_H_CVSID SMARTCTL_H_CVSID UTILITY_H_CVSID; ATACMDS_H_CVSID ATAPRINT_H_CVSID CONFIG_H_CVSID EXTERN_H_CVSID INT64_H_CVSID KNOWNDRIVES_H_CVSID SCSICMDS_H_CVSID SCSIPRINT_H_CVSID SMARTCTL_H_CVSID UTILITY_H_CVSID;
// This is a block containing all the "control variables". We declare // This is a block containing all the "control variables". We declare
...@@ -132,6 +132,8 @@ void Usage (void){ ...@@ -132,6 +132,8 @@ void Usage (void){
" Show identity information for device\n\n" " Show identity information for device\n\n"
" -a, --all \n" " -a, --all \n"
" Show all SMART information for device\n\n" " Show all SMART information for device\n\n"
" -x, --xall\n"
" Show all information for device\n\n"
); );
printf( printf(
"================================== SMARTCTL RUN-TIME BEHAVIOR OPTIONS =====\n\n" "================================== SMARTCTL RUN-TIME BEHAVIOR OPTIONS =====\n\n"
...@@ -273,7 +275,7 @@ const char * parse_options(int argc, char** argv, ...@@ -273,7 +275,7 @@ const char * parse_options(int argc, char** argv,
scsi_print_options & scsiopts) scsi_print_options & scsiopts)
{ {
// Please update getvalidarglist() if you edit shortopts // Please update getvalidarglist() if you edit shortopts
const char *shortopts = "h?Vq:d:T:b:r:s:o:S:HcAl:iav:P:t:CXF:n:B:"; const char *shortopts = "h?Vq:d:T:b:r:s:o:S:HcAl:iaxv:P:t:CXF:n:B:";
// Please update getvalidarglist() if you edit longopts // Please update getvalidarglist() if you edit longopts
struct option longopts[] = { struct option longopts[] = {
{ "help", no_argument, 0, 'h' }, { "help", no_argument, 0, 'h' },
...@@ -295,6 +297,7 @@ const char * parse_options(int argc, char** argv, ...@@ -295,6 +297,7 @@ const char * parse_options(int argc, char** argv,
{ "log", required_argument, 0, 'l' }, { "log", required_argument, 0, 'l' },
{ "info", no_argument, 0, 'i' }, { "info", no_argument, 0, 'i' },
{ "all", no_argument, 0, 'a' }, { "all", no_argument, 0, 'a' },
{ "xall", no_argument, 0, 'x' },
{ "vendorattribute", required_argument, 0, 'v' }, { "vendorattribute", required_argument, 0, 'v' },
{ "presets", required_argument, 0, 'P' }, { "presets", required_argument, 0, 'P' },
{ "test", required_argument, 0, 't' }, { "test", required_argument, 0, 't' },
...@@ -559,6 +562,22 @@ const char * parse_options(int argc, char** argv, ...@@ -559,6 +562,22 @@ const char * parse_options(int argc, char** argv,
ataopts.smart_selective_selftest_log = true; ataopts.smart_selective_selftest_log = true;
/* scsiopts.smart_background_log = true; */ /* scsiopts.smart_background_log = true; */
break; break;
case 'x':
ataopts.drive_info = scsiopts.drive_info = true;
ataopts.smart_check_status = scsiopts.smart_check_status = true;
ataopts.smart_general_values = true;
ataopts.smart_vendor_attrib = scsiopts.smart_vendor_attrib = true;
ataopts.smart_ext_error_log = scsiopts.smart_error_log = true;
ataopts.retry_error_log = true;
ataopts.smart_ext_selftest_log = scsiopts.smart_selftest_log = true;
ataopts.retry_selftest_log = true;
ataopts.smart_selective_selftest_log = true;
ataopts.smart_logdir = ataopts.gp_logdir = true;
ataopts.sct_temp_sts = ataopts.sct_temp_hist = true;
ataopts.sataphy = true;
scsiopts.smart_background_log = true;
scsiopts.sasphy = true;
break;
case 'v': case 'v':
// parse vendor-specific definitions of attributes // parse vendor-specific definitions of attributes
if (!strcmp(optarg,"help")) { if (!strcmp(optarg,"help")) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment