Ask Your Question
0

error while creating services and API endpoints

asked 2014-10-14 00:32:12 -0600

Durrani gravatar image

updated 2014-10-14 06:30:13 -0600

dbaxps gravatar image

Folks,

seeing unreognized argument error while trying to create end-points .. i figure passing keystone service-list i see two identity types one is openstack other is keystone - unrecognized argument is for keystone identify .. can someone please shed some light and how to proceed .. thanks much in advance !

root@ubuntu-08:~# keystone endpoint-create \
>   --service-id=$(keystone service-list | awk '/ identity / {print $2}') \
>   --publicurl=http://controller:5000/v2.0 \
>   --internalurl=http://controller:5000/v2.0 \
>   --adminurl=http://controller:35357/v2.0
usage: keystone [--version] [--debug] [--os-username <auth-user-name>]
                [--os-password <auth-password>]
                [--os-tenant-name <auth-tenant-name>]
                [--os-tenant-id <tenant-id>] [--os-auth-url <auth-url>]
                [--os-region-name <region-name>]
                [--os-identity-api-version <identity-api-version>]
                [--os-token <service-token>]
                [--os-endpoint <service-endpoint>] [--os-cache]
                [--force-new-token] [--stale-duration <seconds>] [--insecure]
                [--os-cacert <ca-certificate>] [--os-cert <certificate>]
                [--os-key <key>] [--timeout <seconds>]
                <subcommand> ...
keystone: error: unrecognized arguments: d1df75824e1c4e51a3465dff12c62908

root@ubuntu-08:~# keystone service-list 
+----------------------------------+----------+----------------+-----------------------------+
|                id                |   name   |      type      |         description         |
+----------------------------------+----------+----------------+-----------------------------+
| d10db1a33dd9417da0480a34350e934c |  cinder  |     volume     |    Cinder Volume Service    |
| 1079fb3b15a44650821bd78aeba1f49b | cinderv2 |    volumev2    |   Cinder Volume Service V2  |
| 96d8a883f52448e2bfcb67a0ba0f39d5 |   ec2    |      ec2       |   EC2 Compatibility Layer   |
| f3cee504ded243eb899e91064241b4f8 |  glance  |     image      |     Glance Image Service    |
| 305e4cf418bf4a47be424fddb05c5615 |   heat   | cloudformation | Heat CloudFormation Service |
| 47c74244d2b84d55a79d64a92eb3885a |   heat   | orchestration  |  Heat Orchestration Service |
| 6c148576ffef4c7fb5ba1b81ac3a7fc0 | keystone |    identity    |      OpenStack Identity     |
| d1df75824e1c4e51a3465dff12c62908 | keystone |    identity    |  Keystone Identity Service  |
| b2a83c8695904b5a85dd906fde2f173d |   nova   |    compute     |     Nova Compute Service    |
| 44c3c2d630074fcfa381106cc09faa86 |  novav3  |   computev3    |   Nova Compute Service V3   |
| 472695d0cc474232aa9b1bddd8e70e3a |    s3    |       s3       |              S3             |
+----------------------------------+----------+----------------+-----------------------------+
edit retag flag offensive close merge delete

3 answers

Sort by ยป oldest newest most voted
0

answered 2014-10-14 09:51:21 -0600

bishoy gravatar image

updated 2014-10-14 09:51:59 -0600

--service-id=$(keystone service-list | awk '/ identity / {print $2}') it doesn't need you to use awk however it's smarter and faster but it retrives you 2 identity as you have in the service tables!!

edit flag offensive delete link more
0

answered 2014-10-14 07:57:46 -0600

larsks gravatar image

There are two identity services registered in your service catalog:

| 6c148576ffef4c7fb5ba1b81ac3a7fc0 | keystone |    identity    |      OpenStack Identity     |
| d1df75824e1c4e51a3465dff12c62908 | keystone |    identity    |  Keystone Identity Service  |

So when you try to get the service id with awk:

keystone service-list | awk '/ identity / {print $2}'

You are getting two results:

6c148576ffef4c7fb5ba1b81ac3a7fc0
d1df75824e1c4e51a3465dff12c62908

So your final command line looks like:

root@ubuntu-08:~# keystone endpoint-create \
>   --service-id=6c148576ffef4c7fb5ba1b81ac3a7fc0 d1df75824e1c4e51a3465dff12c62908 \
>   --publicurl=http://controller:5000/v2.0 \
>   --internalurl=http://controller:5000/v2.0 \
>   --adminurl=http://controller:35357/v2.0

And that's the the source of your error. You should remove one of the identity entries from the service catalog.

edit flag offensive delete link more
0

answered 2014-10-14 06:46:30 -0600

dbaxps gravatar image

updated 2014-10-14 07:03:20 -0600

I believe there are syntax errors in first statement
View for samples https://kashyapc.fedorapeople.org/vir...

 $ for i in start enable status; \
    do systemctl $i openstack-keystone; done 

  $ keystone service-create --name keystone --type identity \
    --description "Keystone Identity Service"
  +-------------+----------------------------------+
  |   Property  |              Value               |
  +-------------+----------------------------------+
  | description |    Keystone Identity Service     |
  |   enabled   |               True               |
  |      id     | 87bff5bf23ce4601bebbf2b81ddb20ef |
  |     name    |             keystone             |
  |     type    |             identity             |
  +-------------+----------------------------------+

  $ keystone endpoint-create --service_id 87bff5bf23ce4601bebbf2b81ddb20ef \
          --publicurl 'http://192.169.142.97:5000/v2.0' \
          --adminurl 'http://192.169.142.97:35357/v2.0' \
          --internalurl 'http://192.169.142.97:5000/v2.0'
  +-------------+----------------------------------+
  |   Property  |              Value               |
  +-------------+----------------------------------+
  |   adminurl  | http://192.169.142.97:35357/v2.0 |
  |      id     | 6fc0caec84be4fd39fa596134fd0612c |
  | internalurl | http://192.169.142.97:5000/v2.0  |
  |  publicurl  | http://192.169.142.97:5000/v2.0  |
  |    region   |            regionOne             |
  |  service_id | 87bff5bf23ce4601bebbf2b81ddb20ef |
  +-------------+----------------------------------+
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-10-14 00:32:12 -0600

Seen: 1,471 times

Last updated: Oct 14 '14