openhab / openhab-syno-spk

openHAB Synology SPK Install Package
Eclipse Public License 2.0
161 stars 42 forks source link

Installation on DSM6.0.2 fails with 'Port undefined configured...' #36

Closed tseroo closed 7 years ago

tseroo commented 8 years ago

Hi,

I'm having the same problem as described in #24. None of the DSM 6 packages is working for me. I'm running DSM 6.0.2-8451 Update 2 and I've tried

Error message is "Port undefined configured for this package is either used by another service or reserved for system. Please disable or modify the conflicting service, or contact the developer to modify the package configuration".

Port 8080 is not in use:

root@ds412:/usr/local/etc/services.d# netstat -an | grep 8080
root@ds412:/usr/local/etc/services.d#

That's written in the synopkg.log:

2016/11/06 20:13:50 (system) trigger :
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 INFO --no-same-owner
2016/11/06 20:13:50 (system) trigger :
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 INFO --no-same-owner ret=[0]
2016/11/06 20:13:50 (system) trigger :
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 conf --no-same-owner
/bin/tar: conf: Not found in archive
/bin/tar: Exiting with failure status due to previous errors
2016/11/06 20:13:50 (system) trigger :
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 conf --no-same-owner ret=[2]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/start-stop-status --no-same-owner --no-same-permissions
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/start-stop-status --no-same-owner --no-same-permissions ret=[0]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preinst --no-same-owner --no-same-permissions
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preinst --no-same-owner --no-same-permissions ret=[0]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postinst --no-same-owner --no-same-permissions
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postinst --no-same-owner --no-same-permissions ret=[0]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preuninst --no-same-owner --no-same-permissions
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preuninst --no-same-owner --no-same-permissions ret=[0]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postuninst --no-same-owner --no-same-permissions
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postuninst --no-same-owner --no-same-permissions ret=[0]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preupgrade --no-same-owner --no-same-permissions
/bin/tar: scripts/preupgrade: Not found in archive
/bin/tar: Exiting with failure status due to previous errors
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/preupgrade --no-same-owner --no-same-permissions ret=[2]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postupgrade --no-same-owner --no-same-permissions
/bin/tar: scripts/postupgrade: Not found in archive
/bin/tar: Exiting with failure status due to previous errors
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/tar xf /volume1/@tmp/upload_tmp.319140 -C /volume1/@tmp/581F80EE0 scripts/postupgrade --no-same-owner --no-same-permissions ret=[2]
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
Begin: /bin/rm -rf /volume1/@tmp/581F80EE0
2016/11/06 20:13:50 (system) trigger OpenHAB 1.8.3-001:
End: /bin/rm -rf /volume1/@tmp/581F80EE0 ret=[0]

Any ideas?? Thanks, Harry

tseroo commented 7 years ago

No one has any hint???

cniweb commented 7 years ago

Hi @tseroo,

I released a new release with the new OH2 folder structure (#37), try it, please: https://github.com/openhab/openhab-syno-spk/releases/tag/2.0.0.008-SNAPSHOT-DSM6

Thanks, Christian

cniweb commented 7 years ago

Can you try reinstalling the package?

cniweb commented 7 years ago

This is actually a DSM issue, but this should be fixed in DSM 6.0.2 Update 2, can you reboot your DS?

florisi commented 7 years ago

Running latest DSM, try to install 2.0.0.008-SNAPSHOT, still the same error

tseroo commented 7 years ago

I've test again with DSM 6.0.2U6 and 2.0.0.008-SNAPSHOT but no change, still failing.

Skostrub commented 7 years ago

Guys try to reboot your NAS.

This worked for me with .008 installation

tseroo commented 7 years ago

The system rebooted when installing Update 6, but it did not work. I've done another reboot and tried again, and it failed. Any other suggestions?

hilmarf commented 7 years ago

have you checked the SSL ports? netstat -l | grep 443 on my DSM this results in tcp6 0 0 [::]:8443 [::]:* LISTEN after changing HTTPS_PORT=8443 to HTTPS_PORT=9443 in start_runtime.sh openHAB runs fine

tseroo commented 7 years ago

I guess you are talking about starting openHAB, but my problem is that the installation fails! I only have the spk file and no start scripts.

aspruil commented 7 years ago

I am also having the same problem. I even tried uninstalling several apps that may be a port conflict and still cannot get the installs to work. Really want to use openhab on Synology...

Thanks...

yphyph01 commented 7 years ago

Hello, I don't know if that could help the port conflict issue, but do not forget that OpenHAB2 is also using the port 8101 to connect in ssh to the Karaf Console Regards

tseroo commented 7 years ago

Problem solved! Under /usr/local/etc/services.d there are files containing package related data. In my case the sabnzbd.sc file contained dst.ports="8080/tcp". Although I've changed the sabnzbd port to 8180 via the GUI, the sabnzbd.sc file was not updated accordingly, thus still containing 8080. After changing the .sc file to 8180, openhab installation did not complain anymore!

It seems the ports 8080, 8443 and 5555 are needed.

BTW, in the meantime I have it running as a Docker container.

aspruil commented 7 years ago

@tseroo that was it. Got it installed. Thanks....

ppmhuijbers commented 7 years ago

Had the same issue, only then with Zarafa.sc that left 8081 in the configuration although it was removed. Logged in with ssh , took sudo -i (admin rights) and removed with vi Zarafa.sc -> wq! the configuration parts referring to port 8081 . Thanks tseroo for the solution

Pi-And-More commented 6 years ago

Stumbled upon this post when trying to do the same for OpenHab. For me 8080, 8443 and 5555 were not in use and also not in the .sc files. What eventually helped me was to unpack the SPK file as suggested here: https://github.com/openhab/openhab-syno-spk/issues/69 and which I learned how to do here: https://forum.synology.com/enu/viewtopic.php?t=10807