Re: [netbsd-users] Re: zvol performance expecations? zvol swap?

2021-02-17 Thread Malcolm Herbert
Also to note - zpools get really unhappy when allocation gets up above 80% - a 
set of pre-allocated thick-provisioned zvols on a fresh zpool set aside for 
this purpose is probably ok to take above that limit though, but you might want 
to workshop that ...

On Thu, 18 Feb 2021, at 11:15, Malcolm Herbert wrote:
> I typically use ZFS on Solaris or FreeBSD but would recommend using a 
> different zpool for swap if you can so you can have a different vdev 
> layout more suited to that load (ie, RAID1 rather than RAID5) and/or to 
> tweak other settings as desired independently of your data zpools
> 
> Either way, definitely provision your swap zvols as thick volumes so 
> that you have all the space you might need pre-allocated and you won't 
> force the system to hunt for more at the point where it is already 
> under load.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] Re: zvol performance expecations? zvol swap?

2021-02-17 Thread Malcolm Herbert
I typically use ZFS on Solaris or FreeBSD but would recommend using a different 
zpool for swap if you can so you can have a different vdev layout more suited 
to that load (ie, RAID1 rather than RAID5) and/or to tweak other settings as 
desired independently of your data zpools

Either way, definitely provision your swap zvols as thick volumes so that you 
have all the space you might need pre-allocated and you won't force the system 
to hunt for more at the point where it is already under load.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] Re: NetBSD ZFS compatibility with other OSs

2020-02-24 Thread Malcolm Herbert
slightly off-topic, but MacOS came >< this close to releasing with ZFS support, 
but it got scuppered at the last minute due to politics

https://news.ycombinator.com/item?id=17477600

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


VirtualBox guest support

2019-12-14 Thread Malcolm Herbert
On Fri, 13 Dec 2019, at 00:46, Valery Ushakov wrote:
> This is the semi-periodic reminder that Virtual Box Guest Additions do
> support NetBSD, the code has been in the public VirtualBox repository
> for more than 3 years (but vboxfs support *is* indeed missing).

Valery - apologies, I may have missed such a reminder ... in this the lack of 
vboxsf is a minor nuisance as NFS works just as well in most cases but requires 
configuration on the host end for support.

> GA have not been packaged though. ...

... does this mean I might be able to build from source on the host itself?  
Many of the other bento VMs do this as a matter of course as part of their 
build, so this isn't a show-stopper either

> ... The main obstacle is that kernel
> modules need access to some non-public kernel headers to be built.

I'm not sure I understand this last bit - non-public kernel headers from the 
NetBSD side or the VirtualBox side?

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] 8.1 sysinst script/logging failures

2019-12-11 Thread Malcolm Herbert
It looks as if 9.0_RC1 sysinst works as advertised for generating an install 
script, will work with that and can probably backport the bits I need from 
there to work with 8.1, thanks all.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


8.1 sysinst script/logging failures

2019-12-11 Thread Malcolm Herbert
As suggested in a different thread, sysinst has the capability to log the steps 
it took to create an install as a shell script.  Unfortunately when I tried it 
I got failures with an NetBSD-8.1-amd64.iso image running under VirtualBox 
5.2.6.  The path I took through sysinst was as follows:

a: installation messages in English
a:unchanged (keyboard type)
e:utility menu
e:logging functions
a:logging: on
b:scripting: on
x:exit
x:exit
a:install netbsd to hard disk
b:yes
a:wd0 (16GB, vbox harddisk)
a:this is the correct geometry
b:use the entire disk
a:yes (do you want to install the netbsd bootcode)
b:use existing partition sizes
x:partition sizes ok
name:(blank)

at this point I get a segfault and the terminal appears to be in noecho mode:

[1]   Segmentation fault  ${cmd}

If I repeat the above and put in a name for the disk, I get the same error.

/tmp/sysinst.log contains:
executing: gpt -qr header wd0
Creating disklabel VBOX HARDDISK   in /tmp/disktab.VBOX HARDDISK
executing: sh -c 'cat /tmp/disktab.* > /tmp/disktab'

/tmp/sysinst.sh contains:
gpt -qr header wd0
cat <> /etc/disktab
(a disk tab entry, however it appears to contain a lot of control characters, 
not just printable ascii)
EOF
sh -c 'cat /tmp/disktab.* > /tmp/disktab'

