mirror of
https://github.com/amadvance/snapraid.git
synced 2026-12-04 22:00:19 -05:00
Some minor changes.
This commit is contained in:
parent
50078b8155
commit
83f89f4f0e
9 changed files with 53 additions and 27 deletions
2
HISTORY
2
HISTORY
|
|
@ -8,6 +8,8 @@ SnapRAID HISTORY
|
||||||
sync. Note that the sync will terminate with an error.
|
sync. Note that the sync will terminate with an error.
|
||||||
* If the content file is placed in a data disk, it's automatically excluded
|
* If the content file is placed in a data disk, it's automatically excluded
|
||||||
from the sync process.
|
from the sync process.
|
||||||
|
* Increased by one the minimum number of content files. Before it was only
|
||||||
|
a suggestion, but now it's a requirement in case you put them in data disks.
|
||||||
|
|
||||||
1.6 2011/9 - THIS UPDATE IS HIGHLY RECOMMENDED!
|
1.6 2011/9 - THIS UPDATE IS HIGHLY RECOMMENDED!
|
||||||
===============================================
|
===============================================
|
||||||
|
|
|
||||||
4
TODO
4
TODO
|
|
@ -5,8 +5,10 @@ This is the list of TODO items for SnapRAID.
|
||||||
|
|
||||||
- v1.7
|
- v1.7
|
||||||
|
|
||||||
|
* Use st_dev to effectively check if data/parity disks are different and
|
||||||
|
content files are in different disks.
|
||||||
|
|
||||||
* Put the content files in the data disks in the default configuration file.
|
* Put the content files in the data disks in the default configuration file.
|
||||||
But this requires to have at leas N+1 or them.
|
|
||||||
|
|
||||||
* Remove the dependency of the 'disk' order specification in the conf file.
|
* Remove the dependency of the 'disk' order specification in the conf file.
|
||||||
The used order can be defined by SnapRAID and saved in the content file to avoid
|
The used order can be defined by SnapRAID and saved in the content file to avoid
|
||||||
|
|
|
||||||
7
mingw.c
7
mingw.c
|
|
@ -87,7 +87,12 @@ static void windows_info2stat(const BY_HANDLE_FILE_INFORMATION* info, struct win
|
||||||
/* hidden files should be backuped like any other */
|
/* hidden files should be backuped like any other */
|
||||||
if ((info->dwFileAttributes & FILE_ATTRIBUTE_DEVICE) != 0) {
|
if ((info->dwFileAttributes & FILE_ATTRIBUTE_DEVICE) != 0) {
|
||||||
st->st_mode = S_IFBLK;
|
st->st_mode = S_IFBLK;
|
||||||
} else if ((info->dwFileAttributes & (FILE_ATTRIBUTE_SYSTEM | FILE_ATTRIBUTE_TEMPORARY | FILE_ATTRIBUTE_OFFLINE | FILE_ATTRIBUTE_REPARSE_POINT)) != 0) {
|
} else if ((info->dwFileAttributes & (
|
||||||
|
FILE_ATTRIBUTE_SYSTEM /* System files */
|
||||||
|
| FILE_ATTRIBUTE_TEMPORARY /* Files going to be deleted on close */
|
||||||
|
| FILE_ATTRIBUTE_OFFLINE
|
||||||
|
| FILE_ATTRIBUTE_REPARSE_POINT /* Symbolic links */
|
||||||
|
)) != 0) {
|
||||||
st->st_mode = S_IFCHR;
|
st->st_mode = S_IFCHR;
|
||||||
} else if ((info->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0) {
|
} else if ((info->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0) {
|
||||||
st->st_mode = S_IFDIR;
|
st->st_mode = S_IFDIR;
|
||||||
|
|
|
||||||
21
snapraid.1
21
snapraid.1
|
|
@ -121,9 +121,12 @@ files. You should not store other data in them, with the only
|
||||||
possible exception of the \(a"content\(a" files.
|
possible exception of the \(a"content\(a" files.
|
||||||
.PP
|
.PP
|
||||||
The list of files is stored in the \(a"content\(a" files, usually
|
The list of files is stored in the \(a"content\(a" files, usually
|
||||||
stored in the parity disks or in other locations.
|
stored in the data, parity or boot disks.
|
||||||
These files contain the details of you backup with all the
|
These files contain the details of your backup with all the
|
||||||
checksums to verify its integrity.
|
checksums to verify its integrity.
|
||||||
|
The \(a"content\(a" file is stored in multiple copies, each one in a
|
||||||
|
different disks, to ensure that in even in case of a multiple disk
|
||||||
|
failure at least one copy is available.
|
||||||
.PP
|
.PP
|
||||||
For example, suppose that you are interested only at one parity level
|
For example, suppose that you are interested only at one parity level
|
||||||
of protection, and that your disks are present in:
|
of protection, and that your disks are present in:
|
||||||
|
|
@ -159,6 +162,10 @@ content /mnt/diskpar/content
|
||||||
.PD 0
|
.PD 0
|
||||||
.PP
|
.PP
|
||||||
.PD
|
.PD
|
||||||
|
content /var/snapraid/content
|
||||||
|
.PD 0
|
||||||
|
.PP
|
||||||
|
.PD
|
||||||
disk d1 /mnt/disk1/
|
disk d1 /mnt/disk1/
|
||||||
.PD 0
|
.PD 0
|
||||||
.PP
|
.PP
|
||||||
|
|
@ -185,6 +192,10 @@ content E:\(rspar\(rscontent
|
||||||
.PD 0
|
.PD 0
|
||||||
.PP
|
.PP
|
||||||
.PD
|
.PD
|
||||||
|
content C:\(rssnapraid\(rscontent
|
||||||
|
.PD 0
|
||||||
|
.PP
|
||||||
|
.PD
|
||||||
disk d1 F:\(rsarray\(rs
|
disk d1 F:\(rsarray\(rs
|
||||||
.PD 0
|
.PD 0
|
||||||
.PP
|
.PP
|
||||||
|
|
@ -399,10 +410,8 @@ from the \(a"sync\(a" process.
|
||||||
This option is mandatory and it can be used more time to save
|
This option is mandatory and it can be used more time to save
|
||||||
more copies of the same files.
|
more copies of the same files.
|
||||||
.PP
|
.PP
|
||||||
You have to store at least one copy for each parity disk used.
|
You have to store at least one copy for each parity disk used
|
||||||
It\(cqs suggested to use one more to ensure to always have
|
plus one. Using some more don\(cqt hurt.
|
||||||
one copy in case of multiple disks damage, to be able to
|
|
||||||
check the data integrity of the remaining.
|
|
||||||
.SS disk NAME DIR
|
.SS disk NAME DIR
|
||||||
Defines the name and the mount point of the disks of the array.
|
Defines the name and the mount point of the disks of the array.
|
||||||
NAME is used to identify the disk, and it must be unique.
|
NAME is used to identify the disk, and it must be unique.
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,9 @@ parity /mnt/diskpar/parity
|
||||||
|
|
||||||
# Defines the file to use as content list
|
# Defines the file to use as content list
|
||||||
# You can use multiple specification to store more copies of the file
|
# You can use multiple specification to store more copies of the file
|
||||||
# It's suggested to have at least N+1 copies of the file, where N is the number of parity files.
|
# You must have least one copy for each parity file plus one. Some more don't hurt
|
||||||
# It can be in the disks used for data or parity storage
|
# They can be in the disks used for data, parity or boot,
|
||||||
|
# but each file must be in a different disk
|
||||||
# Format: "content FILE_PATH"
|
# Format: "content FILE_PATH"
|
||||||
content /mnt/diskpar/content
|
content /mnt/diskpar/content
|
||||||
#content /mnt/diskqar/content
|
#content /mnt/diskqar/content
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,9 @@ parity E:\par\parity
|
||||||
|
|
||||||
# Defines the file to use as content list
|
# Defines the file to use as content list
|
||||||
# You can use multiple specification to store more copies of the file
|
# You can use multiple specification to store more copies of the file
|
||||||
# It's suggested to have at least N+1 copies of the file, where N is the number of parity files.
|
# You must have least one copy for each parity file plus one. Some more don't hurt
|
||||||
# It can be in the disks used for data or parity storage
|
# They can be in the disks used for data, parity or boot,
|
||||||
|
# but each file must be in a different disk
|
||||||
# Format: "content FILE_PATH"
|
# Format: "content FILE_PATH"
|
||||||
content E:\par\content
|
content E:\par\content
|
||||||
#content F:\qar\content
|
#content F:\qar\content
|
||||||
|
|
|
||||||
15
snapraid.d
15
snapraid.d
|
|
@ -87,9 +87,12 @@ Getting Started
|
||||||
possible exception of the "content" files.
|
possible exception of the "content" files.
|
||||||
|
|
||||||
The list of files is stored in the "content" files, usually
|
The list of files is stored in the "content" files, usually
|
||||||
stored in the parity disks or in other locations.
|
stored in the data, parity or boot disks.
|
||||||
These files contain the details of you backup with all the
|
These files contain the details of your backup with all the
|
||||||
checksums to verify its integrity.
|
checksums to verify its integrity.
|
||||||
|
The "content" file is stored in multiple copies, each one in a
|
||||||
|
different disks, to ensure that in even in case of a multiple disk
|
||||||
|
failure at least one copy is available.
|
||||||
|
|
||||||
For example, suppose that you are interested only at one parity level
|
For example, suppose that you are interested only at one parity level
|
||||||
of protection, and that your disks are present in:
|
of protection, and that your disks are present in:
|
||||||
|
|
@ -104,6 +107,7 @@ Getting Started
|
||||||
|
|
||||||
:parity /mnt/diskpar/parity
|
:parity /mnt/diskpar/parity
|
||||||
:content /mnt/diskpar/content
|
:content /mnt/diskpar/content
|
||||||
|
:content /var/snapraid/content
|
||||||
:disk d1 /mnt/disk1/
|
:disk d1 /mnt/disk1/
|
||||||
:disk d2 /mnt/disk2/
|
:disk d2 /mnt/disk2/
|
||||||
:disk d3 /mnt/disk3/
|
:disk d3 /mnt/disk3/
|
||||||
|
|
@ -113,6 +117,7 @@ Getting Started
|
||||||
|
|
||||||
:parity E:\par\parity
|
:parity E:\par\parity
|
||||||
:content E:\par\content
|
:content E:\par\content
|
||||||
|
:content C:\snapraid\content
|
||||||
:disk d1 F:\array\
|
:disk d1 F:\array\
|
||||||
:disk d2 G:\array\
|
:disk d2 G:\array\
|
||||||
:disk d3 H:\array\
|
:disk d3 H:\array\
|
||||||
|
|
@ -302,10 +307,8 @@ Configuration
|
||||||
This option is mandatory and it can be used more time to save
|
This option is mandatory and it can be used more time to save
|
||||||
more copies of the same files.
|
more copies of the same files.
|
||||||
|
|
||||||
You have to store at least one copy for each parity disk used.
|
You have to store at least one copy for each parity disk used
|
||||||
It's suggested to use one more to ensure to always have
|
plus one. Using some more don't hurt.
|
||||||
one copy in case of multiple disks damage, to be able to
|
|
||||||
check the data integrity of the remaining.
|
|
||||||
|
|
||||||
disk NAME DIR
|
disk NAME DIR
|
||||||
Defines the name and the mount point of the disks of the array.
|
Defines the name and the mount point of the disks of the array.
|
||||||
|
|
|
||||||
15
snapraid.txt
15
snapraid.txt
|
|
@ -100,9 +100,12 @@ files. You should not store other data in them, with the only
|
||||||
possible exception of the "content" files.
|
possible exception of the "content" files.
|
||||||
|
|
||||||
The list of files is stored in the "content" files, usually
|
The list of files is stored in the "content" files, usually
|
||||||
stored in the parity disks or in other locations.
|
stored in the data, parity or boot disks.
|
||||||
These files contain the details of you backup with all the
|
These files contain the details of your backup with all the
|
||||||
checksums to verify its integrity.
|
checksums to verify its integrity.
|
||||||
|
The "content" file is stored in multiple copies, each one in a
|
||||||
|
different disks, to ensure that in even in case of a multiple disk
|
||||||
|
failure at least one copy is available.
|
||||||
|
|
||||||
For example, suppose that you are interested only at one parity level
|
For example, suppose that you are interested only at one parity level
|
||||||
of protection, and that your disks are present in:
|
of protection, and that your disks are present in:
|
||||||
|
|
@ -117,6 +120,7 @@ the following options:
|
||||||
|
|
||||||
parity /mnt/diskpar/parity
|
parity /mnt/diskpar/parity
|
||||||
content /mnt/diskpar/content
|
content /mnt/diskpar/content
|
||||||
|
content /var/snapraid/content
|
||||||
disk d1 /mnt/disk1/
|
disk d1 /mnt/disk1/
|
||||||
disk d2 /mnt/disk2/
|
disk d2 /mnt/disk2/
|
||||||
disk d3 /mnt/disk3/
|
disk d3 /mnt/disk3/
|
||||||
|
|
@ -126,6 +130,7 @@ instead of slashes:
|
||||||
|
|
||||||
parity E:\par\parity
|
parity E:\par\parity
|
||||||
content E:\par\content
|
content E:\par\content
|
||||||
|
content C:\snapraid\content
|
||||||
disk d1 F:\array\
|
disk d1 F:\array\
|
||||||
disk d2 G:\array\
|
disk d2 G:\array\
|
||||||
disk d3 H:\array\
|
disk d3 H:\array\
|
||||||
|
|
@ -338,10 +343,8 @@ from the "sync" process.
|
||||||
This option is mandatory and it can be used more time to save
|
This option is mandatory and it can be used more time to save
|
||||||
more copies of the same files.
|
more copies of the same files.
|
||||||
|
|
||||||
You have to store at least one copy for each parity disk used.
|
You have to store at least one copy for each parity disk used
|
||||||
It's suggested to use one more to ensure to always have
|
plus one. Using some more don't hurt.
|
||||||
one copy in case of multiple disks damage, to be able to
|
|
||||||
check the data integrity of the remaining.
|
|
||||||
|
|
||||||
7.4 disk NAME DIR
|
7.4 disk NAME DIR
|
||||||
-----------------
|
-----------------
|
||||||
|
|
|
||||||
6
state.c
6
state.c
|
|
@ -261,12 +261,12 @@ void state_config(struct snapraid_state* state, const char* path, int verbose, i
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
if (state->qarity[0] != 0) {
|
if (state->qarity[0] != 0) {
|
||||||
content_required = 2;
|
content_required = 3;
|
||||||
} else {
|
} else {
|
||||||
content_required = 1;
|
content_required = 2;
|
||||||
}
|
}
|
||||||
if (content_count < content_required) {
|
if (content_count < content_required) {
|
||||||
fprintf(stderr, "You must have one 'content' file for each parity disk.\n");
|
fprintf(stderr, "You must have at least %d 'content' files. One for each parity disk plus one.\n", content_required);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue