twpayne / chezmoi

Manage your dotfiles across multiple diverse machines, securely.
https://www.chezmoi.io/
MIT License
12.85k stars 477 forks source link

Hangs on most commands #2906

Closed MathieuMoalic closed 1 year ago

MathieuMoalic commented 1 year ago

Describe the bug

chezmoi hangs on most commands.

chezmoi init --apply git@github.com:mathieumoalic/dotfiles.git --verbose --debug : hangs chezmoi init: works chezmoi add .config/file: hangs

Also ^C doesn't stop the process when it hangs. I must kill the terminal.

To reproduce

chezmoi init --apply git@github.com:mathieumoalic/dotfiles.git --verbose --debug

Expected behavior

Anything happens

Output of command with the --verbose flag

$ chezmoi --verbose $COMMAND
nothing

Output of chezmoi doctor

```console $ chezmoi doctor RESULT CHECK MESSAGE ok version v2.33.0, commit ced12b81b493670520b177dcc62de2c67172858d, built at 2023-03-24T01:29:01Z, built by goreleaser ok latest-version v2.33.0 ok os-arch linux/amd64 (CentOS Linux 7 (Core)) ok uname --------------------- 3.10.0-1160.81.1.el7.x86_64 #1 SMP Fri Dec 16 17:29:43 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux ok go-version go1.20.2 (gc) ok executable ~/.local/bin/chezmoi ok upgrade-method replace-executable ok config-file no config file found ok source-dir ~/.local/share/chezmoi is a git working tree (clean) ok suspicious-entries no suspicious entries ok working-tree ~/.local/share/chezmoi is a git working tree (clean) ok dest-dir ~ is a directory ok umask 022 ok cd-command found ~/.local/bin/zsh ok cd-args ~/.local/bin/zsh info diff-command not set ok edit-command found /usr/bin/nano ok edit-args /usr/bin/nano ok git-command found ~/.local/share/conda/bin/git, version 2.34.1 ok merge-command found /usr/bin/vimdiff ok shell-command found ~/.local/bin/zsh ok shell-args ~/.local/bin/zsh info age-command age not found in $PATH ok gpg-command found /usr/bin/gpg, version 2.0.22 info pinentry-command not set info 1password-command op not found in $PATH info bitwarden-command bw not found in $PATH info dashlane-command dcli not found in $PATH info gopass-command gopass not found in $PATH info keepassxc-command keepassxc-cli not found in $PATH info keepassxc-db not set info keeper-command keeper not found in $PATH info lastpass-command lpass not found in $PATH info pass-command pass not found in $PATH info passhole-command ph not found in $PATH info rbw-command rbw not found in $PATH info vault-command vault not found in $PATH info secret-command not set ```

Output of chezmoi init