I am happy to run up a 9.0_RC1 and test the same there.  At the moment I don't 
have this VM in a state where I can copy files from it, so my description above 
is necessarily vague for the content of /etc/disktab - /tmp/disktab looks fine 
with no binary characters that I can see ...

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] About using NetBSD as a guest, why, how etc.

2019-12-10 Thread Malcolm Herbert
On Wed, 11 Dec 2019, at 09:33, Rhialto wrote:
> On Tue 10 Dec 2019 at 18:39:00 +1100, Malcolm Herbert wrote:
> > is doing a manual from-scratch install from the command-line
> > documented anywhere?
:
:
> But you can try another approach: you can have sysinst create a shell
> script which contains everything it does (at least when I tried it once
> upon a time it seemed to work). 

... I had no idea this feature was available, that's certainly a workable 
solution for me, thanks very much!

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] About using NetBSD as a guest, why, how etc.

2019-12-09 Thread Malcolm Herbert
Mayuresh - I find NetBSD in a VirtualBox VM under Ubuntu quite nice. In my case 
I also use encrypted zpools for my data which Linux supports now.

I like using VirtualBox+packer+vagrant with the bento[1] packer configs to spin 
out VMs of different types.  

My only gripe with VirtualBox is that it doesn't have native client tools 
support for the *BSD family and the vboxfs filesystem isn't available - 
ordinarily these provide file-level access to the host filesystem and vagrant 
heavily uses this.  Instead (for example), the packer+vagrant config for 
FreeBSD will use NFS which works but is a bit more fiddly to set up.

Unfortunately there is no bento recipe for NetBSD at all, so you'd have to 
build out the VM manually ...

I would like to create a bento recipe for NetBSD, however the bit that's 
preventing me doing this is understanding how to properly add disk labels and 
bootblocks from the command-line - one can stuff keys into the VM to drive 
sysinst but this is a nightmare to debug ... is doing a manual from-scratch 
install from the command-line documented anywhere?

Regards,
Malcolm

[1] https://github.com/chef/bento

-- 
Malcolm Herbert
m...@mjch.net


Re: [netbsd-users] Re: Basic vt100 console "noisy"

2019-11-21 Thread Malcolm Herbert
On Fri, 22 Nov 2019, at 07:40, Rhialto wrote:
:
:
> If you have a serial terminal at hand, it is always fun to try. I
> operated a DEC Alpha with a serial console, even though it had display
> hardware.

I had a real Wyse terminal running in vt52 emulation mode as a console for a 
number of years until the power supply blew and I was quoted an outrageous 
price to replace it ...  while it was running it was awesome to have that in 
the corner of the room - with screen running it was as functional as a regular 
pseudo-terminal ...

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


upgrade in-place process?

2019-10-17 Thread Malcolm Herbert
I have a VM with a provider that uses Xen under the hood.  Recently my VM 
suffered an outage which I believe may have been due to an upgrade of their 
platform to Xen 4.4.4 (or so dmesg says it is now).

My previous OS was (iirc) 6.1 and in order to get it to boot at all, the admin 
there has upgraded my kernel to 8.1_RC1 ...

I'm ok with this, but at some point I'll need to also upgrade all the userland 
binaries and I'm wondering the best method might be ... is there any 
documentation on how best to perform these steps?

Unfortunately although I do have the ability to start and stop the VM, I can't 
manipulate the VM config beyond asking their admin to boot my VM from a 
particular kernel image ... 

Should I ask that they boot from (say) the 8.1 netbsd-INSTALL_XEN3_DOMU.gz 
image and then go through the upgrade via that (I do have access to the 
console)?  Once that's done I can then ask that they boot from the regular 8.1 
netbsd-XEN3_DOMU.gz

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: portable USB disk installation

2019-10-06 Thread Malcolm Herbert
On Sun, Oct 06, 2019 at 03:28:39PM +0100, David Brownlee wrote:
|On Sun, 6 Oct 2019 at 14:03, Rhialto  wrote:
|> On Sun 06 Oct 2019 at 13:46:03 +0200, orr721 wrote:
|> > Is there some way how to make the installation disk number
|> > agnostic?
|>
[ snip ]
|>
|> So instead of '/dev/sd0a' you would use 'ROOT.a', etc.

huh ... when did this become available? that's pretty neat

continuing on with this feature, how does this interact with something
like /etc/dumpdates? does the root device name remain the same? dump
will rely on the device name to keep track of which level of dump is
required next ... if it changes, you might still need the RAIDFrame
trick below

