{ Community }
  • Academy
  • Docs
  • Developers
  • Resources
    • Community Articles
    • Apigee on GitHub
    • Code Samples
    • Videos & eBooks
    • Accelerator Methodology
  • Support
  • Ask a Question
  • Spaces
    • Product Announcements
    • General
    • Edge/API Management
    • Developer Portal (Drupal-based)
    • Developer Portal (Integrated)
    • API Design
    • APIM on Istio
    • Extensions
    • Business of APIs
    • Academy/Certification
    • Adapter for Envoy
    • Analytics
    • Events
    • Hybrid
    • Integration (AWS, PCF, Etc.)
    • Microgateway
    • Monetization
    • Private Cloud Deployment
    • 日本語コミュニティ
    • Insights
    • IoT Apigee Link
    • BaaS/Usergrid
    • BaaS Transition/Migration
    • Apigee-127
    • New Customers
    • Topics
    • Questions
    • Articles
    • Ideas
    • Leaderboard
    • Badges
  • Log in
  • Sign up

Get answers, ideas, and support from the Apigee Community

  • Home /
  • BaaS/Usergrid /
avatar image
0
Question by fwward2011 · Jul 25, 2018 at 10:24 PM · 241 Views usergridusergrid api authenticationtomcat

Deploying Usergrid Basic Auth giving 401 error from Tomcat

hello again!

I have Usergrid 2.1.0 deployed on AWS and it is running in Tomcat 7.

I can do the status check with no problems, but when I try to initialize the database, I am getting a 401 http/1.1 error from tomcat because there is no REALM for "Usergrid Authentication"

Please advise so I can get Usergrid fully functioning on AWS.