```console $ chezmoi init --apply git@github.com:mathieumoalic/dotfiles.git --verbose --debug 2023-04-03T11:34:58+02:00 INF persistentPreRunRootE args=["chezmoi","init","--apply","git@github.com:mathieumoalic/dotfiles.git","--verbose","--debug"] goVersion=go1.20.2 version={"builtBy":"goreleaser","commit":"ced12b81b493670520b177dcc62de2c67172858d","date":"2023-03-24T01:29:01Z","version":"2.33.0"} 2023-04-03T11:34:58+02:00 ERR Stat error="stat /home/users/mathieum/.config/chezmoi/chezmoistate.boltdb: no such file or directory" component=system name=/home/users/mathieum/.config/chezmoi/chezmoistate.boltdb 2023-04-03T11:34:58+02:00 INF Mkdir component=system name=/home/users/mathieum/.local/share/chezmoi perm=511 2023-04-03T11:34:58+02:00 ERR Mkdir error="mkdir /run/user/2203: file exists" component=system name=/run/user/2203 perm=448 2023-04-03T11:34:58+02:00 INF Stat component=system name=/run/user/2203 2023-04-03T11:34:58+02:00 ERR Stat error="stat /home/users/mathieum/.local/share/chezmoi/.git: no such file or directory" component=system name=/home/users/mathieum/.local/share/chezmoi/.git 2023-04-03T11:34:58+02:00 ERR Stat error="stat /home/users/mathieum/.local/share/.git: no such file or directory" component=system name=/home/users/mathieum/.local/share/.git 2023-04-03T11:34:58+02:00 ERR Stat error="stat /home/users/mathieum/.local/.git: no such file or directory" component=system name=/home/users/mathieum/.local/.git 2023-04-03T11:34:58+02:00 ERR Mkdir error="mkdir /home/users/mathieum/.local/share/chezmoi: file exists" component=system name=/home/users/mathieum/.local/share/chezmoi perm=511 2023-04-03T11:34:58+02:00 INF Stat component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:34:58+02:00 ERR ReadFile error="open /home/users/mathieum/.local/share/chezmoi/.chezmoiroot: no such file or directory" component=system data= name=/home/users/mathieum/.local/share/chezmoi/.chezmoiroot size=0 2023-04-03T11:34:58+02:00 ERR Stat error="stat /home/users/mathieum/.local/share/chezmoi/.git: no such file or directory" component=system name=/home/users/mathieum/.local/share/chezmoi/.git Cloning into '/home/users/mathieum/.local/share/chezmoi'... remote: Enumerating objects: 758, done. remote: Counting objects: 100% (758/758), done. remote: Compressing objects: 100% (380/380), done. remote: Total 758 (delta 376), reused 728 (delta 346), pack-reused 0 Receiving objects: 100% (758/758), 3.77 MiB | 5.81 MiB/s, done. Resolving deltas: 100% (376/376), done. Updating files: 100% (609/609), done. 2023-04-03T11:35:04+02:00 INF Run args=["git","clone","--recurse-submodules","git@github.com:mathieumoalic/dotfiles.git","/home/users/mathieum/.local/share/chezmoi"] duration=5.967919806s env=["XDG_SESSION_ID=95226","HOSTNAME=eagle.man.poznan.pl","TERM=xterm-256color","SHELL=/home/users/mathieum/.local/bin/zsh","HISTSIZE=100000","SSH_CLIENT=150.254.109.161 60048 22","ZDOTDIR=/home/users/mathieum/.config/zsh","SSH_TTY=/dev/pts/105","USER=mathieum","LS_COLORS=","MAIL=/var/spool/mail/mathieum","PATH=/home/users/mathieum/.local/bin/scripts:/home/users/mathieum/.local/bin:/home/users/mathieum/.local/share/cargo/bin:/home/users/mathieum/grant_398/scratch/bin:/home/users/mathieum/.local/share/conda/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/usr/local/go/bin","PWD=/home/users/mathieum","LANG=en_US.UTF-8","MODULEPATH=/usr/share/Modules/modulefiles/local/${ARCH}","LOADEDMODULES=","HISTCONTROL=ignoredups","SHLVL=1","HOME=/home/users/mathieum","LOGNAME=mathieum","SSH_CONNECTION=150.254.109.161 60048 150.254.160.193 22","MODULESHOME=/usr/share/Modules","SLURM_TIME_FORMAT=%H:%M:%S","LESSOPEN=||/usr/bin/lesspipe.sh %s","ARCH=skylake","XDG_RUNTIME_DIR=/run/user/2203","BASH_FUNC_module()=() { eval `/usr/bin/modulecmd bash $*`\n}","OLDPWD=/home/users/mathieum","EDITOR=nano","VISUAL=nano","SUDO_EDIT=nano","XDG_DATA_HOME=/home/users/mathieum/.local/share","XDG_CONFIG_HOME=/home/users/mathieum/.config","XDG_STATE_HOME=/home/users/mathieum/.local/state","XDG_CACHE_HOME=/home/users/mathieum/.cache","ERRFILE=/home/users/mathieum/.cache/X11/xsession-errors","USERXSESSION=/home/users/mathieum/.cache/X11/xsession","USERXSESSIONRC=/home/users/mathieum/.cache/X11/xsessionrc","ALTUSERXSESSION=/home/users/mathieum/.cache/X11/Xsession","GNUPGHOME=/home/users/mathieum/.local/share/gnupg","GTK2_RC_FILES=/home/users/mathieum/.config/gtk-2.0/gtkrc","JUPYTER_CONFIG_DIR=/home/users/mathieum/.config/jupyter","LESSHISTFILE=/home/users/mathieum/.cache/less/history","_Z_DATA=/home/users/mathieum/.local/share/z","ZSH_COMPDUMP=/cache/.zcompdump-eagle.man.poznan.pl","RUSTUP_HOME=/home/users/mathieum/.local/share/rust","CARGO_HOME=/home/users/mathieum/.local/share/cargo","CUDA_CACHE_PATH=/home/users/mathieum/.cache/nv","GOPATH=/home/users/mathieum/.local/share/go","STARSHIP_SHELL=zsh","STARSHIP_SESSION_KEY=1044722290151832","LESS_TERMCAP_mb=\u001b[01;32m","LESS_TERMCAP_md=\u001b[01;32m","LESS_TERMCAP_me=\u001b[0m","LESS_TERMCAP_se=\u001b[0m","LESS_TERMCAP_so=\u001b[01;47;34m","LESS_TERMCAP_ue=\u001b[0m","LESS_TERMCAP_us=\u001b[01;36m","LESS=-r","_=/home/users/mathieum/.local/bin/chezmoi","CHEZMOI=1","CHEZMOI_COMMAND=init","CHEZMOI_CONFIG_FILE=/home/users/mathieum/.config/chezmoi/chezmoi.toml","CHEZMOI_SOURCE_DIR=/home/users/mathieum/.local/share/chezmoi","CHEZMOI_CACHE_DIR=/home/users/mathieum/.cache/chezmoi","CHEZMOI_HOSTNAME=eagle","CHEZMOI_UID=2203","CHEZMOI_WORKING_TREE=/home/users/mathieum/.local/share/chezmoi","CHEZMOI_GROUP=users","CHEZMOI_HOME_DIR=/home/users/mathieum","CHEZMOI_OS=linux","CHEZMOI_USERNAME=mathieum","CHEZMOI_ARCH=amd64","CHEZMOI_ARGS=chezmoi init --apply git@github.com:mathieumoalic/dotfiles.git --verbose --debug","CHEZMOI_EXECUTABLE=/home/users/mathieum/.local/bin/chezmoi","CHEZMOI_FQDN_HOSTNAME=eagle.man.poznan.pl","CHEZMOI_GID=100","CHEZMOI_VERBOSE=1","CHEZMOI_KERNEL_OSRELEASE=3.10.0-1160.81.1.el7.x86_64","CHEZMOI_KERNEL_OSTYPE=Linux","CHEZMOI_KERNEL_VERSION=#1 SMP Fri Dec 16 17:29:43 UTC 2022","CHEZMOI_OS_RELEASE_PRETTY_NAME=CentOS Linux 7 (Core)","CHEZMOI_OS_RELEASE_REDHAT_SUPPORT_PRODUCT_VERSION=7","CHEZMOI_OS_RELEASE_ID=centos","CHEZMOI_OS_RELEASE_ID_LIKE=rhel fedora","CHEZMOI_OS_RELEASE_CPE_NAME=cpe:/o:centos:centos:7","CHEZMOI_OS_RELEASE_VERSION=7 (Core)","CHEZMOI_OS_RELEASE_ANSI_COLOR=0;31","CHEZMOI_OS_RELEASE_BUG_REPORT_URL=https://bugs.centos.org/","CHEZMOI_OS_RELEASE_CENTOS_MANTISBT_PROJECT_VERSION=7","CHEZMOI_OS_RELEASE_VERSION_ID=7","CHEZMOI_OS_RELEASE_REDHAT_SUPPORT_PRODUCT=centos","CHEZMOI_OS_RELEASE_HOME_URL=https://www.centos.org/","CHEZMOI_OS_RELEASE_CENTOS_MANTISBT_PROJECT=CentOS-7","CHEZMOI_OS_RELEASE_NAME=CentOS Linux","CHEZMOI_VERSION_COMMIT=ced12b81b493670520b177dcc62de2c67172858d","CHEZMOI_VERSION_DATE=2023-03-24T01:29:01Z","CHEZMOI_VERSION_VERSION=2.33.0","CHEZMOI_VERSION_BUILT_BY=goreleaser"] path=/home/users/mathieum/.local/share/conda/bin/git 2023-04-03T11:35:04+02:00 INF RunCmd args=["git","clone","--recurse-submodules","git@github.com:mathieumoalic/dotfiles.git","/home/users/mathieum/.local/share/chezmoi"] component=system env=["XDG_SESSION_ID=95226","HOSTNAME=eagle.man.poznan.pl","TERM=xterm-256color","SHELL=/home/users/mathieum/.local/bin/zsh","HISTSIZE=100000","SSH_CLIENT=150.254.109.161 60048 22","ZDOTDIR=/home/users/mathieum/.config/zsh","SSH_TTY=/dev/pts/105","USER=mathieum","LS_COLORS=","MAIL=/var/spool/mail/mathieum","PATH=/home/users/mathieum/.local/bin/scripts:/home/users/mathieum/.local/bin:/home/users/mathieum/.local/share/cargo/bin:/home/users/mathieum/grant_398/scratch/bin:/home/users/mathieum/.local/share/conda/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/usr/local/go/bin","PWD=/home/users/mathieum","LANG=en_US.UTF-8","MODULEPATH=/usr/share/Modules/modulefiles/local/${ARCH}","LOADEDMODULES=","HISTCONTROL=ignoredups","SHLVL=1","HOME=/home/users/mathieum","LOGNAME=mathieum","SSH_CONNECTION=150.254.109.161 60048 150.254.160.193 22","MODULESHOME=/usr/share/Modules","SLURM_TIME_FORMAT=%H:%M:%S","LESSOPEN=||/usr/bin/lesspipe.sh %s","ARCH=skylake","XDG_RUNTIME_DIR=/run/user/2203","BASH_FUNC_module()=() { eval `/usr/bin/modulecmd bash $*`\n}","OLDPWD=/home/users/mathieum","EDITOR=nano","VISUAL=nano","SUDO_EDIT=nano","XDG_DATA_HOME=/home/users/mathieum/.local/share","XDG_CONFIG_HOME=/home/users/mathieum/.config","XDG_STATE_HOME=/home/users/mathieum/.local/state","XDG_CACHE_HOME=/home/users/mathieum/.cache","ERRFILE=/home/users/mathieum/.cache/X11/xsession-errors","USERXSESSION=/home/users/mathieum/.cache/X11/xsession","USERXSESSIONRC=/home/users/mathieum/.cache/X11/xsessionrc","ALTUSERXSESSION=/home/users/mathieum/.cache/X11/Xsession","GNUPGHOME=/home/users/mathieum/.local/share/gnupg","GTK2_RC_FILES=/home/users/mathieum/.config/gtk-2.0/gtkrc","JUPYTER_CONFIG_DIR=/home/users/mathieum/.config/jupyter","LESSHISTFILE=/home/users/mathieum/.cache/less/history","_Z_DATA=/home/users/mathieum/.local/share/z","ZSH_COMPDUMP=/cache/.zcompdump-eagle.man.poznan.pl","RUSTUP_HOME=/home/users/mathieum/.local/share/rust","CARGO_HOME=/home/users/mathieum/.local/share/cargo","CUDA_CACHE_PATH=/home/users/mathieum/.cache/nv","GOPATH=/home/users/mathieum/.local/share/go","STARSHIP_SHELL=zsh","STARSHIP_SESSION_KEY=1044722290151832","LESS_TERMCAP_mb=\u001b[01;32m","LESS_TERMCAP_md=\u001b[01;32m","LESS_TERMCAP_me=\u001b[0m","LESS_TERMCAP_se=\u001b[0m","LESS_TERMCAP_so=\u001b[01;47;34m","LESS_TERMCAP_ue=\u001b[0m","LESS_TERMCAP_us=\u001b[01;36m","LESS=-r","_=/home/users/mathieum/.local/bin/chezmoi","CHEZMOI=1","CHEZMOI_COMMAND=init","CHEZMOI_CONFIG_FILE=/home/users/mathieum/.config/chezmoi/chezmoi.toml","CHEZMOI_SOURCE_DIR=/home/users/mathieum/.local/share/chezmoi","CHEZMOI_CACHE_DIR=/home/users/mathieum/.cache/chezmoi","CHEZMOI_HOSTNAME=eagle","CHEZMOI_UID=2203","CHEZMOI_WORKING_TREE=/home/users/mathieum/.local/share/chezmoi","CHEZMOI_GROUP=users","CHEZMOI_HOME_DIR=/home/users/mathieum","CHEZMOI_OS=linux","CHEZMOI_USERNAME=mathieum","CHEZMOI_ARCH=amd64","CHEZMOI_ARGS=chezmoi init --apply git@github.com:mathieumoalic/dotfiles.git --verbose --debug","CHEZMOI_EXECUTABLE=/home/users/mathieum/.local/bin/chezmoi","CHEZMOI_FQDN_HOSTNAME=eagle.man.poznan.pl","CHEZMOI_GID=100","CHEZMOI_VERBOSE=1","CHEZMOI_KERNEL_OSRELEASE=3.10.0-1160.81.1.el7.x86_64","CHEZMOI_KERNEL_OSTYPE=Linux","CHEZMOI_KERNEL_VERSION=#1 SMP Fri Dec 16 17:29:43 UTC 2022","CHEZMOI_OS_RELEASE_PRETTY_NAME=CentOS Linux 7 (Core)","CHEZMOI_OS_RELEASE_REDHAT_SUPPORT_PRODUCT_VERSION=7","CHEZMOI_OS_RELEASE_ID=centos","CHEZMOI_OS_RELEASE_ID_LIKE=rhel fedora","CHEZMOI_OS_RELEASE_CPE_NAME=cpe:/o:centos:centos:7","CHEZMOI_OS_RELEASE_VERSION=7 (Core)","CHEZMOI_OS_RELEASE_ANSI_COLOR=0;31","CHEZMOI_OS_RELEASE_BUG_REPORT_URL=https://bugs.centos.org/","CHEZMOI_OS_RELEASE_CENTOS_MANTISBT_PROJECT_VERSION=7","CHEZMOI_OS_RELEASE_VERSION_ID=7","CHEZMOI_OS_RELEASE_REDHAT_SUPPORT_PRODUCT=centos","CHEZMOI_OS_RELEASE_HOME_URL=https://www.centos.org/","CHEZMOI_OS_RELEASE_CENTOS_MANTISBT_PROJECT=CentOS-7","CHEZMOI_OS_RELEASE_NAME=CentOS Linux","CHEZMOI_VERSION_COMMIT=ced12b81b493670520b177dcc62de2c67172858d","CHEZMOI_VERSION_DATE=2023-03-24T01:29:01Z","CHEZMOI_VERSION_VERSION=2.33.0","CHEZMOI_VERSION_BUILT_BY=goreleaser"] path=/home/users/mathieum/.local/share/conda/bin/git 2023-04-03T11:35:04+02:00 ERR ReadFile error="open /home/users/mathieum/.local/share/chezmoi/.chezmoiversion: no such file or directory" component=system data= name=/home/users/mathieum/.local/share/chezmoi/.chezmoiversion size=0 2023-04-03T11:35:04+02:00 ERR ReadFile error="open /home/users/mathieum/.local/share/chezmoi/.chezmoiroot: no such file or directory" component=system data= name=/home/users/mathieum/.local/share/chezmoi/.chezmoiroot size=0 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:35:04+02:00 INF Delete bucket=configState component=persistentState key=configState 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:35:04+02:00 INF Get bucket=configState component=persistentState key=configState value= 2023-04-03T11:35:04+02:00 ERR ReadFile error="open /home/users/mathieum/.local/share/chezmoi/.chezmoiversion: no such file or directory" component=system data= name=/home/users/mathieum/.local/share/chezmoi/.chezmoiversion size=0 2023-04-03T11:35:04+02:00 INF Stat component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:35:04+02:00 INF Stat component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi 2023-04-03T11:35:04+02:00 INF ReadFile component=system data="history.txt\n*zwc\nstate.yml\n.zcompdump\ngtk/.config/gtk-3.0/bookma..." name=/home/users/mathieum/.local/share/chezmoi/.chezmoiignore size=194 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/VSCodium 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/VSCodium/User 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/alacritty 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/broot 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/broot/launcher 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/btop 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/dunst 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/git 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/git/info 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/helix 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/helix/themes 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/hypr 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/i3 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/lazydocker 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/lazygit 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/nushell 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/paru 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/picom 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/polybar 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/rofi 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/sway 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/swaylock 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-autoreload 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-autoreload/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-continuum 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-continuum/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-continuum/scripts/handle_tmux_automatic_start 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-dracula 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-dracula/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect/lib 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect/lib/tmux-test 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect/save_command_strategies 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-resurrect/strategies 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-sensible 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-yank 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tmux-yank/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tpm 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tpm/bin 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tpm/bindings 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tpm/scripts 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/tmux/plugins/tpm/scripts/helpers 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/waybar 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-autosuggestions 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-autosuggestions/src 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-autosuggestions/src/strategies 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-completions 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-completions/src 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/brackets 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/brackets/test-data 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/cursor 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/line 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/main 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/main/test-data 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/pattern 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/pattern/test-data 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/regexp 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/regexp/test-data 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_config/zsh/plugins/zsh-syntax-highlighting/highlighters/root 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/dot_ssh 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/private_dot_cache 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/private_dot_local 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/private_dot_local/bin 2023-04-03T11:35:04+02:00 INF ReadDir component=system name=/home/users/mathieum/.local/share/chezmoi/private_dot_local/bin/scripts 2023-04-03T11:35:04+02:00 INF Lstat component=system name=/home/users/mathieum/.cache 2023-04-03T11:35:04+02:00 INF Get bucket=entryState component=persistentState key=/home/users/mathieum/.cache value= 2023-04-03T11:35:04+02:00 INF defaultPreApplyFunc actualEntryState={"ContentsSHA256":"","Mode":2147484141,"Type":"dir"} lastWrittenEntryState={} targetEntryState={"ContentsSHA256":"","Mode":2147484096,"Type":"dir"} targetRelPath=.cache 2023-04-03T11:35:04+02:00 INF Stat component=system name=/home/users/mathieum/.cache 2023-04-03T11:35:04+02:00 INF Lstat component=system name=/home/users/mathieum/.cache diff --git a/.cache b/.cache old mode 40755 new mode 40700 2023-04-03T11:35:04+02:00 INF Chmod component=system mode=448 name=/home/users/mathieum/.cache 2023-04-03T11:35:04+02:00 INF Mkdir component=system name=/home/users/mathieum/.config/chezmoi perm=511 ```