|If you need to do this on older NetBSD systems you can setup a single
|element autoconfiguring raidframe device (eg raid6) and have root on
|raid6a - I've done that one NetBSD7 & 8. (If you are running a new
|enough release to have ROOT though, don't bother faffing with raidframe
|for this :-p)|

yes, I was about to chime in with this response as I do exactly this on
some of my older instances, but you beat me to it ... :)

also - I've recently discovered a bunch of disks with old installs of
NetBSD on them from some of my hosts where either the hardware died or
the disk developed dud sectors[1] ... modern Linux doesn't understand
RAIDFrame or ffs, but you can easily convince VirtualBox to create a
.vmdk disk which references the appropriate disk device[2], create an
appropriate VM shell and then boot directly off the USB disk - I mention
this because it might be useful for someone in a pinch if they have
a box which has fallen over and no other *BSD hosts handy to plug it
into[3]

Regards,
Malcolm

[1] in the case of the disk with bad sectors, the host couldn't complete
an fsck so I did need to use ddrescue to do a block-level copy of what
was recoverable first, but otherwise it was the same process

[2] not a copy, think more a symlink to it - for example:

  vboxmanage internalcommands createrawvmdk \
-rawdisk /dev/sdd1 -filename foo.vmdk

see https://www.virtualbox.org/manual/ch09.html#rawdisk

[3] be aware of RAIDFrame auto-numbering if you do this to a NetBSD host
that uses it, because the host sees it first before VirtualBox gets a
chance to ...

-- 
Malcolm Herbert
m...@mjch.net


Re: NFS client permanent mount points under /mnt?

2019-07-28 Thread Malcolm Herbert
On Sun, Jul 28, 2019 at 04:55:15PM +0930, Brett Lymn wrote:
|On Thu, Jul 25, 2019 at 08:02:34PM -0400, Greg Troxel wrote:
|> /mnt is for random use, when you have some unexpected drive and want
|> to use it. People who know tradition would be very surprised at
|> /mnt/nfs/host. So do not use /mnt.
|
|agreed, don't use /mnt, unfortunately linux does. I have shot myself in
|the foot many a time when doing a rescue, mount something on /mnt and
|then the rescue collapses because they built a mount tree under /mnt
|that I just covered up... gah

Solaris typically mounts the system being installed/rescued under /a for
this exact reason ...

|> I see your point about things deep in the hierarchy, but it's far
|> saner to mount the system or part of it, and symlink in. If you had
|> the disk from the system and mounted it, that's what you'd do.
|
|I don't agree with this - creating sym links can lead to a bunch of
|dangling sym links all over your file system, they can be hard to track
|down so messy to clean up. Much better to mount the fs where it is
|supposed to be in the first place. Also, to be nit-picky there is a
|performance impact from a sym link, the link is read every time it is
|traversed so you double your reads on a path traversal for every sym
|link.

I second this - I once inherited a site ($JOB-3) where (for some
non-obvious reasons) our Irix fleet depended upon a symlink hanging off
the NFS share from a central Linux box that pointed back to their own
local filesystem(!!) ... that was a fun one to sort out when we had a
hiccup with our main fileserver as they all just ... stopped ...

since then I've been a fan of mounting a filesystem somewhere out of the
way and then null/bind mounting where I actually need the content ...
makes things nice and explicit and easily discoverable ... this was back
in the day before LVM and ZFS with their pool-based model, so really the
only option to managing free space was sometimes to migrate data between
large filesystems and altering the relevant mounts ... the users were
none the wiser once that had completed ... and the nice thing was that I
couldn't unmount whilst anyone was using it, whereas with a symlink you
might not notice that it's changed

that said, sometimes unexpected mount ordering can ruin your day,
especially when there's something like ZFS in the mix, which does
its mounts outside of the usual 'mount -a' scope ... yes, one can flag
particular filesystems as 'mountpoint=legacy' which means they get
mounted from /etc/fstab, but that's ... hacky (and ZFS needs to be
explicitly enabled for bind mounts under Linux anyway)

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: Accessing a RAID disk attached externally via USB

