Re: upgrading an old system
On 08/16/16 14:45, Brad Spencer wrote: Going from 2.0 or 3.0 it might be simpler to find another hard drive and install it in the system and just reload everything onto the new drive and swap it in. I wouldn't be too worried about booting a netbsd-7 kernel on a v2 system. But there is a pitfall: Newer systems will not let you log on to multi-user without a populated /etc/pam.d, which IIRC was fois^W^Wcame to us with netbsd-3. Cheerio, hauke -- The ASCII Ribbon CampaignHauke Fath () No HTML/RTF in email Institut für Nachrichtentechnik /\ No Word docs in email TU Darmstadt Respect for open standards Ruf +49-6151-16-3281
Re: upgrading an old system
On Wed, Aug 17, 2016 at 07:25:52PM +0100, Steve Blinkhorn wrote: > I have progresses as far as having oinstalled the binary sets and > running postinstall. However I hit a problem when I set a password > for root, namely while I could login as another user (in group wheel) > I get an authentication error when I try to su, and I can't get back > to a condition where there is no superuser passwd. So I daren't for > the moment swith the box off. > Try a vipw and remove the password entry, this is the string between the ':' just after the username, viz: root:fsrtew$srewza:0:0::0:0:Charlie &:. to root::0:0::0:0:Charlie &:. > I remember that therre were various gotchas when PAM was introduced in > release 3.0. Is there a step I may have missed out? > There shouldn't be unless you are using a su from an unexpected place, try /usr/bin/su just to make sure. > Also, would someone please remind me where the boot-time > configuration lives (boot device, root device, swap device etc.)? > It's been a long day, and I don't get to do this sort of thing very > often. > I usually bury that in the kernel config, perhaps boot.cfg can help but I am not sure about that. -- Brett Lymn
Re: upgrading an old system
I have progresses as far as having oinstalled the binary sets and running postinstall. However I hit a problem when I set a password for root, namely while I could login as another user (in group wheel) I get an authentication error when I try to su, and I can't get back to a condition where there is no superuser passwd. So I daren't for the moment swith the box off. I remember that therre were various gotchas when PAM was introduced in release 3.0. Is there a step I may have missed out? Also, would someone please remind me where the boot-time configuration lives (boot device, root device, swap device etc.)? It's been a long day, and I don't get to do this sort of thing very often. -- Steve Blinkhorn
Re: upgrading an old system
On Tue, 16 Aug 2016, Steve Blinkhorn wrote: > But the disk layout is sorely in need of revision. I'm not trying to be trite, but have you simply considered using dump(8) to backup your filesystems, install your chosen revision, and then restore ? I haven't been closely following the thread, so I apologize if this doesn't work for you for some reason. However, here's a case for backup/restore: 1. You won't have to worry about ABI issues (but NetBSD does well here, as discussed). 2. USB disks and network backup targets are very cheap these days. If you lack good on-site access, a network backup still works if you have some option for that (or simply FTP the compressed dump file somewhere). 3. Most applications keep localized data out of the OS file systems making it pretty easy to move to a new revision. Using the dump(8) utility will save your permissions etc.. > Is the disk layout configuration tool accessible other than through > running sysinst, or will I have to bite the bullet and edit the disk > label by hand? I don't think the disklabel format has changed in a lng time. If it helps you, boot a newer revision of NetBSD and use the tool. Then you can reboot whatever version you want to install and Just Do It. -Swift
Re: upgrading an old system
Very gratefule for all the good advice.Here's the story so far. First of all, I was able to boot a 7.0 kernel with no difficulty - and in the process discovered that there have been 2 CPUs all along. But the disk layout is sorely in need of revision. So I have tried everything I can find: in summary, cutting a new install image CD failed to producenything that worked in the CD-ROM drive. I have a 2.02 install CD that goes into sysinst, but skips the disk layout process and goes straight to installing sets. Other bootable media I have don't boot in this drive. I do remember the days when CD-ROM drives could be very fussy about CD-R and CD-RW media. The 3.0 machine has a much saner disk layout - very possibly because I configured it, whereas the 2.0 was configured by data centre staff way back when. So I think I can move that forwad straightforwardly. Is the disk layout configuration tool accessible other than through running sysinst, or will I have to bite the bullet and edit the disk label by hand? I think there is a sensibly sized root partition on the 2.0 machine, so it might be possible to leave that untouched, adjust the (insanely small) swap partition, and set up a sensible layour for the rest of the disk while keeping a bootable root partition. All thoughts welcome. -- Steve BlinkhornYou wrote: > > st...@prd.co.uk (Steve Blinkhorn) writes: > > [snip] > > > While I have them here I want to upgrade them to 7.0 (i386). But one is > > 2.0, the other 3.0 at present. > > > > It looks as though they will not boot from their USB ports, the > > CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can > > find any blank CD-ROM disks). They have floppy drives, but I'm not > > sure I have a working floppy drive on a working machine any more. > > [snip] > > A lot of good advise has been given. I performed an upgrade from NetBSD > 4.0_STABLE to 7.0 this year on two of my systems. Basically all I ended > up doing was building a new 7.0 kernel and booting that up. The 4.0 > boot blocks were able to deal with a 7.0 kernel without any issues. > Then I unpacked the tar ball sets onto the system and rebooting again. > Then ran postinstall and reboot again. It all worked well, except for > one thing... 7.0 does not support schedular activations and anything > compiled against the old libpthreads failed. This effected packages > from package source, so I also had to recompile everything from package > source that I needed. This was a bit unexpected, but not fatal, and I > was going to do that anyway. This is one place where the extremely good > binary compatibility that NetBSD has will probably fall over. > > Going from 2.0 or 3.0 it might be simpler to find another hard drive and > install it in the system and just reload everything onto the new drive > and swap it in. You probably can install it on another system, if > needed, but assuming that the CD-ROM is bootable everything should fit > on a CD on the target system [sans a lack of blank media...]. You > mentioned that the filesystems were doing to be resized... this will > almost certainly need to be done anyway. With the addition of /stand, > which I don't think was in 2.0 or 3.0, you may not have enough room in / > to unpack the system. I nearly ran into this with an ancient laptop > that went from 4.0_STABLE to 7.0. The size of /stand was larger and > things just barely fit. > > > > > > -- > Brad Spencer - b...@anduin.eldar.org - KC8VKS > http://anduin.eldar.org - & - http://anduin.ipv6.eldar.org [IPv6 only] > -- Steve Blinkhorn This email is for the addressee only. If you are not the addressee you should immediately delete this email from your system(s) and inform us. It may contain information that is confidential or otherwise privileged, and should not be copied or redistributed to recipients not originally specified as addressees without permission. S F Blinkhorn MA PhD CPsychol FBPsS, Managing Director, Psychometric Research & Development Ltd. PO Box 1143, St Albans, Herts, AL1 9UT, UK Registered in England No. 1909571 Registered Office: 45 Grosvenor Rd., St Albans, Herts, AL1 3AW Phone: +44 (0)1727 841455 http://www.prd.co.uk
Re: upgrading an old system
st...@prd.co.uk (Steve Blinkhorn) writes: [snip] > While I have them here I want to upgrade them to 7.0 (i386). But one is > 2.0, the other 3.0 at present. > > It looks as though they will not boot from their USB ports, the > CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can > find any blank CD-ROM disks). They have floppy drives, but I'm not > sure I have a working floppy drive on a working machine any more. [snip] A lot of good advise has been given. I performed an upgrade from NetBSD 4.0_STABLE to 7.0 this year on two of my systems. Basically all I ended up doing was building a new 7.0 kernel and booting that up. The 4.0 boot blocks were able to deal with a 7.0 kernel without any issues. Then I unpacked the tar ball sets onto the system and rebooting again. Then ran postinstall and reboot again. It all worked well, except for one thing... 7.0 does not support schedular activations and anything compiled against the old libpthreads failed. This effected packages from package source, so I also had to recompile everything from package source that I needed. This was a bit unexpected, but not fatal, and I was going to do that anyway. This is one place where the extremely good binary compatibility that NetBSD has will probably fall over. Going from 2.0 or 3.0 it might be simpler to find another hard drive and install it in the system and just reload everything onto the new drive and swap it in. You probably can install it on another system, if needed, but assuming that the CD-ROM is bootable everything should fit on a CD on the target system [sans a lack of blank media...]. You mentioned that the filesystems were doing to be resized... this will almost certainly need to be done anyway. With the addition of /stand, which I don't think was in 2.0 or 3.0, you may not have enough room in / to unpack the system. I nearly ran into this with an ancient laptop that went from 4.0_STABLE to 7.0. The size of /stand was larger and things just barely fit. -- Brad Spencer - b...@anduin.eldar.org - KC8VKS http://anduin.eldar.org - & - http://anduin.ipv6.eldar.org [IPv6 only]
Re: upgrading an old system
With such old systems and doing upgrades, there are a few things to worry about compared to updating one version at a time: 1) boot blocks. At least at some point for sparc, my memory is fuzzy, but I had a problem that seems like: I think around NetBSD 3, the boot blocks for NetBSD 3 would not boot 5 kernels. So if you updated to 4 and then installed 4 bootblocks, you were ok. 2) binary compat. NetBSD is really good about binary compat, but I am not sure that the compat options are turned on by default. So booting a netbsd 7 kernel on a 2.0 system may not entirely work. I would recommend one of several options: 0) First, make backups. 1) as coypu@ said, you can put the disk in some other box, upgrade, and put it back. 2) A) Create a script /.installboot to: cp /usr/mdec/boot to /boot, and also to run installboot. Mine is attached, but note that you need to get the root fs type right, do the right thing for raid, and set any serial console options. Run this on the system as it is. B) install sysutils/etcmanage from pkgsrc, and read the etcmanage howto. Register the files that you haven't changed from the system via etcmanage --import, using a manifest that you create from the 2.0 or 3.0 install sets from the archives. C) Get the next version of the OS, and use INSTALL-NetBSD installkernel (from the etcmanage package), and reboot. If that is ok do installuser. Check the etcmanage situation (it will autoupgrade what it can). Repeat for the next version. Optionally, skip versions. As long as the new kernel boots, and you can run the userland install (which involves perl to run etcmanage), you should be able to skip. Probably you can jump from 2 to 4. Probably even to 5. 5 to 7 is probably ok. I have no idea about 2 to 7, but if you just boot a 7 kernel and see if the system is ok, it's likely ok to upgrade if it comes up. #!/bin/sh installboot -v /dev/rwd0a /usr/mdec/bootxx_ffsv1 cp -p /usr/mdec/boot / signature.asc Description: PGP signature
Re: upgrading an old system
My memory us that whne booting an installation floppy the first stages involve setting up an MFS and proceeding to the resst of the installation over FTP, NFS or whatever. Is there not a way of setting up this MFS from the existing file system? I seem to remember warnings not to power cycle before a certain stage had been reached. -- Steve BlinkhornYou wrote: > > => I have two servers I have just retrieved from their regular home in a > => data centre some distance away. (Less tha opportune interventions by > => the staff there meant they would not accept remote logins). > => > => While I have them here I want to upgrade them to 7.0 (i386). But one is > => 2.0, the other 3.0 at present. > >Wow. > > => It looks as though they will not boot from their USB ports, the > => CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can > => find any blank CD-ROM disks). They have floppy drives, but I'm not > => sure I have a working floppy drive on a working machine any more. > >I would think CD-ROM would be the way to go. Surely someone in the area > has a stack in the back closet. > > => I have both the machines running normally, and I've backed up everything I > => need to keep. Is there a way of upgrading these machines by placing > => initial installation files on their hard drives, say in a /altboot > => directory, bootin from there and doing the rest over NFS or FTP? I > => have to do an install because I think both machines need new boot > => blocks to even boot newer releases. I also need to change the disk > => layout to add more swap space and create /tmp on disk rather than in an > => MFS. > >Upgrading via installer from the hard drive was easier up to NetBSD 6, > as you could boot an INSTALL kernel and point it at the sets on your > hard drive as /targetroot. Since NetBSD 7 I've just dumped an install > image on USB flash and booted that. That still wouldn't help > restructuring the partitions, though; you want to boot from alternate > media for that. > > => I am under time pressure because these two machines form the backbone > => of live 24/7/365 services, now being run on VPSs in their absence. > >This seems exactly the sort of thing you don't want to do under time > pressure. > >Good luck... > > >Gary Duzan > > > => -- > => Steve Blinkhorn > => > => > > >
Re: upgrading an old system
Probably less "cool", but I've previously installed to older i386 machines by just putting their hard disks in a newer amd64 machine that could boot from USB. If you are still interested in a more complex setup, several people have install scripts that could help you not miss any steps you might forget in a manual install, e.g.: http://mirror.isoc.org.il/pub/netbsd/misc/kamil/autoinst.sh (I have not tried it myself so cannot testify for it) I imagine it is also possible to execute these steps in single user. On Mon, Aug 15, 2016 at 07:15:01PM +0100, Steve Blinkhorn wrote: > I have two servers I have just retrieved from their regular home in a > data centre some distance away. (Less tha opportune interventions by > the staff there meant they would not accept remote logins). > > While I have them here I want to upgrade them to 7.0 (i386). But one is > 2.0, the other 3.0 at present. > > It looks as though they will not boot from their USB ports, the > CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can > find any blank CD-ROM disks). They have floppy drives, but I'm not > sure I have a working floppy drive on a working machine any more. > > I have both the machines running normally, and I've backed up everything I > need to keep. Is there a way of upgrading these machines by placing > initial installation files on their hard drives, say in a /altboot > directory, bootin from there and doing the rest over NFS or FTP? I > have to do an install because I think both machines need new boot > blocks to even boot newer releases. I also need to change the disk > layout to add more swap space and create /tmp on disk rather than in an > MFS. > > I am under time pressure because these two machines form the backbone > of live 24/7/365 services, now being run on VPSs in their absence. > > -- > Steve Blinkhorn
Re: upgrading an old system
=> I have two servers I have just retrieved from their regular home in a => data centre some distance away. (Less tha opportune interventions by => the staff there meant they would not accept remote logins). => => While I have them here I want to upgrade them to 7.0 (i386). But one is => 2.0, the other 3.0 at present. Wow. => It looks as though they will not boot from their USB ports, the => CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can => find any blank CD-ROM disks). They have floppy drives, but I'm not => sure I have a working floppy drive on a working machine any more. I would think CD-ROM would be the way to go. Surely someone in the area has a stack in the back closet. => I have both the machines running normally, and I've backed up everything I => need to keep. Is there a way of upgrading these machines by placing => initial installation files on their hard drives, say in a /altboot => directory, bootin from there and doing the rest over NFS or FTP? I => have to do an install because I think both machines need new boot => blocks to even boot newer releases. I also need to change the disk => layout to add more swap space and create /tmp on disk rather than in an => MFS. Upgrading via installer from the hard drive was easier up to NetBSD 6, as you could boot an INSTALL kernel and point it at the sets on your hard drive as /targetroot. Since NetBSD 7 I've just dumped an install image on USB flash and booted that. That still wouldn't help restructuring the partitions, though; you want to boot from alternate media for that. => I am under time pressure because these two machines form the backbone => of live 24/7/365 services, now being run on VPSs in their absence. This seems exactly the sort of thing you don't want to do under time pressure. Good luck... Gary Duzan => -- => Steve Blinkhorn=> =>
upgrading an old system
I have two servers I have just retrieved from their regular home in a data centre some distance away. (Less tha opportune interventions by the staff there meant they would not accept remote logins). While I have them here I want to upgrade them to 7.0 (i386). But one is 2.0, the other 3.0 at present. It looks as though they will not boot from their USB ports, the CD-ROM drives seem not to be DVD-compatible (and I'm not sure I can find any blank CD-ROM disks). They have floppy drives, but I'm not sure I have a working floppy drive on a working machine any more. I have both the machines running normally, and I've backed up everything I need to keep. Is there a way of upgrading these machines by placing initial installation files on their hard drives, say in a /altboot directory, bootin from there and doing the rest over NFS or FTP? I have to do an install because I think both machines need new boot blocks to even boot newer releases. I also need to change the disk layout to add more swap space and create /tmp on disk rather than in an MFS. I am under time pressure because these two machines form the backbone of live 24/7/365 services, now being run on VPSs in their absence. -- Steve Blinkhorn