우분투 설치에서 종속성 오류


4

SSH 액세스 권한 만 있고 종속성 오류의 머리 또는 꼬리를 만들 수없는 우분투 서버에서 APT 설정을 수정하려고합니다.

sudo apt-get install -f을 실행하고 다음을 얻습니다.

Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
4 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up ssl-cert (1.0.23ubuntu2) ...
dpkg: error processing ssl-cert (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of postgresql-common:
 postgresql-common depends on ssl-cert (>= 1.0.11); however:
  Package ssl-cert is not configured yet.
dpkg: error processing postgresql-common (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
                                                                                                          dpkg: dependency problems prevent configuration of postgresql-8.4:
 postgresql-8.4 depends on postgresql-common (>= 104~); however:
  Package postgresql-common is not configured yet.
 postgresql-8.4 depends on ssl-cert; however:
  Package ssl-cert is not configured yet.
dpkg: error processing postgresql-8.4 (--configure):
 dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
                                                              dpkg: dependency problems prevent configuration of postgresql:
 postgresql depends on postgresql-8.4; however:
  Package postgresql-8.4 is not configured yet.
dpkg: error processing postgresql (--configure):
 dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
                                                              Errors were encountered while processing:
 ssl-cert
 postgresql-common
 postgresql-8.4
 postgresql
E: Sub-process /usr/bin/dpkg returned an error code (1)

이것이 정확히 무엇을 의미합니까?순환 의존성이 있습니까?

필요한 의존성 ssl-cert 설치를 시도했지만 작동하지 않습니다.

dpkg도 직접 사용할 수 없습니다.

이 문제를 해결하는 방법에 대한 팁이 있습니까? 아니면 누군가 문제를 더 잘 이해하도록 도와 줄 수 있습니까?제공해야하는 추가 정보가 있습니까?

===

수정 :
sudo sh -x /path/to/config.postinst configure을 실행하면 다음과 같은 결과가 나타납니다.

+ . /usr/share/debconf/confmodule
+ [ !  ]
+ PERL_DL_NONLAZY=1
+ export PERL_DL_NONLAZY
+ [  ]
+ exec /usr/share/debconf/frontend /var/lib/dpkg/info/ssl-cert.postinst configure

스크립트가 마지막 줄을 실행하지 못했음을 의미합니까?

sudo /usr/share/debconf/frontend /var/lib/dpkg/info/ssl-cert.postinst configure 실행은 자동으로 완료되지만 후속 echo $?1을 생성하여 오류가 발생했음을 나타냅니다.

파일 상단에 set -x을 추가 한 다음 sudo ... frontend ... configure 명령을 실행하면 다음 위치에서 실패합니다.

make-ssl-cert generate-default-snakeoil

set -x이 파일도 다음 위치에서 실패합니다 :

 openssl req -config /tmp/tmp.wPl6nkzKYm -new -x509 -days 3650 -nodes -out /etc/ssl/certs/ssl-cert-snakeoil.pem -keyout /etc/ssl/private/ssl-cert-snakeoil.key

ssl-cert0으로이 명령을 실행하면 다음이 제공됩니다.

Generating a 1024 bit RSA private key
.....................++++++
.......................++++++
writing new private key to '/etc/ssl/private/ssl-cert-snakeoil.key'
-----
problems making Certificate Request
53829:error:0D07A097:asn1 encoding routines:ASN1_mbstring_ncopy:string too long:a_mbstr.c:154:maxsize=64

OpenSSL에 익숙하지 않습니다.무슨 일이야?

(또한이 질문을 새 질문으로 분기해야합니까?이 질문의 범위를 초과 했습니까?)

3

I went around for a bit, and seems that your "Company name" is too long for openSSL. This is a bug. You should upgrade your system to precise or later to fix this.

Remove any blocking package and upgrade your system. That should fix the issue.


2

The key excerpt from the output is this error while running the post-installation script for the ssl-cert package:

Setting up ssl-cert (1.0.23ubuntu2) ...
dpkg: error processing ssl-cert (--configure):
subprocess installed post-installation script returned error exit status 1

All of the subsequent errors are a consequence of the failure to complete the installation of ssl-cert.

To find out exactly how the postinst script failed, run

sudo sh -x /var/lib/dpkg/info/ssl-cert.postinst configure

Once you manage to debug the root cause, run sudo apt-get install -f again.