2019-07-09 Thread Malcolm Herbert
On Tue, Jul 09, 2019 at 08:39:11PM -0400, Greg Troxel wrote:
|mlel...@serpens.de (Michael van Elst) writes:
|> fr...@phoenix.owl.de (Frank Wille) writes:
|>>It appears as sd0 with a RAID partition in sd0a. How can I access an
|>>FFS partition inside the RAID without changing anything on that RAID
|>>disk?
|
|I am assuming that this is raidframe and the original system is NetBSD.
|
|If you have raid autoconfig enabled, I'd expect the raid set to just
|appear, similar to how I would expect the original setup worked.

a note of caution on this however - I have had experience with
a external device and both my internal drive(s) using raidframe
autoconfigure ... during boot one or other will be remapped to different
raidN ID ... I'd gotten lucky in that my internal disks ended up on
raid0 where they were meant to be and the external was remapped to raid7
(iirc)

unfortunately, this change stays with the raidframe device, so when
you insert that external disk back into it's original host the kernel
on there can't boot because the root fs pivot fails ... some judicious
booting from an install CD got me out of that, but it was a definite
head-scratching moment to start with ...

|> You could create a RAID set that includes that disk and access the
|> raidframe device.
|>
|> You could also calculate the offset and size of the partition inside
|> the RAID volume and manually add a wedge with these parameters.
|
|The raid header is 64 blocks, so a wedge that is like sd0a but starts
|64 sectors later and ends in the same place should function like
|raid0d. Then of course you may have a disklabel or gpt inside the raid.

this seems the safest way ... of course if you want to absolutely
make sure you don't modify your original disk, use a hardware
duplicator first and use the copy (but be very very certain you haven't
accidentally put them in the wrong way around ... btdt)

Hope that helps,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: Serial SLIP Connection

2018-11-01 Thread Malcolm Herbert
I'm curious - why SLIP and not PPP?

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: security clarification, efail-attack-paper.pdf

2018-05-14 Thread Malcolm Herbert
On Mon, May 14, 2018 at 04:59:12PM -0700, George Georgalis wrote:
|Could someone clarify how this attack scenario plays out? Are these
|pgp/html mail clients actually so broke that they would send crypto
|secrets as part of an http request while rendering a malicious email?

my understanding is that the text/html portion of the email is laced
with strings which match the MIME boundary marker and a pgp-encrypted
block containing the message that the attacker wants to decrypt. certain
mail clients will do this and then drop the resultant cleartext into the
same memory location as the pre-rendered HTML portion of the email[1].

In their example, the plaintext is appended to the end of an image url,
so that when the mail reader gets to the point of rendering the html,
the link fires and the exfil occurs with the HTTP GET request

the basic issue is that text/plain and text/html forms can be
constructed so that the mime boundary isn't properly escaped (which is
the basic exploit here) - if mail readers insisted on base64 encoded
html when encountering pgp-encrypted email, I think the problem would go
away ...

Regards,
Malcolm

[1] the paper asserts that this occurs, I have no idea the actual mechanism

-- 
Malcolm Herbert
m...@mjch.net


Re: Any way to "passive commit" to RAM without syncing ?

2016-03-08 Thread Malcolm Herbert
Sounds like you're looking for a combo of overlay mounts on top of tmpfs
- the flush to disk you'd have to manage manually but I've done this
with some success in the past and I do seem to recall it being discussed
to provide pseudo read-write over a read-only medium such as a CDROM

http://netbsd.gw.com/cgi-bin/man-cgi?mount_overlay+8+NetBSD-current

the only caution is that I found it tricky to grok the sense of which
filesystem gets overlaid on what and where writes end up, but some
workshopping should show that up pretty quickly

Regards,
Malcolm

