AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • Início
  • system&network
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • Início
  • system&network
    • Recentes
    • Highest score
    • tags
  • Ubuntu
    • Recentes
    • Highest score
    • tags
  • Unix
    • Recentes
    • tags
  • DBA
    • Recentes
    • tags
  • Computer
    • Recentes
    • tags
  • Coding
    • Recentes
    • tags
Início / computer / Perguntas / 1836288
Accepted
94230
94230
Asked: 2024-03-23 07:45:28 +0800 CST2024-03-23 07:45:28 +0800 CST 2024-03-23 07:45:28 +0800 CST

Existe uma maneira fácil de inicializar o Arch Linux usando o chef?

  • 772

Estou ciente de que o Arch Linux não é suportado pelo chef.io, mas existe alguma maneira de inicializar os nós do Arch Linux usando o Knife Bootstrap?

Tentei o mesmo comando que uso em máquinas Debian, mas recebo um erro:

knife bootstrap 10.2.128.80 --ssh-identity-file ~/.ssh/id_rsa --connection-user myUser -N webserver --environment staging --bootstrap-version 18 -y --sudo
Connecting to 10.2.128.80 using ssh
Connecting to 10.2.128.80 using ssh

DEBUG: [SSH] [email protected] cmd = cmd.exe /c ver
DEBUG: [SSH] [email protected] cmd = Get-WmiObject Win32_OperatingSystem | Select Caption,Version | ConvertTo-Json
DEBUG: [SSH] [email protected] cmd = uname -s
DEBUG: [SSH] [email protected] cmd = uname -m
DEBUG: [SSH] [email protected] cmd = test -f /etc/debian_version
DEBUG: [SSH] [email protected] cmd = test -f /etc/os-release && cat /etc/os-release
DEBUG: [SSH] [email protected] cmd = show version
DEBUG: [SSH] [email protected] cmd = test -f /etc/lsb-release && cat /etc/lsb-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/oracle-release && cat /etc/oracle-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/enterprise-release && cat /etc/enterprise-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/parallels-release && cat /etc/parallels-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/system-release && cat /etc/system-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/redhat-release && cat /etc/redhat-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/SuSE-release && cat /etc/SuSE-release
DEBUG: [SSH] [email protected] cmd = test -f /etc/arch-release
DEBUG: [SSH] [email protected] cmd = uname -r
DEBUG: [SSH] [email protected] cmd = sh -c '(sudo echo) < /dev/null'
DEBUG: [SSH] [email protected] cmd = sudo echo '[SSH] Established'
WARNING: Performing legacy client registration with the validation key at /home/myUser/.chef/org-validator.pem...
WARNING: Remove the key file or remove the 'validation_key' configuration option from your config.rb (knife.rb) to use more secure user credentials for client registration.
TRACE: Looking for bootstrap template in /opt/chef-workstation/embedded/lib/ruby/gems/3.1.0/gems/knife-18.2.7/lib/chef/knife/bootstrap/templates
TRACE: Found bootstrap template: /opt/chef-workstation/embedded/lib/ruby/gems/3.1.0/gems/knife-18.2.7/lib/chef/knife/bootstrap/templates/chef-full.erb
Bootstrapping 10.2.128.80
DEBUG: [SSH] [email protected] cmd = sudo sh /tmp/chef_T472LE/bootstrap.sh
 [10.2.128.80] -----> Installing Chef Omnibus (stable/18)
downloading https://omnitruck.chef.io/chef/install.sh
  to file /tmp/install.sh.32304/install.sh
 [10.2.128.80] trying wget...
 [10.2.128.80] "arch" "rolling" x86_64
 [10.2.128.80] Getting information for chef stable 18 for "arch"...
 [10.2.128.80] downloading https://omnitruck.chef.io/stable/chef/metadata?v=18&p="arch"&pv="rolling"&m=x86_64
  to file /tmp/install.sh.32308/metadata.txt
 [10.2.128.80] trying wget...
 [10.2.128.80] ERROR 404
 [10.2.128.80] Omnitruck artifact does not exist for version 18 on platform "arch"

