Bug #541
closedmulti-vkd support patch for review
0%
Description
Well.. I suppose it's time to stop lurking and come out of the
woodwork..
Attached is a multi-vkd patch for vkernels on the 1.8-RELEASE branch.
(plus a couple of very minor typo fixups in the multi-vke code)
Since I'm pretty out of date on my C, no comments can be too harsh :)
a.k.a
I'm not used to strong typing at the moment, unless you count 'cons'
or 'my %tab;' a strong type..
so I'll be glad to fix asap - hoping something like this can
make release, although I know it might be too late..
The patch tries to match the multi-vke organization as much as it can,
maxing out via #define at 16 vkd's, which should be pretty good
for most purposes. Also, it kludges the '-r' argument to mean
'disk' - let me know if I should fix the manpage / vkernel
usage statement..
As far as testing goes, I basically made sure I can label, newfs,
mount and fill the disks.. vinum/ccd remains incomplete/unested..
(see below)
Simple FFS Check:
Fill up a bunch of single-partition disks..
- uname -sr
DragonFly 1.8.0-RELEASE - df
Filesystem 1K-blocks Used Avail Capacity Mounted on
/dev/vkd0a 1032142 314428 635144 33% /
/dev/vkd1a 120926 120898 -9646 109% /mnt/1
/dev/vkd2a 120926 120898 -9646 109% /mnt/2
/dev/vkd3a 120926 120898 -9646 109% /mnt/3
/dev/vkd4a 120926 120898 -9646 109% /mnt/4
/dev/vkd5a 120926 120898 -9646 109% /mnt/5
/dev/vkd6a 120926 120898 -9646 109% /mnt/6
/dev/vkd7a 120926 120898 -9646 109% /mnt/7
/dev/vkd8a 120926 120898 -9646 109% /mnt/8
/dev/vkd9a 120926 120898 -9646 109% /mnt/9
/dev/vkd10a 120926 120898 -9646 109% /mnt/10
/dev/vkd11a 120926 120898 -9646 109% /mnt/11
/dev/vkd12a 120926 120898 -9646 109% /mnt/12
/dev/vkd13a 120926 120898 -9646 109% /mnt/13
/dev/vkd14a 120926 120898 -9646 109% /mnt/14
/dev/vkd15a 120926 120898 -9646 109% /mnt/15 - du -sk /mnt/*/*
120896 /mnt/1/testfile
120896 /mnt/10/testfile
120896 /mnt/11/testfile
120896 /mnt/12/testfile
120896 /mnt/13/testfile
120896 /mnt/14/testfile
120896 /mnt/15/testfile
238224 /mnt/16/testfile
120896 /mnt/2/testfile
120896 /mnt/3/testfile
120896 /mnt/4/testfile
120896 /mnt/5/testfile
120896 /mnt/6/testfile
120896 /mnt/7/testfile
120896 /mnt/8/testfile
120896 /mnt/9/testfile - uptime
12:09AM up 42 mins, 1 user, load averages: 6.30, 9.58, 5.45
(/mnt/16/ results from my 'test accessing one too many disks' logic
gone bad)
Vinum Check:
well - perhaps eventually.. current status (after relabeling):
- cat vinum.conf.disks
drive d1 device /dev/vkd1a
drive d2 device /dev/vkd2a - vinum create -f vinum.conf.disks
Bus error (core dumped)
and I think I won't look further as the build box is a PII-450
that's chewing on a pgksrc bulk at the moment..
Lurker Comments:
I've been using DragonFly since late 1.4.x as my day-to-day desktop,
and I must say the experience is great, I like all the goals, pkgsrc
is a great fit, and I'm looking forward to using the VKERNEL for more
systems testing (hopefully with a faster box :)..
thanks to the team for running a great project!
I've got some other vkernel / dfly related ideas floating around
in my head, that I might work on but would like to throw out there
while I'm on my lurk-box to test the waters in case I don't get
to them just yet:
- arbitrary VKERNEL tty's via a fifo for 'detached' operation
- some kind of control socket protocol
(e.g. host-initiated clean shutdown, etc),
or signal handler hook-scripts, etc.
- leaving a pidfile somehwere
- auto host-side pf rulesets on vkernel startup
(to constrain the vkernels)
- expanding vkd's into some kind of spoofed cam / scsi bus
to allow for 'hotswap' vkds , etc.
- importing KAME SCTP, if there's any use for it and I'm capable of
it.. (that one just got in my head somehow.. cough syslink
transport ..?? ;)
Any comments on implementing some of the above would be welcome -
my kernel skillz are very weak. Need to get the McKusic book methinks :)
Probably the tty-on-a-pipe would be my first choice / next target..
Thanks again for creating a great system!
- Chris
Files