On Wed, Mar 9, 2016, at 10:49, Swift Griggs wrote:
> 
> I know NetBSD supports RAM disks. I also know it uses them for 
> installation, but I'm not sure if they are overlays on top of the static 
> disk images or if they get loaded/populated with the image after the 
> system boots. The effect is the same, either way. You end up with a 
> writable file system in RAM which is predicated on a disk image. I was 
> thinking about this in the context of another problem.
> 
> Let's say I've got a machine with a boatload of RAM and I have an 
> application which wants extremely fast writes, but doesn't really care 
> that much about data integrity, and this case, nor do I. Having the
> system 
> come back in the same state after rebooting is "nice to have" in this 
> thought experiment. Soo, here is the question:
> 
> Since a RAM disk is probably the fastest option, is there a way to 
> basically leave uncommitted data until I run "sync" or something calls 
> fsync() ? Even better, is there a way to fake a sync until I run
> something 
> else ?
> 
> In other words, operate out of a RAM disk until my human operator gives 
> the go-ahead to flush out the writes to disk or the RAM disk gets full. I 
> think Sprite did something like this back in the Jurassic Period. I also 
> remember CacheFS for Solaris doing something similar for NFS.
> 
> I can think of a few applications:
> 
> - Internet cafe style browsing where the machines are using older 
> hardware. They might benefit from using a small RAM disk overlay rather 
> than having to use something like a PATA disks for it's cache.
> 
> - Editing high bandwidth data like video or audio. Most of the time my 
> editing sessions don't last more than an hour and once I get a final cut
> I 
> just save the project to a server and don't care much about the recording 
> or editing workstation.
> 
> - Any kind of temporary storage that needs RAM disk speeds, but still 
> needs an option to sync/flush the file system back to long term storage.
> 
> I'm guessing this would be a little tricky with something like UFS since
> a 
> process could alter/write to a file and it'd need to reflect that when 
> another process wanted to do the same, fseek(), or dozens of other 
> operations. However, I just wonder if there is already a way to do this 
> and I'm just not aware of it.
> 
> I wonder if the LiveCD's for Linux that let you flush you changes to USB 
> do something similar. I doubt it. I'm guessing they just load a RAM disk 
> image and you operate on that until you reboot and it's lost.
> 
> -Swift


-- 
Malcolm Herbert
m...@mjch.net


Re: Changing one's subscribed-from email address

2016-02-21 Thread Malcolm Herbert
On Mon, Feb 22, 2016, at 07:18, Petar Bogdanovic wrote:
> You can "talk" to majord...@netbsd.org, i.e. send commands to majordomo
> within the body of messages addressed to majord...@netbsd.org.
> 
> Examples:
:
> 
> AFAIR, more than one command per message is allowed (subscribe!).

yes, however you may need to perform the authorisation round-dance for
each command, which may be a pain ... :)

-- 
Malcolm Herbert
m...@mjch.net


syspkg equivalent of pkgsrc audit?

2015-12-21 Thread Malcolm Herbert
Folks - I'm coming to the conclusion that for host which I'm using the system 
version of various tools[1] I have bad visibility for when these versions of 
the package become insecure and require an update.

Given that we don't have system packages to list in some manner similar to 
pkgsrc packages, what is the best method for comparing these against the 
content of the vulnerabilities file?

I tend to use the released versions of the OS from the relevant .iso - as part 
of the build process would it make sense to produce a file somewhere in /etc 
which lists the various bundled package versions grouped by install set?

Alternatively, has anyone got a guide for how to disable/replace as much of the 
system-supplied packages with their pkgsrc equivalent and get around the 
visibility problem that way?  This may be preferable as then we can update 
individual packages as required.

Regards,
Maloclm

[1] sshd, named/bind, postfix in the main

-- 
Malcolm Herbert
m...@mjch.net


bmake and interactive processes

2015-10-14 Thread Malcolm Herbert
Hello all - I've been a long time user of bmake/pmake for various
tasks and have recently started using my make recipes to initiate an
interactive PostgreSQL shell with the same set of arguments that I'm
using elsewhere and reduce some duplication in my code.

I'm finding that if I use ctrl-c to exit pgsql (and therefore make as
well) that my terminal appears to end up in a no-echo mode for some
reason. I definitely have this problem when using bmake/pmake under
Linux, I haven't confirmed whether this also is the case under NetBSD at
this point (I will do so tonight).

I am able to restore my terminal with 'reset' or 'stty sane' however
when I add these to rules within my Makefile they appear to be triggered
by make but by the time it finishes, the terminal is back to its broken
state.

I know make isn't designed to drive interactive commands, so this isn't
a gripe about that per se, but I am curious to know what I can do about
it. Does anyone have ideas? 

So far I've added a trap to the shell script on exit to run 'reset'
after the pgsql command exits, however as noted above, although my
terminal clears, the problem persists.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


Re: pf and rpi

2014-10-03 Thread Malcolm Herbert
On Sat, Oct 04, 2014 at 02:47:52AM +0200, Rhialto wrote:
|On Fri 03 Oct 2014 at 16:25:58 +0200, Zoran Kolic wrote:
| On freebsd I use ipfw, with rules that first one wins. On pf I know
| that the last one wins. Cannot be so sure reading npf howto. My bet
| is that the last wins too.
|
|I've never understood the reason for last one wins. That seems like
|unnecessary work, checking all those rules that may or may not be
|winning in the end. And you can get the same effect with a first one
|wins system (hence more efficiently) if you simply reverse the order
|of the rules.

