Error Java Connection Refused

timmon
Beiträge: 14
Registriert: 12 Okt 2010, 12:50

Error Java Connection Refused

Beitrag von timmon »

Hi Everybody,

i got a problem with my OPSI server.

I installed on mine server a VM with OPSI 4.0 ...
1stboot.py etc. works, but when i wanna go into the "Opsi-configed" (On the Desktop)
I login with my "Adminuser" and then the error appears:

Code: Alles auswählen

Connection Lost
java.net.ConnectException Connection Refused

/configed/configed.log

Code: Alles auswählen

TEST     -- Tue Oct 12 12:54:38 CEST 2010 --   OS Linux  Version 2.6.32-21-generic
TEST     -- Tue Oct 12 12:54:41 CEST 2010 --  retrieveOpsiModules
ERROR    -- Tue Oct 12 12:54:41 CEST 2010 -- de.uib.opsicommand.JSONthroughHTTPS Exception on connecting, java.net.ConnectException: Connection refused
ERROR    -- Tue Oct 12 12:54:41 CEST 2010 -- de.uib.opsicommand.JSONthroughHTTPS Exception on connecting, java.net.ConnectException: Connection refused

Thanks!
Timmon
Benutzeravatar
j.schneider
uib-Team
Beiträge: 2042
Registriert: 29 Mai 2008, 15:14

Re: Error Java Connection Refused

Beitrag von j.schneider »

It seems that the opsi service (opsiconfd) is not running.
Please try to start it:

Code: Alles auswählen

/etc/init.d/opsiconfd start
If the error persists, please post the last ~30 lines from /var/log/opsi/opsiconfd/opsiconfd.log


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


timmon
Beiträge: 14
Registriert: 12 Okt 2010, 12:50

Re: Error Java Connection Refused

Beitrag von timmon »

Code: Alles auswählen

root@test:/# /etc/init.d/opsiconfd start
Starting opsi config service.....   (done).
root@test:/# /etc/init.d/opsiconfd status
Checking opsi config service... (not running).

Code: Alles auswählen

[2] [Oct 12 13:46:23]      line 365 in '_executeMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/Backend.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 365 in '_executeMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/Backend.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 309 in '_dispatchMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/BackendManager.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 1127 in 'host_getObjects' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 203 in 'getSet' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 343 in 'execute' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 166 in 'execute' in file '/usr/lib/pymodules/python2.6/MySQLdb/cursors.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      line 35 in 'defaulterrorhandler' in file '/usr/lib/pymodules/python2.6/MySQLdb/connections.py' (Logger.py|710)
[2] [Oct 12 13:46:23]      ==>>> (1146, "Table 'opsi.HOST' doesn't exist") (opsiconfd.py|2257)
[1] [Oct 12 13:46:39]
==================================================================
=             opsi configuration service starting                =
==================================================================
 (Logger.py|777)
[5] [Oct 12 13:46:39] Starting opsiconfd main thread (opsiconfd.py|2243)
[5] [Oct 12 13:46:39] Modules file signature verified (customer: opsi community - opsi 4.0 evaluation - uib gmbh) (MySQL.py|406)
[5] [Oct 12 13:46:40] Added static content '/' which points to directory '/usr/share/opsiconfd/static' (opsiconfd.py|2116)
[2] [Oct 12 13:46:40] Traceback: (Logger.py|710)
[2] [Oct 12 13:46:40]      line 2248 in 'run' in file '/usr/lib/pymodules/python2.6/opsiconfd/opsiconfd.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 2126 in '_createSite' in file '/usr/lib/pymodules/python2.6/opsiconfd/opsiconfd.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 365 in '_executeMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/Backend.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 365 in '_executeMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/Backend.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 365 in '_executeMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/Backend.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in 'host_getObjects' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 309 in '_dispatchMethod' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/BackendManager.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1 in '<module>' in file '<string>' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 1127 in 'host_getObjects' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 203 in 'getSet' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 343 in 'execute' in file '/usr/lib/pymodules/python2.6/OPSI/Backend/MySQL.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 166 in 'execute' in file '/usr/lib/pymodules/python2.6/MySQLdb/cursors.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      line 35 in 'defaulterrorhandler' in file '/usr/lib/pymodules/python2.6/MySQLdb/connections.py' (Logger.py|710)
[2] [Oct 12 13:46:40]      ==>>> (1146, "Table 'opsi.HOST' doesn't exist") (opsiconfd.py|2257)

