OpenStack Interview Questions and Answers
Here is a list of Important OpenStack Interview Question and Answers.
OpenStack Identity Management
How would you add the user apressuser with a Member role to the apress project?A. openstack role add –project apress –user apressuser _member_
B. openstack role add –project apress –user apressuser member
C. openstack role add –project apress –user _member_ apressuser
D. openstack role add –project apress –user member apressuser
Answer:
A. openstack role add --project apress --user apressuser _member_
Which two system services should be started for a proper Keystone functioning (choose two)?
A. keystone-main
B. keystone-admin
C. memcached
D. httpd
Answer:
C. memcached
D. httpd
How would you define a new role in OpenStack cloud (choose all applicable)?
A. Enter command openstack role create newrole.
B. Restart httpd service.
C. Create new “keystonerc” file.
D. Add definition to policy.json files.
Answer:
A. Enter command openstack role create newrole.
D. Add definition to policy.json files.
How would you separate two or more cloud instances but manage them with one Keystone instance?
A. Use Domains feature.
B. Use Regions feature.
C. Use availability zones.
D. Each cloud instance should use own Keystone instance feature.
Answer:
A. Use Domains feature.
Which HTTP error code would you get if the Keystone token has expired?
A. ERROR 404.
B. ERROR 403.
C. ERROR 401.
D. All of them.
Answer:
C. ERROR 401.
OpenStack Images Management
Where are the images stored when using the local file system by default?A. /var/cache/glance/
B. /var/lib/glance/store/
C. /var/log/glance/
D. /var/lib/glance/images/
Answer:
D. /var/lib/glance/images/
Which two main daemons does Glance consist of (choose two)?
A. glance-endpoint
B. glance-registry
C. glance-backend
D. glance-api
Answer:
B. glance-registry
D. glance-api
What parameter in Glance’s configuration files defines the back end for storing files?
A. default_store
B. default_backend
C. prefered_store
D. prefered_backend
Answer:
B. default_backend
How can an image in OpenStack cloud be stored with CLI?
A. openstack image create –file image.img –disk-format qcow2 –containerformat bare –public image
B. openstack image add –file image.img –disk-format qcow2 –containerformat bare –public image
C. openstack image create –file image.img –disk qcow2 –container-format bare –public image
D. openstack image add –file image.img –disk qcow2 –container-format bare –public image
Answer:
A. openstack image create --file image.img --disk-format qcow2 --containerformat bare --public image
How can the storage volume be limited in Glance per user?
A. Put image_size_cap option to /etc/glance/glance-api.conf
B. Put image_size_cap option to /etc/glance/glance-registry.conf
C. Put user_storage_quota option to /etc/glance/glance-api.conf
D. Put user_storage_quota option to /etc/glance/glance-registry.conf
Answer:
C. Put user_storage_quota option to /etc/glance/glance-api.conf
Openstack Networking
What service provides routing and Network Address Translation?A. neutron-server
B. neutron-openvswitch-agent
C. neutron-l3-agent
D. neutron-metadata-agent
Answer:
B. neutron-openvswitch-agent
How can you check the status of running Neutron agents?
A. neutron agents-list-state
B. neutron agent-list
C. neutron list-agent
D. neutron agents-list
Answer:
C. neutron list-agent
Name the Neutron API service config.
A. /etc/neutron/neutron.conf
B. /etc/neutron.conf
C. /etc/neutron/plugin.ini
D. /etc/neutron/api-server.conf
Answer:
A. /etc/neutron/neutron.conf
How can you correctly add a new rule to an existing Security Group?
A. nova secgroup-add-rule apress-sgroup tcp 0.0.0.0/0
B. nova secgroup-add-rule apress-sgroup tcp 0.0.0.0/0
C. nova secgroup-add-new-rule apress-sgroup tcp 0.0.0.0/0
D. nova secgroup-add-new-rule apress-sgroup tcp 0.0.0.0/0
Answer:
A. nova secgroup-add-rule apress-sgroup tcp 0.0.0.0/0
Where is the Neutron API log file situated?
A. /var/log/neutron/neutron.log
B. /var/log/neutron/server.log
C. /var/log/neutron/api.log
D. /var/log/neutron/api-server.log
Answer:
B. /var/log/neutron/server.log
OpenStack Compute
Which service acts as a proxy service between the database and nova-compute services?A. nova-conductor
B. nova-nonvncproxy
C. nova-api
D. nova-scheduler
Answer:
A. nova-conductor
How can you add a new flavor with name m5.tiny that has 5GB disk, 2 vCPU, and 500Mb RAM?
A. nova flavor-create –is-public true m5.tiny auto 500 2 5
B. nova flavor-create –is-public true m5.tiny auto 5 2 500
C. nova flavor-create –is-public true m5.tiny auto 500 5 2
D. nova flavor-create –is-public true m5.tiny auto 5 500 2
Answer:
C. nova flavor-create --is-public true m5.tiny auto 500 5 2
Which GNU/Linux permissions should be applied to the private SSH key?
A. 640
B. 660
C. 600
D. 620
Answer:
C. 600
How can the regular user get Nova quotes for the project?
A. nova quota-list
B. nova quota-show
C. nova show-quota
D. nova list-quota
Answer:
B. nova quota-show
How can you get summary statistics for all tenants?
A. nova show-stat
B. nova usage-list all
C. nova statistics
D. nova usage-list
Answer:
D. nova usage-list
OpenStack Dashboard
What is the main configuration file of the OpenStack Dashboard?A. /var/www/html/openstack-dashboard/local_settings
B. /etc/openstack-dashboard/local_settings
C. /etc/horizon/horizon.conf
D. /etc/horizon/local_settings
Answer:
B. /etc/openstack-dashboard/local_settings
OpenStack Object Storage
How can you upload all of the files from the ~user directory to the container tempcontainer?A. swift upload tempcontainer ~user/all
B. swift upload tempcontainer ~user/*
C. swift upload ~user/* tempcontainer
D. swift upload ~user/* tempcontainer all
Answer:
B. swift upload tempcontainer ~user/*
How can you check the status of the object test in container cont ?
A. swift stat test cont
B. swift cont test stat
C. swift stat cont test
D. swift test cont stat
Answer:
C. swift stat cont test
How can you get disk usage stats in Swift?
A. recon -l
B. swift-recon -d
C. swift-recon -l
D. recon -d
Answer:
B. swift-recon -d
How can you get a list of all objects in test container?
A. swift list test
B. swift test list
C. swift list
D. swift list container test
Answer:
A. swift list test
How can you get the object with curl command?
A. curl -X GET -H ‘X-Auth-Token: token’ http://server/AUTH_User/container/object
B. curl -X GET -H ‘X-Auth-Token: token’ http://server/v1/AUTH_User/ -c container -o object
C. curl -X GET -H ‘X-Auth-Token: token’ http://server/v1/AUTH_User/container/object
D. curl -X GET -H ‘X-Auth-Token: token’ http://server/AUTH_User/container object
Answer:
C. curl -X GET -H ‘X-Auth-Token: token’ http://server/v1/AUTH_User/container/object
OpenStack Block Storage
How many cinder-volume services exist in a typical installation?A. One.
B. At least three.
C. One per storage back end.
D. One per database instance.
Answer:
C. One per storage back end.
What parameter in the configuration file defines the public Identity API endpoint?
A. auth_uri
B. auth_ure
C. auth_url
D. auth_url_public
Answer:
A. auth_uri
How can you create a volume with a name test and the size 1GB?
A. openstack volume create test 1
B. cinder create –name test
C. openstack volumes create –size 1 test
D. cinder create –display-name test 1
Answer:
D. cinder create --display-name test 1
What is the Linux LVM partition number?
A. 82
B. 8e
C. 83
D. 1F
Answer:
B. 8e
How does Cinder back up differ from snapshot (choose two)?
A. Back up is stored in Glance.
B. Back up is stored in Swift.
C. Back up can’t be incremental.
D. Back up can be incremental.
Answer:
B. Back up is stored in Swift.
D. Back up can be incremental.
Orchestration of OpenStack
How can the status of the running stack be checked?A. heat event-list mystack
B. heat stack-show mystack
C. heat stack-check mystack
D. heat template-show mystack
Answer:
B. heat stack-show mystack
How can you run a stack (choose all applicable)?
A. heat stack-create -f Hello-World.yml -P network=private -P image=cirros stack
B. heat stack-create -f Hello-World.yml -P network=192.168.0.0/-P image=cirros stack
C. heat stack-create -f Hello-World.yml -P network=private stack
D. heat stack-create -f Hello-World.yml -P image=cirros stack
Answer:
A. heat stack-create -f Hello-World.yml -P network=private -P image=cirros stack
C. heat stack-create -f Hello-World.yml -P network=private stack
D. heat stack-create -f Hello-World.yml -P image=cirros stack
Which service accepts CloudFormation REST API calls for templates processing?
A. heat-api-cloudwatch
B. heat-cfn
C. heat-api-cfn
D. heat-api
Answer:
C. heat-api-cfn
How would you see the stack output (choose all applicable)?
A. heat output-list mystack
B. heat output-show mystack
C. heat stack-show mystack
D. heat stack-list mystack
Answer:
A. heat output-list mystack
C. heat stack-show mystack
Is it possible to update a stack?
A. Yes, only when stack is suspended.
B. Yes, you can update running stack.
C. No.
Answer:
B. Yes, you can update running stack.
Troubleshooting OpenStack
How would you search for the Identity Service configuration files in a configuration directory hierarchy?A. find /etc -name keystone*
B. find /etc –name heat*
C. find /var –name keystone*
D. find / –name heat*
Answer:
A. find /etc -name keystone*
Where would you find all of the messages from Cinder service (choose all applicable)?
A. /var/log/messages
B. /var/log/cinder/api.log
C. /var/log/cinder/scheduler.log
D. /var/log/cinder/backup.log
Answer:
A. /var/log/messages
B. /var/log/cinder/api.log
C. /var/log/cinder/scheduler.log
D. /var/log/cinder/backup.log
How would you back up all the OpenStack databases?
A. mysqlbackup –opt –all-db > /tmp/all-openstack.sql
B. mysqlbackup –opt –all-databases > /tmp/all-openstack.sql
C. mysqldump –opt –all-db > /tmp/all-openstack.sql
D. mysqldump –opt –all-databases > /tmp/all-openstack.sql
Answer:
D. mysqldump --opt --all-databases > /tmp/all-openstack.sql
How would you enumerate all the compute hosts (choose all applicable)?
A. openstack hypervisor list
B. openstack host list
C. nova host-enumerate
D. nova hypervisor-list
Answer:
B. openstack host list
D. nova hypervisor-list
How would you check the status of the RabbitMQ messaging server?
A. rabbitmqctl stat
B. rabbitmq status
C. rabbitmqctl status
D. rabbitmq state
Answer:
C. rabbitmqctl status
How would you get a list of all virtual machines?
A. openstack vm list
B. openstack server list
C. openstack host list
D. openstack instance list
Answer:
B. openstack server list
How would you check the status of the Neutron agents?
A. neutron agent-list
B. neutron plugin-list
C. openstack agent list
D. openstack network list
Answer:
A. neutron agent-list
How would you get the details of a given router?
A. neutron router list router
B. neutron router show router
C. openstack router list router
D. openstack router show router
Answer:
D. openstack router show router