Either this means:
   - We do not support "arch"
   - We do not have an artifact for 18

 [10.2.128.80] This is often the latter case due to running a prerelease or RC version of Chef
or a gem version which was only pushed to rubygems and not omnitruck.

You may be able to set your knife[:bootstrap_version] to the most recent stable
release of Chef to fix this problem (or the most recent stable major version number).

In order to test the version parameter, adventurous users may take the Metadata URL
 [10.2.128.80] below and modify the '&v=<number>' parameter until you successfully get a URL that
does not 404 (e.g. via curl or wget).  You should be able to use '&v=11' or '&v=12'
 [10.2.128.80] successfully.

 [10.2.128.80] If you cannot fix this problem by setting the bootstrap_version, it probably means
that "arch" is not supported.
 [10.2.128.80]
Metadata URL: https://omnitruck.chef.io/stable/chef/metadata?v=18&p="arch"&pv="rolling"&m=x86_64
 [10.2.128.80] Starting the first Chef Infra Client Client run...
 [10.2.128.80] /tmp/chef_T472LE/bootstrap.sh: line 364: chef-client: command not found
ERROR: The following error occurred on 10.2.128.80:
ERROR: -----> Installing Chef Omnibus (stable/18)
     downloading https://omnitruck.chef.io/chef/install.sh
       to file /tmp/install.sh.32304/install.sh
     trying wget...
     "arch" "rolling" x86_64
     Getting information for chef stable 18 for "arch"...
     downloading https://omnitruck.chef.io/stable/chef/metadata?v=18&p="arch"&pv="rolling"&m=x86_64
       to file /tmp/install.sh.32308/metadata.txt
     trying wget...
     ERROR 404
     Omnitruck artifact does not exist for version 18 on platform "arch"

     Either this means:
        - We do not support "arch"
        - We do not have an artifact for 18

     This is often the latter case due to running a prerelease or RC version of Chef
     or a gem version which was only pushed to rubygems and not omnitruck.

     You may be able to set your knife[:bootstrap_version] to the most recent stable
     release of Chef to fix this problem (or the most recent stable major version number).

     In order to test the version parameter, adventurous users may take the Metadata URL
     below and modify the '&v=<number>' parameter until you successfully get a URL that
     does not 404 (e.g. via curl or wget).  You should be able to use '&v=11' or '&v=12'
     successfully.

     If you cannot fix this problem by setting the bootstrap_version, it probably means
     that "arch" is not supported.

     Metadata URL: https://omnitruck.chef.io/stable/chef/metadata?v=18&p="arch"&pv="rolling"&m=x86_64
     Starting the first Chef Infra Client Client run...
      /tmp/chef_T472LE/bootstrap.sh: line 364: chef-client: command not found
DEBUG: [SSH] [email protected] cmd = sudo rm -f "/tmp/chef_T472LE/bootstrap.sh"

Entendo que, como o Arch Linux não é compatível, ele não encontrará o arquivo para download no seguinte URL .

Existe alguma maneira de fazê-lo pensar que é um sistema operacional compatível? Se pudesse baixar o arquivo para uma instalação do Debian, o resto da instalação ainda funcionaria?

arch-linux
  • 1 1 respostas
  • 32 Views

1 respostas

  • Voted
  1. Best Answer
    94230
    2024-03-24T05:35:51+08:002024-03-24T05:35:51+08:00

    Eu descobri como fazer isso.

    Basicamente, tudo que você precisa fazer é instalar o pacote chef-clientdo AUR usando o knife bootstrap --bootstrap-install-commandsinalizador

    Pessoalmente, na minha configuração não tenho outro usuário além do root, então uso este script :

    --bootstrap-install-command "curl -sSf https://repo.barata.pt/-/snippets/9/raw/master/bootstrap-arch.sh | sh"
    

    Não testei, mas algo assim deve funcionar se você se conectar à máquina como usuário com sudo sem senha configurada:

    pacman --noconfirm -S wget base-devel
    cd /tmp
    wget --no-verbose https://aur.archlinux.org/cgit/aur.git/snapshot/chef-client.tar.gz
    tar -xvf chef-client.tar.gz
    cd chef-client
    makepkg -si --noconfirm
    cd ..
    rm -rf chef-clien*
    

    Divulgação completa, o chef-clientpacote AUR está sendo mantido por mim

    • 0

relate perguntas

  • Manjaro: Faltam os primeiros segundos da "nova" fonte sonora

  • libinput não consegue detectar o touchpad

  • Não é possível criar um novo projeto após a atualização para o Android Studio 3.4. Antergos Linux baseado em Arch

  • Versão mais recente do Arch Linux que incluía AIF

  • Como consertar o MariaDB quando ele trava durante o desligamento (aguardando page_cleaner)?

Sidebar

Stats

  • Perguntas 205573
  • respostas 270741
  • best respostas 135370
  • utilizador 68524
  • Highest score
  • respostas
  • Marko Smith

    Como posso reduzir o consumo do processo `vmmem`?

    • 11 respostas
  • Marko Smith

    Baixar vídeo do Microsoft Stream

    • 4 respostas
  • Marko Smith

    O Google Chrome DevTools falhou ao analisar o SourceMap: chrome-extension

    • 6 respostas
  • Marko Smith

    O visualizador de fotos do Windows não pode ser executado porque não há memória suficiente?

    • 5 respostas
  • Marko Smith

    Como faço para ativar o WindowsXP agora que o suporte acabou?

    • 6 respostas
  • Marko Smith

    Área de trabalho remota congelando intermitentemente

    • 7 respostas
  • Marko Smith

    O que significa ter uma máscara de sub-rede /32?

    • 6 respostas
  • Marko Smith

    Ponteiro do mouse movendo-se nas teclas de seta pressionadas no Windows?

    • 1 respostas
  • Marko Smith

    O VirtualBox falha ao iniciar com VERR_NEM_VM_CREATE_FAILED

    • 8 respostas
  • Marko Smith

    Os aplicativos não aparecem nas configurações de privacidade da câmera e do microfone no MacBook

    • 5 respostas
  • Martin Hope
    Vickel O Firefox não permite mais colar no WhatsApp web? 2023-08-18 05:04:35 +0800 CST
  • Martin Hope
    Saaru Lindestøkke Por que os arquivos tar.xz são 15x menores ao usar a biblioteca tar do Python em comparação com o tar do macOS? 2021-03-14 09:37:48 +0800 CST
  • Martin Hope
    CiaranWelsh Como posso reduzir o consumo do processo `vmmem`? 2020-06-10 02:06:58 +0800 CST
  • Martin Hope
    Jim Pesquisa do Windows 10 não está carregando, mostrando janela em branco 2020-02-06 03:28:26 +0800 CST
  • Martin Hope
    andre_ss6 Área de trabalho remota congelando intermitentemente 2019-09-11 12:56:40 +0800 CST
  • Martin Hope
    Riley Carney Por que colocar um ponto após o URL remove as informações de login? 2019-08-06 10:59:24 +0800 CST
  • Martin Hope
    zdimension Ponteiro do mouse movendo-se nas teclas de seta pressionadas no Windows? 2019-08-04 06:39:57 +0800 CST
  • Martin Hope
    jonsca Todos os meus complementos do Firefox foram desativados repentinamente, como posso reativá-los? 2019-05-04 17:58:52 +0800 CST
  • Martin Hope
    MCK É possível criar um código QR usando texto? 2019-04-02 06:32:14 +0800 CST
  • Martin Hope
    SoniEx2 Altere o nome da ramificação padrão do git init 2019-04-01 06:16:56 +0800 CST

Hot tag

windows-10 linux windows microsoft-excel networking ubuntu worksheet-function bash command-line hard-drive

Explore

  • Início
  • Perguntas
    • Recentes
    • Highest score
  • tag
  • help

Footer

AskOverflow.Dev

About Us

  • About Us
  • Contact Us

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve