Es gibt unter Umständen ein Problem beim Update mit dem Paket opsi-depotserver (4.0.4.2-1) auf Debian 6, wenn ein mysql-server auf dem System installiert ist:
Code: Alles auswählen
opsi-depotserver (4.0.4.2-1) wird eingerichtet ...
[...]
[5] [Dez 15 20:20:35] Disabling mysql backend and license management module: no customer in modules file (MySQL.py|441)
[5] [Dez 15 20:20:35] Creating base path: '/var/lib/opsi/config' (File.py|237)
[5] [Dez 15 20:20:35] Creating opsi base (SQL.py|391)
[5] [Dez 15 20:20:35] Configuring samba (opsi-setup|175)
[4] [Dez 15 20:20:35] Share opt_pcbin configuration found in '/etc/samba/smb.conf'. You should use opsi_depot_rw instead, if you need a writeable depot-Share. (opsi-setup|209)
[5] [Dez 15 20:20:35] Adding share [opsi_depot_rw] (opsi-setup|235)
[5] [Dez 15 20:20:35] Adding share [opsi_images] (opsi-setup|249)
[5] [Dez 15 20:20:35] Creating backup of /etc/samba/smb.conf (opsi-setup|292)
[5] [Dez 15 20:20:35] Writing new smb.conf (opsi-setup|295)
[5] [Dez 15 20:20:35] Reloading samba (opsi-setup|300)
[5] [Dez 15 20:20:36] Setting rights (opsi-setup|534)
[5] [Dez 15 20:20:36] Setting rights on directory '/etc/opsi' (opsi-setup|618)
[5] [Dez 15 20:20:37] Setting rights (opsi-setup|534)
[5] [Dez 15 20:20:37] Setting rights on directory '/tftpboot/linux' (opsi-setup|618)
dpkg: Fehler beim Bearbeiten von opsi-depotserver (--configure):
Unterprozess installiertes post-installation-Skript gab den Fehlerwert 1 zurück
configured to not write apport reports
Fehler traten auf beim Bearbeiten von:
opsi-depotserver
E: Sub-process /usr/bin/dpkg returned an error code (1)
Code: Alles auswählen
# dpkg --configure --pending
opsi-depotserver (4.0.4.2-1) wird eingerichtet ...
[4] [Dez 15 20:39:31] Failed to read opsi modules file '/etc/opsi/modules': Signature not found (Backend.py|376)
[5] [Dez 15 20:39:31] Disabling mysql backend and license management module: no customer in modules file (MySQL.py|441)
[5] [Dez 15 20:39:32] Creating base path: '/var/lib/opsi/config' (File.py|237)
[5] [Dez 15 20:39:32] Creating opsi base (SQL.py|391)
[4] [Dez 15 20:39:32] Failed to read opsi modules file '/etc/opsi/modules': Signature not found (Backend.py|376)
[5] [Dez 15 20:39:32] Disabling mysql backend and license management module: no customer in modules file (MySQL.py|441)
[5] [Dez 15 20:39:33] Creating base path: '/var/lib/opsi/config' (File.py|237)
[5] [Dez 15 20:39:33] Creating opsi base (SQL.py|391)
[5] [Dez 15 20:39:33] Configuring samba (opsi-setup|175)
[5] [Dez 15 20:39:34] Setting rights (opsi-setup|534)
[5] [Dez 15 20:39:34] Setting rights on directory '/etc/opsi' (opsi-setup|618)
[5] [Dez 15 20:39:34] Setting rights (opsi-setup|534)
[5] [Dez 15 20:39:35] Setting rights on directory '/tftpboot/linux' (opsi-setup|618)
dpkg: Fehler beim Bearbeiten von opsi-depotserver (--configure):
Unterprozess installiertes post-installation-Skript gab den Fehlerwert 1 zurück
Fehler traten auf beim Bearbeiten von:
opsi-depotserver
Code: Alles auswählen
/usr/bin/opsi-setup --set-rights /tftpboot || true
if [ -e "/etc/init.d/mysql" ];then
mysqlstate=$(/etc/init.d/mysql status | grep "start/running")
if [ "$mysqlstate" != "" -a "$mysqlbackend" != "" ]; then
/usr/bin/opsi-setup --update-mysql
fi
fi
Code: Alles auswählen
# mysqlstate=$(/etc/init.d/mysql status | grep "start/running") ; echo $?
1
Der Quick-Fix für mich war:
Code: Alles auswählen
# mv /etc/init.d/mysql /etc/init.d/mysql_
# dpkg --configure --pending
# mv /etc/init.d/mysql_ /etc/init.d/mysql
Wie auch immer, das Paket selbst müsste gefixt werden, und zwar mindestens so:
Code: Alles auswählen
# mysqlstate=$(/etc/init.d/mysql status | grep "start/running"||true) ; echo $?
0
## mysql läuft:
Code: Alles auswählen
# /etc/init.d/mysql status
/usr/bin/mysqladmin Ver 8.42 Distrib 5.1.72, for debian-linux-gnu on x86_64
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Server version 5.1.72-2
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /var/run/mysqld/mysqld.sock
Uptime: 2 days 12 hours 43 min 29 sec
Threads: 1 Questions: 11345 Slow queries: 0 Opens: 2889 Flush tables: 1 Open tables: 64 Queries per second avg: 0.51.
Code: Alles auswählen
# /etc/init.d/mysql status
MySQL is stopped..
Das Mysql-Update läuft übrigens nicht sauber durch, zumindest nicht hier. Ich habe keine Lizenz dafür und nutze mysql dementsprechend nicht,
aber hier sei Euch zumindest an dieser Stelle Bescheid gesagt:
Code: Alles auswählen
# opsi-setup --update-mysql
[5] [Dez 15 21:03:42] Connection to database 'opsi' on 'localhost' as user 'XremovedX' (opsi-setup|1192)
[2] [Dez 15 21:03:42] Traceback: (Logger.py|742)
[2] [Dez 15 21:03:42] line 3441 in '<module>' in file '/usr/bin/opsi-setup' (Logger.py|742)
[2] [Dez 15 21:03:42] line 3396 in 'main' in file '/usr/bin/opsi-setup' (Logger.py|742)
[2] [Dez 15 21:03:42] line 1201 in 'updateMySQLBackend' in file '/usr/bin/opsi-setup' (Logger.py|742)
[2] [Dez 15 21:03:42] line 395 in 'execute' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|742)
[2] [Dez 15 21:03:42] line 166 in 'execute' in file '/usr/lib/pymodules/python2.6/MySQLdb/cursors.py' (Logger.py|742)
[2] [Dez 15 21:03:42] line 35 in 'defaulterrorhandler' in file '/usr/lib/pymodules/python2.6/MySQLdb/connections.py' (Logger.py|742)
[2] [Dez 15 21:03:42] ==>>> (1347, "'opsi.00_view_Alle_Lizenzen' is not BASE TABLE") (opsi-setup|3445)
ERROR: (1347, "'opsi.00_view_Alle_Lizenzen' is not BASE TABLE")