Additional context

I'm running this on an HPC with no admin privileges and 10 years old system libs.

The debug info does not help as it only mentions operations that worked: The last line 2023-04-03T11:35:04+02:00 INF Mkdir component=system name=/home/users/mathieum/.config/chezmoi perm=511 actually makes the directory succesfully but I have no idea what comes next.

twpayne commented 1 year ago

chezmoi hangs on most commands.

chezmo is used by tens of thousands of people where it does not hang on most commands. The problems here are almost certainly due to a problem with your machine and are not a bug in chezmoi.

Also ^C doesn't stop the process when it hangs. I must kill the terminal.

This means that chezmoi is getting stuck in uninterruptible sleep. This is typically due to I/O problems on your machine.

To debug this, try running chezmoi with strace, which may help you find out which system call is causing the uninterruptible sleep.

MathieuMoalic commented 1 year ago

ah I didn't know strace to debug executables before. This is interesting. There seems to be someting wrong here indeed.

13:57:45 write(2, "\33[90m2023-04-05T13:57:45+02:00\33["..., 1492023-04-05T13:57:45+02:00 INF Mkdir component=system name=/home/users/mathieum/.config/chezmoi perm=511
) = 149
13:57:45 openat(AT_FDCWD, "/home/users/mathieum/.config/chezmoi/chezmoistate.boltdb", O_RDWR|O_CREAT|O_CLOEXEC, 0600) = 3
13:57:45 fcntl(3, F_GETFL)              = 0x8002 (flags O_RDWR|O_LARGEFILE)
13:57:45 fcntl(3, F_SETFL, O_RDWR|O_NONBLOCK|O_LARGEFILE) = 0
13:57:45 epoll_ctl(4, EPOLL_CTL_ADD, 3, {EPOLLIN|EPOLLOUT|EPOLLRDHUP|EPOLLET, {u32=2485757272, u64=140293297513816}}) = -1 EPERM (Operation not permitted)
13:57:45 fcntl(3, F_GETFL)              = 0x8802 (flags O_RDWR|O_NONBLOCK|O_LARGEFILE)
13:57:45 fcntl(3, F_SETFL, O_RDWR|O_LARGEFILE) = 0
13:57:45 flock(3, LOCK_EX|LOCK_N

From this trace, I can roughly guess that chezmoi can't open ~/.config/chezmoi/chezmoistate.boltdb ? I can interact with this file just fine though. It's more of a boltDB issue than a chezmoi issue, would you agree ?

twpayne commented 1 year ago

Thank you for the investigation. What's happening here is that chezmoi stores its persistent state in a BoltDB database, and the system call to lock the database file is hanging.

BoltDB, like most (all?) databases, requires file locking to ensure database consistency. Some filesystems do not support file locking. This is not really a BoltDB issue, more of a "your filesystem lacks a critical feature" issue.

What's the output of mount for the filesystem containing your home directory?

I'm considering adding a simple persistent state backend that does not require file locking, which would also help chezmoi run on a wider range of systems.

twpayne commented 1 year ago

(Incidentally, my initial guess would be that your home directory is on a NFS partition and NFS file locking has not been configured)

MathieuMoalic commented 1 year ago

You are spot on! From the mount command I learn that the home directory is using GPFS if I'm not wrong. I guess it doesn't support file locking as you mentionned. With this information I used chezmoi with the --persistent-state flag to change the db location to another filesystem and it works! Thanks for helping me :)