mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-19 22:46:36 -05:00
Configuration is now required also for smart and probe commands
Some checks failed
Some checks failed
This commit is contained in:
parent
b8b1d38781
commit
189029749e
3 changed files with 0 additions and 17 deletions
|
|
@ -1763,14 +1763,6 @@ int snapraid_main(int argc, char* argv[])
|
|||
break;
|
||||
}
|
||||
|
||||
switch (operation) {
|
||||
case OPERATION_SMART :
|
||||
case OPERATION_PROBE :
|
||||
/* allow to run without configuration file */
|
||||
opt.auto_conf = 1;
|
||||
break;
|
||||
}
|
||||
|
||||
/* open the log file */
|
||||
log_open(log_file);
|
||||
|
||||
|
|
|
|||
|
|
@ -588,14 +588,6 @@ void state_config(struct snapraid_state* state, const char* path, const char* co
|
|||
if (!f) {
|
||||
/* LCOV_EXCL_START */
|
||||
if (errno == ENOENT) {
|
||||
if (state->opt.auto_conf) {
|
||||
log_tag("conf:missing:\n");
|
||||
/* mark that we are without a configuration file */
|
||||
state->no_conf = 1;
|
||||
state->level = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
log_fatal(errno, "No configuration file found at '%s'\n", path);
|
||||
} else if (errno == EACCES) {
|
||||
log_fatal(errno, "You do not have rights to access the configuration file '%s'\n", path);
|
||||
|
|
|
|||
|
|
@ -117,7 +117,6 @@ struct snapraid_option {
|
|||
int match_first_uuid; /**< Force the matching of the first UUID. */
|
||||
int force_parity_update; /**< Force parity update even if data is not changed. */
|
||||
unsigned io_cache; /**< Number of IO buffers to use. 0 for default. */
|
||||
int auto_conf; /**< Allow to run without configuration file. */
|
||||
int force_stats; /**< Force stats print during process. */
|
||||
uint64_t parity_limit_size; /**< Test limit for parity files. */
|
||||
int skip_multi_scan; /**< Don't use threads in scan. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue