Eu instalei originalmente o pacote LAMP na instalação do servidor. Levou-me idades para obter o servidor web para trabalhar e, em seguida, descobri que o PHP não tinha sido instalado como parte do pacote, que é estranho como deveria ter sido. Eu também tentei instalar o servidor SSH para que eu pudesse efetuar login usando o Putty. Toda vez que tento instalar qualquer coisa eu recebo o seguinte: -
jim@Unseen:~$ sudo apt-get -f install php libapache2-mod-php php-mcrypt php-mysq
l
Reading package lists... Done
Building dependency tree
Reading state information... Done
libapache2-mod-php is already the newest version (1:7.0+35ubuntu6.1).
php-mysql is already the newest version (1:7.0+35ubuntu6.1).
The following additional packages will be installed:
libmcrypt4 php7.0 php7.0-mcrypt
Suggested packages:
libmcrypt-dev mcrypt
The following NEW packages will be installed
libmcrypt4 php php-mcrypt php7.0 php7.0-mcrypt
0 to upgrade, 5 to newly install, 0 to remove and 0 not to upgrade.
Need to get 0 B/83.5 kB of archives.
After this operation, 326 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
E: Waited for /usr/sbin/dpkg-preconfigure --apt || true but it wasn't there
E: Failure running script /usr/sbin/dpkg-preconfigure --apt || true
Eu tentei o apt-get clean. Eu tentei o padrão apt-get. Eu corri o apt-get update. Nada que eu tente parece funcionar. Alguém pode sugerir alguma coisa para me ajudar por favor. Eu sou novo no Ubuntu e ficar muito frustrado com isso. Agradecemos antecipadamente
Editar:
Eu tentei a correção sugerida em um post semelhante que se refere a 14.0 *, embora meu servidor seja 16.04.4: -
sudo sh -c "echo 'DPkg::Pre-Install-Pkgs {"/usr/sbin/dpkg-preconfigure --apt || true";};' >> /etc/apt/apt.conf.d/70debconf"
Isso não funcionou e relatou que o 70debconf não existia.
Editar 2
Eu corrigi a string de comando como sugerido para: -
sudo sh -c "echo 'DPkg::Pre-Install-Pkgs {\"/usr/sbin/dpkg-preconf
igure --apt || true\";};' >> /etc/apt/apt.conf.d/70debconf"
Ele retornou um prompt sem mensagens, então presumo que funcionou
Eu então executei o seguinte: -
sudo apt-get install openssh-server
E retornou exatamente como antes: -
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
ncurses-term openssh-sftp-server python3-requests python3-urllib3
ssh-import-id
Suggested packages:
ssh-askpass rssh molly-guard monkeysphere python3-ndg-httpsclient
python3-openssl python3-pyasn1
The following NEW packages will be installed
ncurses-term openssh-server openssh-sftp-server python3-requests
python3-urllib3 ssh-import-id
0 to upgrade, 6 to newly install, 0 to remove and 0 not to upgrade.
Need to get 0 B/746 kB of archives.
After this operation, 5,652 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Preconfiguring packages ...
E: Waited for /usr/sbin/dpkg-preconfigure --apt || true but it wasn't there
E: Failure running script /usr/sbin/dpkg-preconfigure --apt || true
Editar 3
Um pensamento me ocorreu depois de uma ajuda fantástica. Antes de começar este problema, instalei o Webmin como uma maneira rápida de acessar remotamente o servidor a partir do meu desktop. Tentei instalar o Openssh-server através do webmin e para minha surpresa funcionou. Portanto, a conclusão parece que o webmin interferiu de alguma forma nas funções nativas do servidor. Tenho certeza de que isso não deveria acontecer e me pergunto se devo denunciá-lo.