Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

testing new postinstall check/fix pwd_mkdb



Is there anybody who has old versions of /etc/pwd.db and/etc/spwd.db (created under NetBSD-5 or earlier), on a system running the netbsd-6 branch? Can you test whether "postinstall check pwd_mkdb" and "postinstall fix pwd_pkdb" work with the -current version of postinstall?

   # verify that you have an old pwd.db
   #
   # output should be either an error message,
   #    db: Unknown key `VERSION\0x'
   # or lots of zeros:
   #    VERSION\000     \000\000\000\000
   #
   db -N -Sb -Ub -To hash /etc/pwd.db 'VERSION\0';

   # obtain a new postinstall
   #
   cd src/usr.sbin/postinstall;
   cvs update -p -r1.130 postinstall >postinstall.new;

   # run the new postinstall.
   #
   sh ./postinstall.new check pwd_mkdb;
   sh ./postinstall.new fix pwd_mkdb;

   # verify that your pwd.db has been updated
   #
   # output should be version 1, in big-endian or little-endian 32 bits:
   #    VERSION\000     \001\000\000\000
   # or
   #    VERSION\000     \000\000\000\001
   #
   db -N -Sb -Ub -To hash /etc/pwd.db 'VERSION\0';

--apb (Alan Barrett)


Home | Main Index | Thread Index | Old Index