timmon
Beiträge: 14
Registriert: 12 Okt 2010, 12:50

Re: Error Java Connection Refused

Beitrag von timmon »

I had reinstalled the opsiconfd packet

Code: Alles auswählen

apt-get remove opsiconfd
apt-get install opsiconfd
When i now want to restart the service

Code: Alles auswählen

root@test:/# /etc/init.d/opsiconfd restart
Stopping opsi config service...   (not running).
Starting opsi config service..No directory, logging in with HOME=/
...   (done).
Benutzeravatar
j.schneider
uib-Team
Beiträge: 2042
Registriert: 29 Mai 2008, 15:14

Re: Error Java Connection Refused

Beitrag von j.schneider »

Hi,

please have a look at the manual http://download.uib.de/opsi4.0/doc/opsi ... v40-en.pdf.

Code: Alles auswählen

opsi-setup --init-current-config
opsi-setup --set-rights
/etc/init.d/opsiconfd start
/etc/init.d/opsipxeconfd start


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


timmon
Beiträge: 14
Registriert: 12 Okt 2010, 12:50

Re: Error Java Connection Refused

Beitrag von timmon »

Hi,

really thanks the system is running now.

I work with that manual but didnt find it.

faithfully
Timmon
guillaume
Beiträge: 34
Registriert: 19 Feb 2019, 18:08

Re: Error Java Connection Refused

Beitrag von guillaume »

Hello everyone,

I have the same issue but réinstalling OPSICONFD didn't solve it. Here are my logs :
adminuser@srv-opsi:~$ sudo apt-get install opsiconfd
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
Les NOUVEAUX paquets suivants seront installés :
opsiconfd
0 mis à jour, 1 nouvellement installés, 0 à enlever et 2 non mis à jour.
Il est nécessaire de prendre 34,3 Mo dans les archives.
Après cette opération, 108 Mo d'espace disque supplémentaires seront utilisés.
Réception de :1 http://download.opensuse.org/repositori ... untu_20.04 opsiconfd 4.2.0.246-1 [34,3 MB]
34,3 Mo réceptionnés en 3s (11,2 Mo/s)
Sélection du paquet opsiconfd précédemment désélectionné.
(Lecture de la base de données... 154011 fichiers et répertoires déjà installés.)
Préparation du dépaquetage de .../opsiconfd_4.2.0.246-1_amd64.deb ...
Dépaquetage de opsiconfd (4.2.0.246-1) ...
Paramétrage de opsiconfd (4.2.0.246-1) ...
[5] [2022-03-18 08:03:20.780] [ ] Running opsiconfd setup (setup.py:203)
[4] [2022-03-18 08:03:21.280] [ ] Warning '"is not" with a literal. Did you mean "!="?' in file '<string>', line 254 (logging.py:795)
[5] [2022-03-18 08:03:21.383] [ ] Creating base path: '/var/lib/opsi/config' (File.py:215)
[5] [2022-03-18 08:03:21.699] [ ] Creating opsi base (SQL.py:611)
[5] [2022-03-18 08:03:29.163] [ ] Setting up default values. (ConfigurationData.py:64)
[5] [2022-03-18 08:03:29.340] [ ] Finished setting up default values. (ConfigurationData.py:71)
[4] [2022-03-18 08:03:29.713] [ ] Warning '"is not" with a literal. Did you mean "!="?' in file '<string>', line 254 (logging.py:795)
[5] [2022-03-18 08:03:29.815] [ ] Connection to database 'opsi' on 'localhost' as user 'opsi' (MySQL.py:62)
[5] [2022-03-18 08:03:29.988] [ ] Creating opsi base (SQL.py:611)
[4] [2022-03-18 08:03:39.858] [ ] Warning '"is not" with a literal. Did you mean "!="?' in file '<string>', line 254 (logging.py:795)
[5] [2022-03-18 08:03:40.245] [ ] Setting rights on '/etc/shadow' (Rights.py:233)
[5] [2022-03-18 08:03:40.247] [ ] Setting rights on '/var/log/opsi/opsiconfd/opsiconfd.log' (Rights.py:233)
[5] [2022-03-18 08:03:40.249] [ ] Setting rights on '/etc/dhcp/dhcpd.conf' (Rights.py:233)
[5] [2022-03-18 08:03:40.251] [ ] Setting rights recursively on '/var/lib/opsiconfd/addons' (Rights.py:233)
[5] [2022-03-18 08:03:40.252] [ ] Setting rights recursively on '/etc/opsi' (Rights.py:233)
[5] [2022-03-18 08:03:40.255] [ ] Setting rights recursively on '/etc/opsi/ssl' (Rights.py:233)
[5] [2022-03-18 08:03:40.256] [ ] Setting rights on '/etc/opsi/ssl/opsi-ca-cert.pem' (Rights.py:233)
[5] [2022-03-18 08:03:40.257] [ ] Setting rights on '/etc/opsi/ssl/opsi-ca-cert.pem' (Rights.py:233)
[5] [2022-03-18 08:03:40.259] [ ] Setting rights on '/etc/opsi/ssl/opsi-ca-key.pem' (Rights.py:233)
[5] [2022-03-18 08:03:40.261] [ ] Setting rights on '/etc/opsi/ssl/opsiconfd-cert.pem' (Rights.py:233)
[5] [2022-03-18 08:03:40.263] [ ] Setting rights on '/etc/opsi/ssl/opsiconfd-key.pem' (Rights.py:233)
[4] [2022-03-18 08:03:42.285] [ ] Failed to setup redis downsampling: Error 111 connecting to localhost:6379. Connection refused. (setup.py:250)
Traceback (most recent call last):
File "redis/connection.py", line 607, in connect
File "redis/retry.py", line 45, in call_with_retry
File "redis/connection.py", line 608, in <lambda>
File "redis/connection.py", line 673, in _connect
File "redis/connection.py", line 661, in _connect
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "opsiconfd/setup.py", line 248, in setup
File "opsiconfd/statistics.py", line 72, in setup_metric_downsampling
File "redis/client.py", line 1173, in execute_command
File "redis/connection.py", line 1370, in get_connection
File "redis/connection.py", line 613, in connect
redis.exceptions.ConnectionError: Error 111 connecting to localhost:6379. Connection refused.
Does anyone have an idea ? What's missing ? All my updates are done with OPSI GUI interface.

Thanks for your help.

Regards
Guillaume/William
Benutzeravatar
j.schneider
uib-Team
Beiträge: 2042
Registriert: 29 Mai 2008, 15:14

Re: Error Java Connection Refused

Beitrag von j.schneider »

Hello,

there seem to be no redis server running on the machine.

Probably you should install the package opsi-server-full.
Please read the documentation:

https://download.uib.de/opsi4.2/documen ... rerequires

Regards,
Jan Schneider


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


guillaume
Beiträge: 34
Registriert: 19 Feb 2019, 18:08

Re: Error Java Connection Refused

Beitrag von guillaume »

Hi Jan Schneider,

I followed your steps, and it works fine. OPSI server i back to life !
Strangly the manual install works for me but i cannot understand why the GUI tool didn't update correctly the server ?

Tks a lot for your help,
Regards,
Benutzeravatar
m.radtke
Ex-uib-Team
Beiträge: 1767
Registriert: 10 Jun 2015, 12:19

Re: Error Java Connection Refused

Beitrag von m.radtke »

Hi

just for clarification. What is the GUI tool you mentioned?

Regards
Mathias


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


Antworten