[OpenIndiana-discuss] How to straighten out an /etc/passwd /etc/opasswd mess I've created

hput hputn3 at zohomail.com
Tue May 31 16:17:54 UTC 2022


Till Wegmueller <toasterson at gmail.com> writes:

> Hi
>
> A quick and dirty way of regenerating without your changes to the system is.
>
> 0. Create a backup boot environment where you still can log in.
> 1. Be logged in as root.
> 2. backup the files "mv /etc/passwd{,.bak}" for /etc/group /etc/passwd
> and /etc/shadow. use mv so the files are not present for the next
> step, as pkg would try to update them otherwise as they are marked as
> configuration files
> 3. run 'pkg fix -v' to generate new /etc/passwd /etc/group and
> /etc/shadow files from the packages installed in the system image. pkg
> should tell you exactly the actions it is going to take.
> 4. use useradd to add users again that you added manually.
>
> Hope this helps
> Greetings
> Till

[...]

This is excellent information.  One of those items that must be saved.

Soon after posting I realized I have at least 2 snapshots I'd created
before I got the started the time-slider going... so I was able to
resort to snapshot of backups after all, its nworking fine

Thank you Till
and
Thank you all  




More information about the openindiana-discuss mailing list