Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello,
I deployed a new landscape server on a digital ocean droplet. The host seems to installed fine and I am able to connect to the web UI. For some reason I am unable to register clients. I believe I have setup the certs correctly as well.
First let me post some of the error messages I am seeing:
Server Side:
Code:
landscape-appserver.service - LSB: Enable Landscape frontend UI
Loaded: loaded (/etc/init.d/landscape-appserver; bad; vendor preset: enabled)
Active: active (running) since Tue 2016-10-25 16:08:03 UTC; 22min ago
Docs: man:systemd-sysv-generator(8)
Process: 20664 ExecStop=/etc/init.d/landscape-appserver stop (code=exited, status=0/SUCCESS)
Process: 20681 ExecStart=/etc/init.d/landscape-appserver start (code=exited, status=0/SUCCESS)
Tasks: 3
Memory: 144.9M
CPU: 10.438s
CGroup: /system.slice/landscape-appserver.service
└─20729 python /opt/canonical/landscape/landscape --rundir=/opt/canonical/landscape --pidfile=/var/run/landscape/landscape-appserver-1.pid
Oct 25 16:28:50 landscape.myhost.com appserver-1[20729]: Exception while rendering view on exception
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/zope/app/publication/zopepublication.py", line 379, in handleException
body = mapply(view, (), request)
File "/usr/lib/python2.7/dist-packages/zope/publisher/publish.py", line 107, in mapply
return debug_call(obj, args)
File "/usr/lib/python2.7/dist-packages/zope/publisher/publish.py", line 113, in debug_call
return obj(*args)
File "/opt/canonical/landscape/canonical/landscape/ui/page/page.py", line 262, in __call__
self._check_request_csrf_token()
File "/opt/canonical/landscape/canonical/landscape/ui/page/page.py", line 238, in _check_request_csrf_token
self.request, require_post=require_post)
File "/opt/canonical/landscape/canonical/landscape/ui/page/page.py", line 429, in check_request_csrf_token
raise Unauthorized("Missing/invalid CSRF token")
Unauthorized: Missing/invalid CSRF token
Oct 25 16:28:50 landscape.myhost.com appserver-1[20729]: x.x.x.x - - [25/Oct/2016:16:28:50 +0000] "POST /message-system HTTP/1.1" 404 107 "-" "landscape-client/14.12-0ubuntu0.14.04"
Oct 25 16:29:06 landscape.myhost.com appserver-1[20729]: x.x.x.x - - [25/Oct/2016:16:29:06 +0000] "POST /ajax/ HTTP/1.1" 408 - "http://landscape.myhost.com:8080/account/standalone" "Mo
Oct 25 16:29:06 landscape.myhost.com appserver-1[20729]: Stopping factory <canonical.twisted.proxy.ProxyClientFactoryWithFinish instance at 0x7f761c7fcc68>
Oct 25 16:29:06 landscape.myhost.com appserver-1[20729]: Starting factory <canonical.twisted.proxy.ProxyClientFactoryWithFinish instance at 0x7f761c762050>
Oct 25 16:29:36 landscape.myhost.com appserver-1[20729]: http://landscape.myhost.com:8080/message-system
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/zope/publisher/publish.py", line 129, in publish
obj = request.traverse(obj)
File "/usr/lib/python2.7/dist-packages/zope/publisher/browser.py", line 540, in traverse
ob = super(BrowserRequest, self).traverse(obj)
File "/usr/lib/python2.7/dist-packages/zope/publisher/http.py", line 457, in traverse
ob = super(HTTPRequest, self).traverse(obj)
File "/usr/lib/python2.7/dist-packages/zope/publisher/base.py", line 260, in traverse
obj = publication.traverseName(self, obj, entry_name)
File "/usr/lib/python2.7/dist-packages/zope/app/publication/zopepublication.py", line 198, in traverseName
ob2 = adapter.publishTraverse(request, nm)
File "/opt/canonical/landscape/canonical/routes/publisher.py", line 125, in publishTraverse
raise NotFound(self.context, name)
NotFound: Object: <canonical.landscape.model.root.landscape.LandscapeRoot object at 0x7f761f7680d0>, name: u'message-system'
Oct 25 16:29:36 landscape.myhost.com appserver-1[20729]: Exception while rendering view on exception
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/zope/app/publication/zopepublication.py", line 379, in handleException
Client Side:
Code:
HTTPCodeError: Server returned HTTP code 404
2016-10-25 12:22:36,538 INFO [MainThread] Message exchange failed.
2016-10-25 12:22:36,539 INFO [MainThread] Message exchange completed in 0.27s.
2016-10-25 12:23:36,544 INFO [MainThread] Queueing message to register with account 'standalone' without a password.
2016-10-25 12:23:36,546 INFO [MainThread] Starting urgent message exchange with http://landscape.myhost.com:8080/message-system.
2016-10-25 12:23:36,624 ERROR [PoolThread-twisted.internet.reactor-1] Error contacting the server at http://landscape.myhost.com:8080/message-system.
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/landscape/broker/transport.py", line 71, in exchange
message_api)
File "/usr/lib/python2.7/dist-packages/landscape/broker/transport.py", line 45, in _curl
headers=headers, cainfo=self._pubkey, curl=curl))
File "/usr/lib/python2.7/dist-packages/landscape/lib/fetch.py", line 115, in fetch
raise HTTPCodeError(http_code, body)
HTTPCodeError: Server returned HTTP code 404
2016-10-25 12:23:36,625 INFO [MainThread] Message exchange failed.
2016-10-25 12:23:36,625 INFO [MainThread] Message exchange completed in 0.08s.
I copied the cert from the Landscape server over to the client.
Code:
from /etc/ssl/certs/landscape_server_ca.crt to client @ /etc/landscape/server.pem
Here is the config on the client pointing to the cert
Code:
[client]
log_level = info
url = http://landscape.myhost.com:8080/message-system
ping_url = http://landscape.myhost.com:8080/pin
data_path = /var/lib/landscape/client
include_manager_plugins = ScriptExecution
computer_title = My Web Server
account_name = standalone
ssl_public_key = /etc/landscape/server.pem
I have edited out hostnames and IPs but have confirmed they are all correct. I also confirmed the cert was using the correct hostname.
Any ideas on what might be preventing registration?
Still stuck on this. I was having issues posting to the Ubuntu forum so I thought I would check in here again... Any ideas?
Sorry to resurrect a long long dead thread, but this was one of the key sites that returned hits on an error I was having today, which (afaik) is the same error the OP was having.
I figured out that the registration instructions are slightly wrong, though I'd be welcome to some feed back. The registration says to run this on the client
Code:
sudo landscape-config --computer-title "My Web Server" --account-name standalone --url http://landscape.domain.com:8080/message-system --ping-url http://landscape.domain.com:8080/ping
However both of those URLs return 404 when you visit them directly. I poked around a bit and found they were actually available on tcp port 8090, NOT 8080, adjusted the offending URLs in /etc/landscape/client.conf and restarted the service, now my landscape client is registering and reporting in appropriately.
This seems like such a dumb thing that I almost have to be wrong, so if someone else finds this and it works for them, I'd love to hear some confirmation.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.