this is why the 'quick' flag is there - it lets the filter engine stop
processing further rules on matching the one with the flag

I thought the argument went that if you set up rules that worked least
specifically to most, then with quick flag you get the best of both
worlds - you can elect to have the filter skip the remaining rules if
you want to or just let the packet trickle out through them all ...

putting the most specific rules at the top may result in bad performance
if most of your traffic doesn't match that rule

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgpvgx3RA2HKk.pgp
Description: PGP signature


Re: Reliable way to run emulated Linux under NetBSD

2014-08-14 Thread Malcolm Herbert
On Thu, Aug 14, 2014 at 08:33:03AM +0100, Matthias Scheler wrote:
|On Wed, Aug 13, 2014 at 10:22:16AM +0200, Kamil Rytarowski wrote:
| I'm looking for a reliable and flawless way to run emulated Linux
| (GNU/Linux distribution under some tool). I'm using i386 and amd64.
|
|A Xen domU under a NetBSD dom0 would do that job.

just curious - has anyone thought of creating a Linux Docker API
work-alike layer for NetBSD to act as either a guest or host? I
understand that Xen is probably a preferred solution for the moment, but
I would be curious as to whether that might be useful as an approach

it is definitely flavour of the month in DevOps circles now but might
be worth a look ... I'm not a dev, so I have no idea how much work that
would entail behind the scenes to implement

as far as I understand it, in order to get any sort of widespread
adoption the Docker API would need to be fairly stable and consistent
among the various Linux flavours and kernel versions out there, which
might make it a good target to work toward from the *BSD side ...

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgpmako12v3wY.pgp
Description: PGP signature


Re: disk numbering

2014-03-11 Thread Malcolm Herbert
On Tue, Mar 11, 2014 at 09:01:18PM +1300, Mark Davies wrote:
|On Tuesday 11 March 2014 19:44:47 you wrote:
| To be perfectly honest, I don't understand why you (or anyone) would
| require that. Why might *I* need that, for example?
|
|In this particular case the ahcisata connected drives are internal and
|always there whereas the siisata connected ones are external and are
|sometimes attached sometimes not. I'd rather not have my primary system
|disk sometimes called wd0, sometimes wd1 and sometimes wd2 depending on
|what external disks are attached at the time.

Someone else beat me to it, but for some time I have set up broken
RAIDFrame mirrors with autoconfigure root set for this reason alone.
When RAIDFrame starts it automagically re-mounts the root filesystem
from the raid device rather than whatever it actually booted from.

It can be annoying to set up, however I have been able to script this
with few problems for when I'm building new hosts

There are drawbacks - last time I tried this on a laptop I was unable
to suspend the laptop as the raid driver (at the time) didn't allow for
this ... I'm not sure whether that's been fixed as I haven't tried it on
a physical host for a while.

Being able to boot a host from any disk and just have /etc/fstab
Just Work was very useful, though if you have two RAIDFrame mirrors
configured to autoconfigure to the same raid device, be prepared for
pain as one will get shunted to a spare raid device instance number and
will keep that on subsequent boots.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgpVgR3BYbAls.pgp
Description: PGP signature


pmake/NetBSD make sources for Linux?

2014-01-05 Thread Malcolm Herbert
I've got a set of tools and management bits and pieces I've been using
quite successfully under NetBSD but I'm having trouble migrating these
to a Linux environment.

I had an abortive attempt at converting these to use GNU make but found
this to be too much pain ... unfortunately there seems to be at least
equal amount of pain trying to track down precompiled binary packages of
pmake on various Linux distributions[1] - I'm trying to get it working
for RedHat and SuSE at this point ...

Instead of looking for packaged versions, I thought I'd try copying out
the version that's bundled with pkgsrc however this seems to rely on an
nbcompat layer which would force me to compile up more of the pkgsrc
tool chain than I want in this instance ... unless I'm off-track here
tand his is the only way to do it using the pkgsrc bootstrap

Alternatively, are there reasonably current stand-alone versions of
pmake to be had that would compile under Linux that someone can point me
at[3]?

It's meant to be portable[4], according to the label on the tin ... :)

Regards,
Malcolm

