Solved pw: user '_dnscrypt-proxy' disappeared during update / pkg: PRE-INSTALL script failed...

Hello.

is this a bug that you know ? is there a fix ? thank you.

Code:
[mario@marietto /home/marietto]==> pkg upgrade

Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Checking for upgrades (87 candidates): 100%
Processing candidates (87 candidates): 100%
Checking integrity... done (0 conflicting)
The following 55 package(s) will be affected (of 0 checked):

Installed packages to be UPGRADED:
    alacritty: 0.13.2 -> 0.13.2_1
    apg: 1.2.0_1,1 -> 1.2.0_2,1
    bat: 0.23.0_12 -> 0.23.0_13
    dnscrypt-proxy2: 2.1.5_5 -> 2.1.5_6
    doas: 6.3p10 -> 6.3p12
    ebur128: 0.1.8_8 -> 0.1.8_9
    firefox: 126.0,2 -> 126.0_2,2
    freebsd-release-manifests: 20240504 -> 20240511
    fzf: 0.42.0_5 -> 0.42.0_6
    harfbuzz-icu: 8.4.0_1 -> 8.5.0_1
    kf6-kauth: 6.1.0_1 -> 6.2.0
    kf6-kcompletion: 6.1.0 -> 6.2.0
    kf6-kdesu: 6.1.0 -> 6.2.0
    kf6-kdoctools: 6.1.0 -> 6.2.0
    kf6-kfilemetadata: 6.1.0 -> 6.2.0
    kf6-kglobalaccel: 6.1.0 -> 6.2.0
    kf6-kidletime: 6.1.0 -> 6.2.0
    kf6-kjobwidgets: 6.1.0 -> 6.2.0
    kf6-kquickcharts: 6.1.0 -> 6.2.0
    kf6-prison: 6.1.0 -> 6.2.0
    kf6-solid: 6.1.1 -> 6.2.0
    kf6-sonnet: 6.1.0 -> 6.2.0
    kf6-syntax-highlighting: 6.1.0 -> 6.2.0
    llvm16: 16.0.6_10 -> 16.0.6_11
    mako: 1.8.0_1 -> 1.9.0
    mesa-gallium-xa: 24.0.6 -> 24.0.7
    mizuma: 2024.01 -> 2024.04
    noto-basic: 2.0_3 -> 2.0_4
    obfs4proxy-tor: 0.0.14_13 -> 0.0.14_14
    php82-ctype: 8.2.18 -> 8.2.19
    php82-filter: 8.2.18 -> 8.2.19
    php82-mysqli: 8.2.18 -> 8.2.19
    php82-opcache: 8.2.18 -> 8.2.19
    php82-pdo_mysql: 8.2.18 -> 8.2.19
    php82-session: 8.2.18 -> 8.2.19
    php82-sqlite3: 8.2.18 -> 8.2.19
    php82-tokenizer: 8.2.18 -> 8.2.19
    php82-xmlreader: 8.2.18 -> 8.2.19
    php82-xmlwriter: 8.2.18 -> 8.2.19
    php82-zip: 8.2.18 -> 8.2.19
    php82-zlib: 8.2.18 -> 8.2.19
    pipewire: 1.0.4 -> 1.0.4_2
    postgresql15-client: 15.6 -> 15.7
    py39-gdbm: 3.9.18_7 -> 3.9.19_7
    py39-opt-einsum: 3.3.0_1 -> 3.3.0_2
    py39-socksio: 1.0.0 -> 1.0.0_1
    py39-sphinx-basic-ng: 1.0.0b2 -> 1.0.0b2_1
    py39-wrapt: 1.16.0 -> 1.16.0_1
    restic: 0.16.4_5 -> 0.16.4_6
    ripgrep: 14.1.0_1 -> 14.1.0_2
    ripgrep-all: 0.9.6_26 -> 0.9.6_27
    rust-cbindgen: 0.26.0_5 -> 0.26.0_6
    spidermonkey102: 102.4.0_17 -> 102.4.0_18
    wlr-which-key: 0.1.3_1 -> 0.1.3_2

Installed packages to be REINSTALLED:
    schilybase-2024.03.21

Number of packages to be upgraded: 54
Number of packages to be reinstalled: 1

The process will require 15 MiB more space.

Proceed with this action? [y/N]: y
[1/55] Upgrading dnscrypt-proxy2 from 2.1.5_5 to 2.1.5_6...
===> Creating groups
Using existing group '_dnscrypt-proxy'
===> Creating users
Creating user '_dnscrypt-proxy' with uid '978'
pwd_mkdb: warning, unknown root shell
pwd_mkdb: warning, unknown root shell
pw: user '_dnscrypt-proxy' disappeared during update
pkg: PRE-INSTALL script failed
 
Solution :

Code:
[mario@marietto /home/marietto]==> /usr/sbin/pwd_mkdb -p /etc/master.passwd
pwd_mkdb: warning, unknown root shell
 
The consequence of the previous command is that the user and root password previoulsy configured by me aren't accepted anymore.
 
pwd_mkdb: warning, unknown root shell

pkg upgrade as well as pwd_mkdb are supposed to be run as root. That's what those errors already tried to tell you.
I don't know what kind of shell/login you are using as ==> is not a valid/default shell prompt, but according to the "mario@marietto" at the beginning of the prompt you are not root nor are you using doas/sudo (or not giving the full commands you entered).

Usually you never need to run pwd_mkdb *except* if you directly modified /usr/passwd with an editor instead of using vipw(8) or any other frontend for user manipulation (passwd, pw).
 
Yes,I ran that command as root. But I removed the word root from the command because I don't like to see it all around the forum. At the moment I went on single user mode because I wanted to set a new root password,but I've got the following error :

Code:
Cannot read termcap database;
using dumb terminal settings.

and I can't issue any command. find does not work,passwd does not work...
I'm using zsh...on single user mode I tried to give the path of zsh,that's /usr/local/bin/zsh,but it says that it can't find it...it can't find any executable that I try to run...please help.
 
Sure. In single user mode,it is the default choice. It is accepted,but then every command I type,it says that it can't find the executable.
 
The solution that I found to fix this problem has been to replace this file : spwd.db with an old and similar version of the same file.
 
dont know if this helps

when i was setting up a ubuntu jail i did the following

switch to root

Code:
su

make sure the passwd file is correct and contains your user

Code:
cd /etc
cat passwd | sed -r 's/(:[x|*]:)([0-9]+:[0-9]+:)/:*:\2:0:0:/g' > master.passwd
pwd_mkdb -d ./ -p master.passwd
 
Back
Top