Below is the error in SSH from trying to initialize the database setup ... how do I create the REALM for Tomcat to do Basic Auth ???

		* Initializing NSS with certpath: sql:/etc/pki/nssdb
		*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
		  CApath: none
		* SSL connection using TLS_DHE_RSA_WITH_AES_256_CBC_SHA
		* Server certificate:
		*       subject: CN=spotzapi.com,OU=PositiveSSL,OU=Domain Control Validated
		*       start date: Jul 03 00:00:00 2018 GMT
		*       expire date: Jun 26 23:59:59 2020 GMT
		*       common name: spotzapi.com
		*       issuer: CN=COMODO RSA Domain Validation Secure Server CA,O=COMODO CA Limited,L=Salford,ST=Greater Manchester,C=GB
		* Server auth using Basic with user 'superuser'
		> PUT /system/database/setup HTTP/1.1
		> Authorization: Basic c3VwZXJ1c2VyOkZX
		> User-Agent: curl/7.29.0
		> Host: spotzapi.com:8443
		> Accept: */*
		>
		< HTTP/1.1 401 Unauthorized
		< Server: Apache-Coyote/1.1
		* Authentication problem. Ignoring this.
		< WWW-Authenticate: Basic realm="Usergrid Authentication"
		< Access-Control-Allow-Origin: *
		< Content-Type: application/json
		< Transfer-Encoding: chunked
		< Date: Wed, 25 Jul 2018 17:31:06 GMT
		<
		* Connection #0 to host spotzapi.com left intact
		{"error":"unauthorized","timestamp":1532539866875,"duration":0,"error_description":"No system access 								authorized","exception":"org.apache.usergrid.rest.exceptions.SecurityException"}[root@spotzapi tomcat]#


It would be nice if someone could give me the guidance I need here since my "trial developer -eval account" has been disabled.

Thanks in advance for any help offered.

Like I said before ... I can successfully check the deployment status and both elasticsearch and cassandra are accessible ...

[root@spotzapi conf]# curl https://spotzapi.com:8443/status
{
  "timestamp" : 1532557394564,
  "duration" : 26,
  "status" : {
    "started" : 1532555560187,
    "uptime" : 1834377,
    "version" : "2.1.0",
    "cassandraAvailable" : true,
    "cassandraStatus" : "GREEN",
    "managementAppIndexStatus" : "GREEN",
    "queueDepth" : 0,
    "org.apache.usergrid.count.AbstractBatcher" : {
      "add_invocation" : {
        "type" : "timer",
        "unit" : "microseconds",
        "duration" : {
          "min" : 0.0,
          "max" : 0.0,
          "mean" : 0.0,
          "std_dev" : 0.0,
          "median" : 0.0,
          "p75" : 0.0,
          "p95" : 0.0,
          "p98" : 0.0,
          "p99" : 0.0,
          "p999" : 0.0
        },
        "rate" : {
          "unit" : "seconds",
          "count" : 0,
          "mean" : 0.0,
          "m1" : 0.0,
          "m5" : 0.0,
          "m15" : 0.0
        }
      },
      "batch_add_invocations" : {
        "type" : "counter",
        "count" : 0
      }
    },
    "org.apache.usergrid.count.CassandraSubmitter" : {
      "submit_invocation" : {
        "type" : "timer",
        "unit" : "microseconds",
        "duration" : {
          "min" : 0.0,
          "max" : 0.0,
          "mean" : 0.0,
          "std_dev" : 0.0,
          "median" : 0.0,
          "p75" : 0.0,
          "p95" : 0.0,
          "p98" : 0.0,
          "p99" : 0.0,
          "p999" : 0.0
        },
        "rate" : {
          "unit" : "seconds",
          "count" : 0,
          "mean" : 0.0,
          "m1" : 0.0,
          "m5" : 0.0,
          "m15" : 0.0
        }
      }
    },
    "org.apache.usergrid.rest.filters.MeteringFilter" : {
      "activeRequests" : {
        "type" : "counter",
        "count" : 1
      },
      "requests" : {
        "type" : "timer",
        "unit" : "milliseconds",
        "duration" : {
          "min" : 1.120395,
          "max" : 137.544386,
          "mean" : 24.62666075,
          "std_dev" : 46.29416986662639,
          "median" : 6.326183500000001,
          "p75" : 22.03745025,
          "p95" : 137.544386,
          "p98" : 137.544386,
          "p99" : 137.544386,
          "p999" : 137.544386
        },
        "rate" : {
          "unit" : "seconds",
          "count" : 8,
          "mean" : 0.004361062652518177,
          "m1" : 3.9833045248366854E-14,
          "m5" : 7.873354569946326E-5,
          "m15" : 0.0012716346588683113
        }
      }
    }
  }
}[root@spotzapi conf]#
Comment
Add comment Show 1
10 |5000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by Apigeeks only
  • Viewable by the original poster
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image fwward2011 · Jul 26, 2018 at 01:15 AM 0
Link

OK !!! .... I resolved it ...

on my setup, I was able to leave off the password to superuser in the CURL commands and after being prompted for password the commands completed successfully ...

have a great life APIGEE .... see ya!

Close

0 Answers

  • Sort: 

Follow this Question

Answers Answers and Comments

43 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Not able to login to usergrid with correct credentials 1 Answer

How do I query BaaS/Usergrid using Paw for MacOS X? 1 Answer

Unable to send BaaS access token to UserGrid Client createEntity 1 Answer

BaaS connectivity with NodeJS 2 Answers

How i can upload a asset on the BAAS with an API on the BAAS, without curl ? 3 Answers

  • Products
    • Edge - APIs
    • Insights - Big Data
    • Plans
  • Developers
    • Overview
    • Documentation
  • Resources
    • Overview
    • Blog
    • Apigee Institute
    • Academy
    • Documentation
  • Company
    • Overview
    • Press
    • Customers
    • Partners
    • Team
    • Events
    • Careers
    • Contact Us
  • Support
    • Support Overview
    • Documentation
    • Status
    • Edge Support Portal
    • Privacy Policy
    • Terms & Conditions
© 2021 Apigee Corp. All rights reserved. - Apigee Community Terms of Use - Powered by AnswerHub
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Create an article
  • Post an idea
  • Spaces
  • Product Announcements
  • General
  • Edge/API Management
  • Developer Portal (Drupal-based)
  • Developer Portal (Integrated)
  • API Design
  • APIM on Istio
  • Extensions
  • Business of APIs
  • Academy/Certification
  • Adapter for Envoy
  • Analytics
  • Events
  • Hybrid
  • Integration (AWS, PCF, Etc.)
  • Microgateway
  • Monetization
  • Private Cloud Deployment
  • 日本語コミュニティ
  • Insights
  • IoT Apigee Link
  • BaaS/Usergrid
  • BaaS Transition/Migration
  • Apigee-127
  • New Customers
  • Explore
  • Topics
  • Questions
  • Articles
  • Ideas
  • Badges