[1] ubuntu seems to be the exception - I've found a mostly working version
of pmake in freebsd-buildtools as well as a pmake package which seem to 
do the right thing, but without a binary package specific to the distro
I need it on, I'll need to compile and link it in-situ I think

[2] to add to the confusion, pmake.sourceforge.net seems to be a dead python
make project, which is annoying as it's referenced in vulnerability reports
for the real pmake (cf http://xforce.iss.net/xforce/xfdb/67495)

[3] I've got almost exactly the same question about mtree, if anyone
has hints on where to find current source for that which would work under
Linux too, that would be appreciated

[4] unless this means 'parallel', I never got a good answer to this

-- 
Malcolm Herbert
m...@mjch.net


pgpOCtHNISR34.pgp
Description: PGP signature


Re: pmake/NetBSD make sources for Linux?

2014-01-05 Thread Malcolm Herbert
On Mon, Jan 06, 2014 at 01:36:34PM +1100, Malcolm Herbert wrote:
|Alternatively, are there reasonably current stand-alone versions of
|pmake to be had that would compile under Linux that someone can point
|me at[3]?

I've had a second attempt at trying to do this with the pkgsrc bootstrap
and found that it seems to work well enough for my purposes ... it's a
little more fiddly to get working, but once I have the binaries I don't
mind - it also resolves the hunt for mtree sources that work since once
the bootstrap is done, I am in a position to just build that directly
from source ...

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgplsmHvlvhih.pgp
Description: PGP signature


Re: issues running i386 6.1 under VirtualBox 4.2.12

2013-06-20 Thread Malcolm Herbert
On Fri, Jun 21, 2013, at 9:11, Malcolm Herbert wrote:
 Hi all - I'm trying to put together a small i386 6.1 host running under
 a 32-bit version of Windows 7 using VirtualBox 4.2.12.  At the moment I
 can't boot the VM guest from the NetBSD-6.1-i386.iso image as the
 install kernel panics (all typos mine - I can't cut and paste this
 text):

I tried booting from older installation media (6.0.2 and 5.0) and got
the same result.  Interestingly, one of the boot attempts crashed
VirtualBox itself ...

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


cpp in base?

2013-06-03 Thread Malcolm Herbert
quick question - should I be able to use /usr/bin/cpp -E without having
installed the compiler binary set? So far on this 5.1.2 host I've got
the base and etc sets installed and when trying to use cpp as a pre-processor
only, I get the following:

|deimos[~/tmp/cpp] 249v: cpp -E ./blah
|cpp: error trying to exec 'cc1': execvp: No such file or directory

Is this intentional?  I'd prefer not to install the compiler set if I 
don't have to as this is a host with limited disk space.

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgpuRusMzvM0x.pgp
Description: PGP signature


Re: Question about nmbclusters

2013-05-22 Thread Malcolm Herbert
On Wed, May 22, 2013 at 09:50:12PM -0400, yancm wrote:
|I am pretty sure you will need to compile this into a new kernel.
|I have used:
|options NKMEMPAGES=98352
|options NMBCLUSTERS=65568
|in my kernel config file in the past...pretty sure I remember it not
|being configurable at runtime.

quick question - of the parameters that are not modifiable once the kernel is 
booted, are there some that are tweakable from the boot loader?  ie, can we
do something like

  boot [args] hd0a:netbsd [ key=value ... ]

Regards,
Malcolm

-- 
Malcolm Herbert
m...@mjch.net


pgpJhIkkfoD9Z.pgp
Description: PGP signature


Re: reset with fss on 5.1.2

2013-02-25 Thread Malcolm Herbert
On Mon, Feb 25, 2013 at 10:02:45PM +1100, Malcolm Herbert wrote:
|I've been looking at using fss with dump to prevent filesystem skew
|when taking backups. The method explained in the NetBSD Guide[1] looks
|promising, however I'm experiencing immediate host reboots when running
|the initial fssconfig command.

I've now tried minimal installs of 5.1.2 and 6.0 with both amd64 and
i386 ports - it appears that only 5.1.2 on amd64 has the problem.

I've managed to generate a screencap and placed this online at:

  http://deimos.ergonaut.org/pub/netbsd/netbsd-5_1_2-amd64-minimal-fss-panic.png

Regards,
Malcolm

-- 
Malcolm HerbertThis brain intentionally
m...@mjch.netleft blank


pgpOqixrJgWuL.pgp
Description: PGP signature