Lukas Ertl
a0781b98f3
Save the config back to disk when a drive goes down.
2004-09-13 17:33:52 +00:00
Lukas Ertl
ea29a30466
Read a whole sector instead of GV_HDR_LEN, since a sector might be
...
bigger (i.e. on CD-ROMs).
2004-09-13 17:27:58 +00:00
Pawel Jakub Dawidek
7e8ca741ca
Make kern.geom.debugflags sysctl tunable from /boot/loader.conf.
...
It will help to debug problems when booting.
Approved by: phk
2004-09-13 14:58:27 +00:00
Poul-Henning Kamp
4090065137
Fix a problem that shows up if less than the full complement of
...
lock sectors are defined ("number_of_keys" argument to gbde init being
less than 4 in the default compile).
2004-09-11 17:58:53 +00:00
Poul-Henning Kamp
cbca0b53e5
Respect that G_BDE_MAXKEYS is a compile time variable.
2004-09-11 17:57:51 +00:00
Max Khon
51eb0765c6
Do not compile in zlib.c. Add a dependency on module instead.
2004-09-08 17:27:31 +00:00
Pawel Jakub Dawidek
f7b4d339ac
Show current status of mirror device directly.
...
Suggested by: Krzysztof Ciep³ucha <kris@home.pl>
2004-09-08 16:37:22 +00:00
Poul-Henning Kamp
5ae652c0ed
For removable devices without media we set a zero mediasize but a non-zero
...
sectorsize in order to avoid a lot of checks around various divisions etc.
Enforce the sectorsize being > 0 with a KASSERT on successful open.
Fix scsi_cd.c to return 2k sectors when no media inserted.
2004-09-05 21:15:58 +00:00
Pawel Jakub Dawidek
6d7b8aecd3
Allow to configure debug level from /boot/loader.conf.
2004-08-30 18:50:06 +00:00
Poul-Henning Kamp
dcbd0fe5aa
Add more KASSERTS and checks.
2004-08-30 09:33:06 +00:00
Pawel Jakub Dawidek
45d5e85a40
GCC, ehh.
2004-08-29 14:29:30 +00:00
Pawel Jakub Dawidek
c0d68b6ef2
Use sc->sc_mediasize instead of sc->sc_provider->mediasize which contains
...
exactly the same value, but is shorter.
2004-08-28 02:35:43 +00:00
Pawel Jakub Dawidek
08249e9e6e
Warn the user if we are not going to use whole provider space.
...
Requested by: Michael Handler <handler@grendel.net>
2004-08-28 02:34:10 +00:00
Pawel Jakub Dawidek
16ebaa0793
Don't allow to insert providers, which are too small.
...
Reported by: Michael Handler <handler@grendel.net>
2004-08-28 02:02:48 +00:00
Lukas Ertl
5bad268cdc
Move config_new_drive() to the correct place and rename it to
...
gv_config_new_drive().
2004-08-27 21:32:18 +00:00
Poul-Henning Kamp
a2033c9615
Introduce g_alloc_bio() as a waiting variant of g_new_bio().
...
Use in places where we can sleep and where we previously failed to check
for a NULL pointer.
MT5 candidate.
2004-08-27 14:43:11 +00:00
Lukas Ertl
4328802ce9
When attaching a consumer from a volume to a plex, check if the
...
volume already has a plex attached and adjust the access counts
of the new consumer accordingly.
2004-08-26 21:04:41 +00:00
Pawel Jakub Dawidek
29c78ab315
Skip providers with not defined sector size.
...
Reported by: kuriyama
2004-08-26 12:42:47 +00:00
Pawel Jakub Dawidek
4cf67afe37
Log verification errors at level 1.
2004-08-25 19:18:07 +00:00
Pawel Jakub Dawidek
f0c8658d4e
Dump disk number.
2004-08-25 12:14:44 +00:00
Pawel Jakub Dawidek
c8b906bcbe
Allow to set kern.geom.mirror.timeout from /boot/loader.conf.
2004-08-23 20:42:34 +00:00
Lukas Ertl
a3423d4c6f
Compare the addresses of two RAID5 work packets directly instead
...
of the addresses of their related bios when locking one out, since
they could share a bio and this could lead to parity corruption.
2004-08-23 17:50:18 +00:00
Lukas Ertl
c4bdc6fc32
Implement the possibility to remove drives.
2004-08-22 17:07:55 +00:00
Pawel Jakub Dawidek
dba915cfee
Implementation of 'verify reading' algorithm, which uses parity data for
...
verification of regular data when device is in complete state.
On verification error, EIO error is returned for the bio and sysctl
kern.geom.raid3.stat.parity_mismatch is increased.
Suggested by: phk
2004-08-22 16:21:12 +00:00
Lukas Ertl
45d0fdcda9
Add forgotten format specifier in a KASSERT and shut up the compiler.
...
Submitted by: Gavin Atkinson <gavin.atkinson@ury.york.ac.uk>
2004-08-22 13:34:24 +00:00
Pawel Jakub Dawidek
d12bd83e9b
Add version history.
2004-08-21 21:15:03 +00:00
Pawel Jakub Dawidek
f5a2f7feac
Implement new reading algorithm, which will use parity component for reading
...
as well, even if device is in complete state.
I observe 40% of speed-up with this option for random read operations,
but slowdown for sequential reads.
Basically, without this option reading from a RAID3 device built from 5
components (c0-c4) looks like this:
Request no. Used components
1 c0+c1+c2+c3
2 c0+c1+c2+c3
3 c0+c1+c2+c3
With the new feature:
Request no. Used components
1 c0+c1+c2+c3
2 (c1^c2^c3^c4)+c1+c2+c3
3 c0+(c0^c2^c3^c4)+c2+c3
4 c0+c1+(c0^c1^c3^c4)+c3
5 c0+c1+c2+(c0^c1^c2^c4)
6 c0+c1+c2+c3
[...]
2004-08-21 18:11:46 +00:00
Lukas Ertl
83bfcb1092
A volume can be up if it has a degraded RAID5 plex.
2004-08-19 12:03:27 +00:00
Pawel Jakub Dawidek
d86bc96cab
We really don't want to receive spoil event for synchroniztion consumers.
2004-08-18 23:33:37 +00:00
Poul-Henning Kamp
a9654c8c58
Do not override the class provided dumpconf function.
2004-08-18 21:42:08 +00:00
Lukas Ertl
9a8bd51965
Pretty print some informational messages.
2004-08-18 20:43:56 +00:00
Lukas Ertl
d30f29867e
Fix a stupid bug in the drive taste function: when checking if a
...
drive is known to the configuration check also if it already has a geom.
Without this check several needless geoms are created and valid
configuration data was overwritten.
This change obsoletes the need for a separate geom to taste an
offered provider and the consumer doesn't need to be opened with the
exclusive bit set.
2004-08-18 20:34:45 +00:00
Pawel Jakub Dawidek
b25aec32ff
NOP class doesn't operate on metadata, so the spoil event can be safely
...
ignored.
2004-08-18 16:58:42 +00:00
Pawel Jakub Dawidek
28b31df727
Dump device status on 'list' command.
2004-08-18 16:46:51 +00:00
Pawel Jakub Dawidek
f1ad62a4d8
Bump synchronization ID if we are sure, that we have ACTIVE components.
2004-08-18 07:28:48 +00:00
David E. O'Brien
fa6a78376f
Minor style.9 cleanup.
2004-08-16 10:33:35 +00:00
Pawel Jakub Dawidek
809a9dc601
Decrease debug level to 0.
2004-08-16 08:33:04 +00:00
Pawel Jakub Dawidek
5e6db16cd6
Fix warning.
2004-08-16 08:21:31 +00:00
Pawel Jakub Dawidek
2d1661a5b6
Introduce GEOM RAID3 class, i.e. kernel module, which implements RAID3
...
transformation and graid3(8) userland utility, which can be used for
configuration. No manual page yet, sorry.
Hardware provided by: Daniel Seuffert
2004-08-16 06:23:14 +00:00
Pawel Jakub Dawidek
f62d59df32
Avoid code duplication by introducing g_mirror_write_metadata() function,
...
which is used now by g_mirror_clear_metadata() function and
g_mirror_update_metadata() function.
2004-08-15 13:58:29 +00:00
Lukas Ertl
71fd4f60da
Make informational output look less like an accident.
2004-08-14 09:56:17 +00:00
Max Khon
75261008d7
Add geom_uzip -- geom class that implements read-only compressed disks.
...
Currently supports cloop V2.0 disk compression format.
May support more formats in future.
2004-08-13 09:40:58 +00:00
Pawel Jakub Dawidek
887c9fd564
MFp4: Simplify code a bit:
...
- Remove kern.geom.mirror.sync_block_size sysctl. It is quite obvious that we
want to use the biggest size possible.
- Do not use UMA zone for sync data allocations. There could be only one
synchronization request per synchronized disk at a time, so allocate memory
for one request on whole synchronization process related to one disk.
Tested by synchronizing one component (out of three) and by synchronizing
two components (out of three) in parallel.
2004-08-11 23:41:53 +00:00
Pawel Jakub Dawidek
445a4b68f2
Actually, HARDCODED flag isn't stored in metadata, so don't bother
...
dumping it.
2004-08-11 22:16:42 +00:00
Pawel Jakub Dawidek
2def749bb1
- Fix typo.
...
- Dump HARDCODED flag.
2004-08-11 22:12:44 +00:00
Pawel Jakub Dawidek
a5ef629f10
Increase default kern.geom.stripe.maxmem to 50 elements.
2004-08-11 12:57:17 +00:00
Pawel Jakub Dawidek
1b949c05a3
When sending request once again because of ENOMEM, reset bio_children
...
and bio_inbed fields to 0. Without this change we can end up with
I/O leakage in some rare situations.
I tested this change by putting failure probability mechanism simlar
to this used in NOP class into g_clone_bio(9) function, so it was
able to return NULL with the given probability.
Discussed with: phk
2004-08-11 12:04:35 +00:00
Pawel Jakub Dawidek
6d8fb92d78
Try harder to not panic on 'stop -f'.
...
After the commit, this command should be really safe to use.
2004-08-11 11:10:46 +00:00
Lukas Ertl
92f49a969d
If we kill the worklist thread of a RAID5 plex we can destroy
...
the worklist mutex at the same time, so move the mtx_destroy() call
to gv_kill_thread().
2004-08-10 20:51:48 +00:00
Lukas Ertl
ecffb8e64b
Lock the topology before calling gv_parse_config, not afterwards.
2004-08-10 20:15:12 +00:00