This file is indexed.

/usr/share/doc/python-glance-doc/html/configuring.html is in python-glance-doc 1:2014.1.5-0ubuntu1.1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

   1
   2
   3
   4
   5
   6
   7
   8
   9
  10
  11
  12
  13
  14
  15
  16
  17
  18
  19
  20
  21
  22
  23
  24
  25
  26
  27
  28
  29
  30
  31
  32
  33
  34
  35
  36
  37
  38
  39
  40
  41
  42
  43
  44
  45
  46
  47
  48
  49
  50
  51
  52
  53
  54
  55
  56
  57
  58
  59
  60
  61
  62
  63
  64
  65
  66
  67
  68
  69
  70
  71
  72
  73
  74
  75
  76
  77
  78
  79
  80
  81
  82
  83
  84
  85
  86
  87
  88
  89
  90
  91
  92
  93
  94
  95
  96
  97
  98
  99
 100
 101
 102
 103
 104
 105
 106
 107
 108
 109
 110
 111
 112
 113
 114
 115
 116
 117
 118
 119
 120
 121
 122
 123
 124
 125
 126
 127
 128
 129
 130
 131
 132
 133
 134
 135
 136
 137
 138
 139
 140
 141
 142
 143
 144
 145
 146
 147
 148
 149
 150
 151
 152
 153
 154
 155
 156
 157
 158
 159
 160
 161
 162
 163
 164
 165
 166
 167
 168
 169
 170
 171
 172
 173
 174
 175
 176
 177
 178
 179
 180
 181
 182
 183
 184
 185
 186
 187
 188
 189
 190
 191
 192
 193
 194
 195
 196
 197
 198
 199
 200
 201
 202
 203
 204
 205
 206
 207
 208
 209
 210
 211
 212
 213
 214
 215
 216
 217
 218
 219
 220
 221
 222
 223
 224
 225
 226
 227
 228
 229
 230
 231
 232
 233
 234
 235
 236
 237
 238
 239
 240
 241
 242
 243
 244
 245
 246
 247
 248
 249
 250
 251
 252
 253
 254
 255
 256
 257
 258
 259
 260
 261
 262
 263
 264
 265
 266
 267
 268
 269
 270
 271
 272
 273
 274
 275
 276
 277
 278
 279
 280
 281
 282
 283
 284
 285
 286
 287
 288
 289
 290
 291
 292
 293
 294
 295
 296
 297
 298
 299
 300
 301
 302
 303
 304
 305
 306
 307
 308
 309
 310
 311
 312
 313
 314
 315
 316
 317
 318
 319
 320
 321
 322
 323
 324
 325
 326
 327
 328
 329
 330
 331
 332
 333
 334
 335
 336
 337
 338
 339
 340
 341
 342
 343
 344
 345
 346
 347
 348
 349
 350
 351
 352
 353
 354
 355
 356
 357
 358
 359
 360
 361
 362
 363
 364
 365
 366
 367
 368
 369
 370
 371
 372
 373
 374
 375
 376
 377
 378
 379
 380
 381
 382
 383
 384
 385
 386
 387
 388
 389
 390
 391
 392
 393
 394
 395
 396
 397
 398
 399
 400
 401
 402
 403
 404
 405
 406
 407
 408
 409
 410
 411
 412
 413
 414
 415
 416
 417
 418
 419
 420
 421
 422
 423
 424
 425
 426
 427
 428
 429
 430
 431
 432
 433
 434
 435
 436
 437
 438
 439
 440
 441
 442
 443
 444
 445
 446
 447
 448
 449
 450
 451
 452
 453
 454
 455
 456
 457
 458
 459
 460
 461
 462
 463
 464
 465
 466
 467
 468
 469
 470
 471
 472
 473
 474
 475
 476
 477
 478
 479
 480
 481
 482
 483
 484
 485
 486
 487
 488
 489
 490
 491
 492
 493
 494
 495
 496
 497
 498
 499
 500
 501
 502
 503
 504
 505
 506
 507
 508
 509
 510
 511
 512
 513
 514
 515
 516
 517
 518
 519
 520
 521
 522
 523
 524
 525
 526
 527
 528
 529
 530
 531
 532
 533
 534
 535
 536
 537
 538
 539
 540
 541
 542
 543
 544
 545
 546
 547
 548
 549
 550
 551
 552
 553
 554
 555
 556
 557
 558
 559
 560
 561
 562
 563
 564
 565
 566
 567
 568
 569
 570
 571
 572
 573
 574
 575
 576
 577
 578
 579
 580
 581
 582
 583
 584
 585
 586
 587
 588
 589
 590
 591
 592
 593
 594
 595
 596
 597
 598
 599
 600
 601
 602
 603
 604
 605
 606
 607
 608
 609
 610
 611
 612
 613
 614
 615
 616
 617
 618
 619
 620
 621
 622
 623
 624
 625
 626
 627
 628
 629
 630
 631
 632
 633
 634
 635
 636
 637
 638
 639
 640
 641
 642
 643
 644
 645
 646
 647
 648
 649
 650
 651
 652
 653
 654
 655
 656
 657
 658
 659
 660
 661
 662
 663
 664
 665
 666
 667
 668
 669
 670
 671
 672
 673
 674
 675
 676
 677
 678
 679
 680
 681
 682
 683
 684
 685
 686
 687
 688
 689
 690
 691
 692
 693
 694
 695
 696
 697
 698
 699
 700
 701
 702
 703
 704
 705
 706
 707
 708
 709
 710
 711
 712
 713
 714
 715
 716
 717
 718
 719
 720
 721
 722
 723
 724
 725
 726
 727
 728
 729
 730
 731
 732
 733
 734
 735
 736
 737
 738
 739
 740
 741
 742
 743
 744
 745
 746
 747
 748
 749
 750
 751
 752
 753
 754
 755
 756
 757
 758
 759
 760
 761
 762
 763
 764
 765
 766
 767
 768
 769
 770
 771
 772
 773
 774
 775
 776
 777
 778
 779
 780
 781
 782
 783
 784
 785
 786
 787
 788
 789
 790
 791
 792
 793
 794
 795
 796
 797
 798
 799
 800
 801
 802
 803
 804
 805
 806
 807
 808
 809
 810
 811
 812
 813
 814
 815
 816
 817
 818
 819
 820
 821
 822
 823
 824
 825
 826
 827
 828
 829
 830
 831
 832
 833
 834
 835
 836
 837
 838
 839
 840
 841
 842
 843
 844
 845
 846
 847
 848
 849
 850
 851
 852
 853
 854
 855
 856
 857
 858
 859
 860
 861
 862
 863
 864
 865
 866
 867
 868
 869
 870
 871
 872
 873
 874
 875
 876
 877
 878
 879
 880
 881
 882
 883
 884
 885
 886
 887
 888
 889
 890
 891
 892
 893
 894
 895
 896
 897
 898
 899
 900
 901
 902
 903
 904
 905
 906
 907
 908
 909
 910
 911
 912
 913
 914
 915
 916
 917
 918
 919
 920
 921
 922
 923
 924
 925
 926
 927
 928
 929
 930
 931
 932
 933
 934
 935
 936
 937
 938
 939
 940
 941
 942
 943
 944
 945
 946
 947
 948
 949
 950
 951
 952
 953
 954
 955
 956
 957
 958
 959
 960
 961
 962
 963
 964
 965
 966
 967
 968
 969
 970
 971
 972
 973
 974
 975
 976
 977
 978
 979
 980
 981
 982
 983
 984
 985
 986
 987
 988
 989
 990
 991
 992
 993
 994
 995
 996
 997
 998
 999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Basic Configuration &mdash; Glance 2014.1.5 documentation</title>
    
    <link rel="stylesheet" href="_static/nature.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    <link rel="stylesheet" href="_static/tweaks.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    './',
        VERSION:     '2014.1.5',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="top" title="Glance 2014.1.5 documentation" href="index.html" />
    <link rel="next" title="Authentication With Keystone" href="authentication.html" />
    <link rel="prev" title="Installation" href="installing.html" /> 
  </head>
  <body>
  <div id="header">
    <h1 id="logo"><a href="http://www.openstack.org/">OpenStack</a></h1>
    <ul id="navigation">
      
      <li><a href="http://www.openstack.org/" title="Go to the Home page" class="link">Home</a></li>
      <li><a href="http://www.openstack.org/projects/" title="Go to the OpenStack Projects page">Projects</a></li>
      <li><a href="http://www.openstack.org/user-stories/" title="Go to the User Stories page" class="link">User Stories</a></li>
      <li><a href="http://www.openstack.org/community/" title="Go to the Community page" class="link">Community</a></li>
      <li><a href="http://www.openstack.org/blog/" title="Go to the OpenStack Blog">Blog</a></li>
      <li><a href="http://wiki.openstack.org/" title="Go to the OpenStack Wiki">Wiki</a></li>
      <li><a href="http://docs.openstack.org/" title="Go to OpenStack Documentation" class="current">Documentation</a></li>
      
    </ul>
  </div>
  

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="basic-configuration">
<h1>Basic Configuration<a class="headerlink" href="#basic-configuration" title="Permalink to this headline"></a></h1>
<p>Glance has a number of options that you can use to configure the Glance API
server, the Glance Registry server, and the various storage backends that
Glance can use to store images.</p>
<p>Most configuration is done via configuration files, with the Glance API
server and Glance Registry server using separate configuration files.</p>
<p>When starting up a Glance server, you can specify the configuration file to
use (see <a class="reference internal" href="controllingservers.html"><em>the documentation on controller Glance servers</em></a>).
If you do <strong>not</strong> specify a configuration file, Glance will look in the following
directories for a configuration file, in order:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">~/.glance</span></tt></li>
<li><tt class="docutils literal"><span class="pre">~/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/etc/glance</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/etc</span></tt></li>
</ul>
<p>The Glance API server configuration file should be named <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt>.
Similarly, the Glance Registry server configuration file should be named
<tt class="docutils literal"><span class="pre">glance-registry.conf</span></tt>. If you installed Glance via your operating system&#8217;s
package management system, it is likely that you will have sample
configuration files installed in <tt class="docutils literal"><span class="pre">/etc/glance</span></tt>.</p>
<p>In addition to this documentation page, you can check the
<tt class="docutils literal"><span class="pre">etc/glance-api.conf</span></tt> and <tt class="docutils literal"><span class="pre">etc/glance-registry.conf</span></tt> sample configuration
files distributed with Glance for example configuration files for each server
application with detailed comments on what each options does.</p>
<p>The PasteDeploy configuration (controlling the deployment of the WSGI
application for each component) may be found by default in
&lt;component&gt;-paste.ini alongside the main configuration file, &lt;component&gt;.conf.
For example, <tt class="docutils literal"><span class="pre">glance-api-paste.ini</span></tt> corresponds to <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt>.
This pathname for the paste config is configurable, as follows:</p>
<div class="highlight-python"><div class="highlight"><pre>[paste_deploy]
config_file = /path/to/paste/config
</pre></div>
</div>
<div class="section" id="common-configuration-options-in-glance">
<h2>Common Configuration Options in Glance<a class="headerlink" href="#common-configuration-options-in-glance" title="Permalink to this headline"></a></h2>
<p>Glance has a few command-line options that are common to all Glance programs:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">--verbose</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can be specified on the command line and in configuration files.</p>
<p>Turns on the INFO level in logging and prints more verbose command-line
interface printouts.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">--debug</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can be specified on the command line and in configuration files.</p>
<p>Turns on the DEBUG level in logging.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">--config-file=PATH</span></tt></li>
</ul>
<p>Optional. Default: See below for default search order.</p>
<p>Specified on the command line only.</p>
<p>Takes a path to a configuration file to use when running the program. If this
CLI option is not specified, then we check to see if the first argument is a
file. If it is, then we try to use that as the configuration file. If there is
no file or there were no arguments, we search for a configuration file in the
following order:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">~/.glance</span></tt></li>
<li><tt class="docutils literal"><span class="pre">~/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/etc/glance</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/etc</span></tt></li>
</ul>
<p>The filename that is searched for depends on the server application name. So,
if you are starting up the API server, <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> is searched for,
otherwise <tt class="docutils literal"><span class="pre">glance-registry.conf</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">--config-dir=DIR</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Specified on the command line only.</p>
<p>Takes a path to a configuration directory from which all *.conf fragments
are loaded. This provides an alternative to multiple &#8211;config-file options
when it is inconvenient to explicitly enumerate all the config files, for
example when an unknown number of config fragments are being generated
by a deployment framework.</p>
<p>If &#8211;config-dir is set, then &#8211;config-file is ignored.</p>
<p>An example usage would be:</p>
<blockquote>
<div><p>$ glance-api &#8211;config-dir=/etc/glance/glance-api.d</p>
<dl class="docutils">
<dt>$ ls /etc/glance/glance-api.d</dt>
<dd>00-core.conf
01-s3.conf
02-swift.conf
03-ssl.conf
... etc.</dd>
</dl>
</div></blockquote>
<p>The numeric prefixes in the example above are only necessary if a specific
parse ordering is required (i.e. if an individual config option set in an
earlier fragment is overridden in a later fragment).</p>
</div>
<div class="section" id="configuring-server-startup-options">
<h2>Configuring Server Startup Options<a class="headerlink" href="#configuring-server-startup-options" title="Permalink to this headline"></a></h2>
<p>You can put the following options in the <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> and
<tt class="docutils literal"><span class="pre">glance-registry.conf</span></tt> files, under the <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt> section. They enable
startup and binding behaviour for the API and registry servers, respectively.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">bind_host=ADDRESS</span></tt></li>
</ul>
<p>The address of the host to bind to.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">0.0.0.0</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">bind_port=PORT</span></tt></li>
</ul>
<p>The port the server should bind to.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">9191</span></tt> for the registry server, <tt class="docutils literal"><span class="pre">9292</span></tt> for the API server</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">backlog=REQUESTS</span></tt></li>
</ul>
<p>Number of backlog requests to configure the socket with.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">4096</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">tcp_keepidle=SECONDS</span></tt></li>
</ul>
<p>Sets the value of TCP_KEEPIDLE in seconds for each server socket.
Not supported on OS X.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">600</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">workers=PROCESSES</span></tt></li>
</ul>
<p>Number of Glance API worker processes to start. Each worker
process will listen on the same port. Increasing this
value may increase performance (especially if using SSL
with compression enabled). Typically it is recommended
to have one worker process per CPU. The value <cite>0</cite> will
prevent any new processes from being created.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">1</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">db_auto_create=False</span></tt></li>
</ul>
<p>Whether to automatically create the database tables.  Otherwise you can
manually run <cite>glance-manage db sync</cite>.</p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<div class="section" id="configuring-ssl-support">
<h3>Configuring SSL Support<a class="headerlink" href="#configuring-ssl-support" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cert_file=PATH</span></tt></li>
</ul>
<p>Path to the certificate file the server should use when binding to an
SSL-wrapped socket.</p>
<p>Optional. Default: not enabled.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">key_file=PATH</span></tt></li>
</ul>
<p>Path to the private key file the server should use when binding to an
SSL-wrapped socket.</p>
<p>Optional. Default: not enabled.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">ca_file=PATH</span></tt></li>
</ul>
<p>Path to the CA certificate file the server should use to validate client
certificates provided during an SSL handshake. This is ignored if
<tt class="docutils literal"><span class="pre">cert_file</span></tt> and &#8216;&#8217;key_file`` are not set.</p>
<p>Optional. Default: not enabled.</p>
</div>
<div class="section" id="configuring-registry-access">
<h3>Configuring Registry Access<a class="headerlink" href="#configuring-registry-access" title="Permalink to this headline"></a></h3>
<p>There are a number of configuration options in Glance that control how
the API server accesses the registry server.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_protocol=PROTOCOL</span></tt></li>
</ul>
<p>If you run a secure Registry server, you need to set this value to <tt class="docutils literal"><span class="pre">https</span></tt>
and also set <tt class="docutils literal"><span class="pre">registry_client_key_file</span></tt> and optionally
<tt class="docutils literal"><span class="pre">registry_client_cert_file</span></tt>.</p>
<p>Optional. Default: http</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_key_file=PATH</span></tt></li>
</ul>
<p>The path to the key file to use in SSL connections to the
registry server, if any. Alternately, you may set the
<tt class="docutils literal"><span class="pre">GLANCE_CLIENT_KEY_FILE</span></tt> environ variable to a filepath of the key file</p>
<p>Optional. Default: Not set.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_cert_file=PATH</span></tt></li>
</ul>
<p>Optional. Default: Not set.</p>
<p>The path to the cert file to use in SSL connections to the
registry server, if any. Alternately, you may set the
<tt class="docutils literal"><span class="pre">GLANCE_CLIENT_CERT_FILE</span></tt> environ variable to a filepath of the cert file</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_ca_file=PATH</span></tt></li>
</ul>
<p>Optional. Default: Not set.</p>
<p>The path to a Certifying Authority&#8217;s cert file to use in SSL connections to the
registry server, if any. Alternately, you may set the
<tt class="docutils literal"><span class="pre">GLANCE_CLIENT_CA_FILE</span></tt> environ variable to a filepath of the CA cert file</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_insecure=False</span></tt></li>
</ul>
<p>Optional. Default: False.</p>
<p>When using SSL in connections to the registry server, do not require
validation via a certifying authority. This is the registry&#8217;s equivalent of
specifying &#8211;insecure on the command line using glanceclient for the API</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">registry_client_timeout=SECONDS</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">600</span></tt>.</p>
<p>The period of time, in seconds, that the API server will wait for a registry
request to complete. A value of &#8216;0&#8217; implies no timeout.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">use_user_token=True</span></tt></li>
</ul>
<p>Optional. Default: True</p>
<p>Pass the user token through for API requests to the registry.</p>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified (see below). If admin credentials are specified then they are
used to generate a token; this token rather than the original user&#8217;s
token is used for requests to the registry.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">admin_user=USER</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the username.</p>
<p>Optional. Default: None</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">admin_password=PASSWORD</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the password.</p>
<p>Optional. Default: None</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">admin_tenant_name=TENANTNAME</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the tenant name.</p>
<p>Optional. Default: None</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">auth_url=URL</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the Keystone endpoint.</p>
<p>Optional. Default: None</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">auth_strategy=STRATEGY</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the auth strategy.</p>
<p>Optional. Default: keystone</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">auth_region=REGION</span></tt></li>
</ul>
<p>If &#8216;use_user_token&#8217; is not in effect then admin credentials can be
specified. Use this parameter to specify the region.</p>
<p>Optional. Default: None</p>
</div>
</div>
<div class="section" id="configuring-logging-in-glance">
<h2>Configuring Logging in Glance<a class="headerlink" href="#configuring-logging-in-glance" title="Permalink to this headline"></a></h2>
<p>There are a number of configuration options in Glance that control how Glance
servers log messages.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">--log-config=PATH</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Specified on the command line only.</p>
<p>Takes a path to a configuration file to use for configuring logging.</p>
<div class="section" id="logging-options-available-only-in-configuration-files">
<h3>Logging Options Available Only in Configuration Files<a class="headerlink" href="#logging-options-available-only-in-configuration-files" title="Permalink to this headline"></a></h3>
<p>You will want to place the different logging options in the <strong>[DEFAULT]</strong> section
in your application configuration file. As an example, you might do the following
for the API server, in a configuration file called <tt class="docutils literal"><span class="pre">etc/glance-api.conf</span></tt>:</p>
<div class="highlight-python"><div class="highlight"><pre>[DEFAULT]
log_file = /var/log/glance/api.log
</pre></div>
</div>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">log_file</span></tt></li>
</ul>
<p>The filepath of the file to use for logging messages from Glance&#8217;s servers. If
missing, the default is to output messages to <tt class="docutils literal"><span class="pre">stdout</span></tt>, so if you are running
Glance servers in a daemon mode (using <tt class="docutils literal"><span class="pre">glance-control</span></tt>) you should make
sure that the <tt class="docutils literal"><span class="pre">log_file</span></tt> option is set appropriately.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">log_dir</span></tt></li>
</ul>
<p>The filepath of the directory to use for log files. If not specified (the default)
the <tt class="docutils literal"><span class="pre">log_file</span></tt> is used as an absolute filepath.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">log_date_format</span></tt></li>
</ul>
<p>The format string for timestamps in the log output.</p>
<p>Defaults to <tt class="docutils literal"><span class="pre">%Y-%m-%d</span> <span class="pre">%H:%M:%S</span></tt>. See the
<a class="reference external" href="http://docs.python.org/library/logging.html">logging module</a> documentation for
more information on setting this format string.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">log_use_syslog</span></tt></li>
</ul>
<p>Use syslog logging functionality.</p>
<p>Defaults to False.</p>
</div>
</div>
<div class="section" id="configuring-glance-storage-backends">
<h2>Configuring Glance Storage Backends<a class="headerlink" href="#configuring-glance-storage-backends" title="Permalink to this headline"></a></h2>
<p>There are a number of configuration options in Glance that control how Glance
stores disk images. These configuration options are specified in the
<tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> config file in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">default_store=STORE</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">file</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Sets the storage backend to use by default when storing images in Glance.
Available options for this option are (<tt class="docutils literal"><span class="pre">file</span></tt>, <tt class="docutils literal"><span class="pre">swift</span></tt>, <tt class="docutils literal"><span class="pre">s3</span></tt>, <tt class="docutils literal"><span class="pre">rbd</span></tt>, <tt class="docutils literal"><span class="pre">sheepdog</span></tt>,
<tt class="docutils literal"><span class="pre">cinder</span></tt> or <tt class="docutils literal"><span class="pre">vsphere</span></tt>).</p>
</div>
<div class="section" id="configuring-glance-image-size-limit">
<h2>Configuring Glance Image Size Limit<a class="headerlink" href="#configuring-glance-image-size-limit" title="Permalink to this headline"></a></h2>
<p>The following configuration option is specified in the
<tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> config file in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">image_size_cap=SIZE</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">1099511627776</span></tt> (1 TB)</p>
<p>Maximum image size, in bytes, which can be uploaded through the Glance API server.</p>
<p><strong>IMPORTANT NOTE</strong>: this value should only be increased after careful consideration
and must be set to a value under 8 EB (9223372036854775808).</p>
</div>
<div class="section" id="configuring-glance-user-storage-quota">
<h2>Configuring Glance User Storage Quota<a class="headerlink" href="#configuring-glance-user-storage-quota" title="Permalink to this headline"></a></h2>
<p>The following configuration option is specified in the
<tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> config file in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">user_storage_quota</span></tt></li>
</ul>
<p>Optional. Default: 0 (Unlimited).</p>
<p>This value specifies the maximum amount of bytes that each user can use
across all storage systems.</p>
<div class="section" id="configuring-the-filesystem-storage-backend">
<h3>Configuring the Filesystem Storage Backend<a class="headerlink" href="#configuring-the-filesystem-storage-backend" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">filesystem_store_datadir=PATH</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">/var/lib/glance/images/</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the filesystem storage backend.</cite></p>
<p>Sets the path where the filesystem storage backend write disk images. Note that
the filesystem storage backend will attempt to create this directory if it does
not exist. Ensure that the user that <tt class="docutils literal"><span class="pre">glance-api</span></tt> runs under has write
permissions to this directory.</p>
</div>
<div class="section" id="configuring-the-filesystem-storage-backend-with-multiple-stores">
<h3>Configuring the Filesystem Storage Backend with multiple stores<a class="headerlink" href="#configuring-the-filesystem-storage-backend-with-multiple-stores" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">filesystem_store_datadirs=PATH:PRIORITY</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">/var/lib/glance/images/:1</span></tt></p>
<p>Example:</p>
<div class="highlight-python"><div class="highlight"><pre>filesystem_store_datadirs = /var/glance/store
filesystem_store_datadirs = /var/glance/store1:100
filesystem_store_datadirs = /var/glance/store2:200
</pre></div>
</div>
<p>This option can only be specified in configuration file and is specific
to the filesystem storage backend only.</p>
<p>filesystem_store_datadirs option allows administrators to configure
multiple store directories to save glance image in filesystem storage backend.
Each directory can be coupled with its priority.</p>
<p><strong>NOTE</strong>:</p>
<ul class="simple">
<li>This option can be specified multiple times to specify multiple stores.</li>
<li>Either filesystem_store_datadir or filesystem_store_datadirs option must be
specified in glance-api.conf</li>
<li>Store with priority 200 has precedence over store with priority 100.</li>
<li>If no priority is specified, default priority &#8216;0&#8217; is associated with it.</li>
<li>If two filesystem stores have same priority store with maximum free space
will be chosen to store the image.</li>
<li>If same store is specified multiple times then BadStoreConfiguration
exception will be raised.</li>
</ul>
</div>
<div class="section" id="configuring-the-swift-storage-backend">
<h3>Configuring the Swift Storage Backend<a class="headerlink" href="#configuring-the-swift-storage-backend" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_auth_address=URL</span></tt></li>
</ul>
<p>Required when using the Swift storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Sets the authentication URL supplied to Swift when making calls to its storage
system. For more information about the Swift authentication system, please
see the <a class="reference external" href="http://swift.openstack.org/overview_auth.html">Swift auth</a>
documentation and the
<a class="reference external" href="http://docs.openstack.org/openstack-object-storage/admin/content/ch02s02.html">overview of Swift authentication</a>.</p>
<p><strong>IMPORTANT NOTE</strong>: Swift authentication addresses use HTTPS by default. This
means that if you are running Swift with authentication over HTTP, you need
to set your <tt class="docutils literal"><span class="pre">swift_store_auth_address</span></tt> to the full URL, including the <tt class="docutils literal"><span class="pre">http://</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_user=USER</span></tt></li>
</ul>
<p>Required when using the Swift storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Sets the user to authenticate against the <tt class="docutils literal"><span class="pre">swift_store_auth_address</span></tt> with.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_key=KEY</span></tt></li>
</ul>
<p>Required when using the Swift storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Sets the authentication key to authenticate against the
<tt class="docutils literal"><span class="pre">swift_store_auth_address</span></tt> with for the user <tt class="docutils literal"><span class="pre">swift_store_user</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_container=CONTAINER</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">glance</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Sets the name of the container to use for Glance images in Swift.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_create_container_on_put</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>If true, Glance will attempt to create the container <tt class="docutils literal"><span class="pre">swift_store_container</span></tt>
if it does not exist.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_large_object_size=SIZE_IN_MB</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">5120</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>What size, in MB, should Glance start chunking image files
and do a large object manifest in Swift? By default, this is
the maximum object size in Swift, which is 5GB</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_large_object_chunk_size=SIZE_IN_MB</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">200</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>When doing a large object manifest, what size, in MB, should
Glance write chunks to Swift?  The default is 200MB.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_multi_tenant=False</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>If set to True enables multi-tenant storage mode which causes Glance images
to be stored in tenant specific Swift accounts. When set to False Glance
stores all images in a single Swift account.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_admin_tenants</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: Not set.</p>
<p>A list of swift ACL strings that will be applied as both read and
write ACLs to the containers created by Glance in multi-tenant
mode. This grants the specified tenants/users read and write access
to all newly created image objects. The standard swift ACL string
formats are allowed, including:</p>
<p>&lt;tenant_id&gt;:&lt;username&gt;
&lt;tenant_name&gt;:&lt;username&gt;
*:&lt;username&gt;</p>
<p>Multiple ACLs can be combined using a comma separated list, for
example: swift_store_admin_tenants = <a class="reference external" href="service:glance,*:admin">service:glance,*:admin</a></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_auth_version</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">2</span></tt></p>
<p>A string indicating which version of Swift OpenStack authentication
to use. See the project
<a class="reference external" href="http://docs.openstack.org/developer/python-swiftclient/">python-swiftclient</a>
for more details.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_service_type</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">object-store</span></tt></p>
<p>A string giving the service type of the swift service to use. This
setting is only used if swift_store_auth_version is <tt class="docutils literal"><span class="pre">2</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_region</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: Not set.</p>
<p>A string giving the region of the swift service endpoint to use. This
setting is only used if swift_store_auth_version is <tt class="docutils literal"><span class="pre">2</span></tt>. This
setting is especially useful for disambiguation if multiple swift
services might appear in a service catalog during authentication.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_endpoint_type</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">publicURL</span></tt></p>
<p>A string giving the endpoint type of the swift service endpoint to
use. This setting is only used if swift_store_auth_version is <tt class="docutils literal"><span class="pre">2</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_ssl_compression</span></tt></li>
</ul>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: True.</p>
<p>If set to False, disables SSL layer compression of https swift
requests. Setting to &#8216;False&#8217; may improve performance for images which
are already in a compressed format, eg qcow2. If set to True then
compression will be enabled (provided it is supported by the swift
proxy).</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">swift_store_retry_get_count</span></tt></li>
</ul>
<p>The number of times a Swift download will be retried before the request
fails.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Swift storage backend.</cite></p>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">0</span></tt></p>
</div>
<div class="section" id="configuring-the-s3-storage-backend">
<h3>Configuring the S3 Storage Backend<a class="headerlink" href="#configuring-the-s3-storage-backend" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_host=URL</span></tt></li>
</ul>
<p>Required when using the S3 storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>Default: s3.amazonaws.com</p>
<p>Sets the main service URL supplied to S3 when making calls to its storage
system. For more information about the S3 authentication system, please
see the <a class="reference external" href="http://aws.amazon.com/documentation/s3/">S3 documentation</a></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_access_key=ACCESS_KEY</span></tt></li>
</ul>
<p>Required when using the S3 storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>Sets the access key to authenticate against the <tt class="docutils literal"><span class="pre">s3_store_host</span></tt> with.</p>
<p>You should set this to your 20-character Amazon AWS access key.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_secret_key=SECRET_KEY</span></tt></li>
</ul>
<p>Required when using the S3 storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>Sets the secret key to authenticate against the
<tt class="docutils literal"><span class="pre">s3_store_host</span></tt> with for the access key <tt class="docutils literal"><span class="pre">s3_store_access_key</span></tt>.</p>
<p>You should set this to your 40-character Amazon AWS secret key.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_bucket=BUCKET</span></tt></li>
</ul>
<p>Required when using the S3 storage backend.</p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>Sets the name of the bucket to use for Glance images in S3.</p>
<p>Note that the namespace for S3 buckets is <strong>global</strong>,
therefore you must use a name for the bucket that is unique. It
is recommended that you use a combination of your AWS access key,
<strong>lowercased</strong> with &#8220;glance&#8221;.</p>
<p>For instance if your Amazon AWS access key is:</p>
<p><tt class="docutils literal"><span class="pre">ABCDEFGHIJKLMNOPQRST</span></tt></p>
<p>then make your bucket value be:</p>
<p><tt class="docutils literal"><span class="pre">abcdefghijklmnopqrstglance</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_create_bucket_on_put</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>If true, Glance will attempt to create the bucket <tt class="docutils literal"><span class="pre">s3_store_bucket</span></tt>
if it does not exist.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">s3_store_object_buffer_dir=PATH</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">the</span> <span class="pre">platform's</span> <span class="pre">default</span> <span class="pre">temporary</span> <span class="pre">directory</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the S3 storage backend.</cite></p>
<p>When sending images to S3, what directory should be
used to buffer the chunks? By default the platform&#8217;s
temporary directory will be used.</p>
</div>
<div class="section" id="configuring-the-rbd-storage-backend">
<h3>Configuring the RBD Storage Backend<a class="headerlink" href="#configuring-the-rbd-storage-backend" title="Permalink to this headline"></a></h3>
<p><strong>Note</strong>: the RBD storage backend requires the python bindings for
librados and librbd. These are in the python-ceph package on
Debian-based distributions.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rbd_store_pool=POOL</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">rbd</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the RBD storage backend.</cite></p>
<p>Sets the RADOS pool in which images are stored.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rbd_store_chunk_size=CHUNK_SIZE_MB</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">4</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the RBD storage backend.</cite></p>
<p>Images will be chunked into objects of this size (in megabytes).
For best performance, this should be a power of two.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rbd_store_ceph_conf=PATH</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">/etc/ceph/ceph.conf</span></tt>, <tt class="docutils literal"><span class="pre">~/.ceph/config</span></tt>, and <tt class="docutils literal"><span class="pre">./ceph.conf</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the RBD storage backend.</cite></p>
<p>Sets the Ceph configuration file to use.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rbd_store_user=NAME</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">admin</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the RBD storage backend.</cite></p>
<p>Sets the RADOS user to authenticate as. This is only needed
when <a class="reference external" href="http://ceph.newdream.net/wiki/Cephx">RADOS authentication</a>
is <a class="reference external" href="http://ceph.newdream.net/wiki/Cluster_configuration#Cephx_auth">enabled.</a></p>
<p>A keyring must be set for this user in the Ceph
configuration file, e.g. with a user <tt class="docutils literal"><span class="pre">glance</span></tt>:</p>
<div class="highlight-python"><div class="highlight"><pre>[client.glance]
keyring=/etc/glance/rbd.keyring
</pre></div>
</div>
<p>To set up a user named <tt class="docutils literal"><span class="pre">glance</span></tt> with minimal permissions, using a pool called
<tt class="docutils literal"><span class="pre">images</span></tt>, run:</p>
<div class="highlight-python"><div class="highlight"><pre>rados mkpool images
ceph-authtool --create-keyring /etc/glance/rbd.keyring
ceph-authtool --gen-key --name client.glance --cap mon &#39;allow r&#39; --cap osd &#39;allow rwx pool=images&#39; /etc/glance/rbd.keyring
ceph auth add client.glance -i /etc/glance/rbd.keyring
</pre></div>
</div>
</div>
<div class="section" id="configuring-the-sheepdog-storage-backend">
<h3>Configuring the Sheepdog Storage Backend<a class="headerlink" href="#configuring-the-sheepdog-storage-backend" title="Permalink to this headline"></a></h3>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">sheepdog_store_address=ADDR</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">localhost</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Sheepdog storage backend.</cite></p>
<p>Sets the IP address of the sheep daemon</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">sheepdog_store_port=PORT</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">7000</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Sheepdog storage backend.</cite></p>
<p>Sets the IP port of the sheep daemon</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">sheepdog_store_chunk_size=SIZE_IN_MB</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">64</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Sheepdog storage backend.</cite></p>
<p>Images will be chunked into objects of this size (in megabytes).
For best performance, this should be a power of two.</p>
</div>
<div class="section" id="configuring-the-cinder-storage-backend">
<h3>Configuring the Cinder Storage Backend<a class="headerlink" href="#configuring-the-cinder-storage-backend" title="Permalink to this headline"></a></h3>
<p><strong>Note</strong>: Currently Cinder store is a partial implementation.
After Cinder expose &#8216;brick&#8217; library, and &#8216;Readonly-volume-attaching&#8217;,
&#8216;volume-multiple-attaching&#8217; enhancement ready, the store will support
&#8216;Upload&#8217; and &#8216;Download&#8217; interface finally.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cinder_catalog_info=&lt;service_type&gt;:&lt;service_name&gt;:&lt;endpoint_type&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">volume:cinder:publicURL</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p><cite>This option is specific to the Cinder storage backend.</cite></p>
<p>Sets the info to match when looking for cinder in the service catalog.
Format is : separated values of the form: &lt;service_type&gt;:&lt;service_name&gt;:&lt;endpoint_type&gt;</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cinder_endpoint_template=http://ADDR:PORT/VERSION/%(project_id)s</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Override service catalog lookup with template for cinder endpoint.
e.g. <a class="reference external" href="http://localhost:8776/v1/%(project_id)s">http://localhost:8776/v1/%(project_id)s</a></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">os_region_name=REGION_NAME</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Region name of this node.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cinder_ca_certificates_file=CA_FILE_PATH</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Location of ca certicates file to use for cinder client requests.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cinder_http_retries=TIMES</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">3</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Number of cinderclient retries on failed http calls.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">cinder_api_insecure=ON_OFF</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Allow to perform insecure SSL requests to cinder.</p>
</div>
</div>
<div class="section" id="configuring-the-image-cache">
<h2>Configuring the Image Cache<a class="headerlink" href="#configuring-the-image-cache" title="Permalink to this headline"></a></h2>
<p>Glance API servers can be configured to have a local image cache. Caching of
image files is transparent and happens using a piece of middleware that can
optionally be placed in the server application pipeline.</p>
<p>This pipeline is configured in the PasteDeploy configuration file,
&lt;component&gt;-paste.ini. You should not generally have to edit this file
directly, as it ships with ready-made pipelines for all common deployment
flavors.</p>
<div class="section" id="enabling-the-image-cache-middleware">
<h3>Enabling the Image Cache Middleware<a class="headerlink" href="#enabling-the-image-cache-middleware" title="Permalink to this headline"></a></h3>
<p>To enable the image cache middleware, the cache middleware must occur in
the application pipeline <strong>after</strong> the appropriate context middleware.</p>
<p>The cache middleware should be in your <tt class="docutils literal"><span class="pre">glance-api-paste.ini</span></tt> in a section
titled <tt class="docutils literal"><span class="pre">[filter:cache]</span></tt>. It should look like this:</p>
<div class="highlight-python"><div class="highlight"><pre>[filter:cache]
paste.filter_factory = glance.api.middleware.cache:CacheFilter.factory
</pre></div>
</div>
<p>A ready-made application pipeline including this filter is defined in
the <tt class="docutils literal"><span class="pre">glance-api-paste.ini</span></tt> file, looking like so:</p>
<div class="highlight-python"><div class="highlight"><pre>[pipeline:glance-api-caching]
pipeline = versionnegotiation context cache apiv1app
</pre></div>
</div>
<p>To enable the above application pipeline, in your main <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt>
configuration file, select the appropriate deployment flavor like so:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="n">paste_deploy</span><span class="p">]</span>
<span class="n">flavor</span> <span class="o">=</span> <span class="n">caching</span>
</pre></div>
</div>
</div>
<div class="section" id="enabling-the-image-cache-management-middleware">
<h3>Enabling the Image Cache Management Middleware<a class="headerlink" href="#enabling-the-image-cache-management-middleware" title="Permalink to this headline"></a></h3>
<p>There is an optional <tt class="docutils literal"><span class="pre">cachemanage</span></tt> middleware that allows you to
directly interact with cache images. Use this flavor in place of the
<tt class="docutils literal"><span class="pre">cache</span></tt> flavor in your api config file.</p>
<blockquote>
<div>[paste_deploy]
flavor = cachemanage</div></blockquote>
</div>
<div class="section" id="configuration-options-affecting-the-image-cache">
<h3>Configuration Options Affecting the Image Cache<a class="headerlink" href="#configuration-options-affecting-the-image-cache" title="Permalink to this headline"></a></h3>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">These configuration options must be set in both the glance-cache
and glance-api configuration files.</p>
</div>
<p>One main configuration file option affects the image cache.</p>
<blockquote>
<div><ul class="simple">
<li><tt class="docutils literal"><span class="pre">image_cache_dir=PATH</span></tt></li>
</ul>
</div></blockquote>
<p>Required when image cache middleware is enabled.</p>
<p>Default: <tt class="docutils literal"><span class="pre">/var/lib/glance/image-cache</span></tt></p>
<p>This is the base directory the image cache can write files to.
Make sure the directory is writeable by the user running the
<tt class="docutils literal"><span class="pre">glance-api</span></tt> server</p>
<blockquote>
<div><ul class="simple">
<li><tt class="docutils literal"><span class="pre">image_cache_driver=DRIVER</span></tt></li>
</ul>
</div></blockquote>
<p>Optional. Choice of <tt class="docutils literal"><span class="pre">sqlite</span></tt> or <tt class="docutils literal"><span class="pre">xattr</span></tt></p>
<p>Default: <tt class="docutils literal"><span class="pre">sqlite</span></tt></p>
<p>The default <tt class="docutils literal"><span class="pre">sqlite</span></tt> cache driver has no special dependencies, other
than the <tt class="docutils literal"><span class="pre">python-sqlite3</span></tt> library, which is installed on virtually
all operating systems with modern versions of Python. It stores
information about the cached files in a SQLite database.</p>
<p>The <tt class="docutils literal"><span class="pre">xattr</span></tt> cache driver required the <tt class="docutils literal"><span class="pre">python-xattr&gt;=0.6.0</span></tt> library
and requires that the filesystem containing <tt class="docutils literal"><span class="pre">image_cache_dir</span></tt> have
access times tracked for all files (in other words, the noatime option
CANNOT be set for that filesystem). In addition, <tt class="docutils literal"><span class="pre">user_xattr</span></tt> must be
set on the filesystem&#8217;s description line in fstab. Because of these
requirements, the <tt class="docutils literal"><span class="pre">xattr</span></tt> cache driver is not available on Windows.</p>
<blockquote>
<div><ul class="simple">
<li><tt class="docutils literal"><span class="pre">image_cache_sqlite_db=DB_FILE</span></tt></li>
</ul>
</div></blockquote>
<p>Optional.</p>
<p>Default: <tt class="docutils literal"><span class="pre">cache.db</span></tt></p>
<p>When using the <tt class="docutils literal"><span class="pre">sqlite</span></tt> cache driver, you can set the name of the database
that will be used to store the cached images information. The database
is always contained in the <tt class="docutils literal"><span class="pre">image_cache_dir</span></tt>.</p>
<blockquote>
<div><ul class="simple">
<li><tt class="docutils literal"><span class="pre">image_cache_max_size=SIZE</span></tt></li>
</ul>
</div></blockquote>
<p>Optional.</p>
<p>Default: <tt class="docutils literal"><span class="pre">10737418240</span></tt> (10 GB)</p>
<p>Size, in bytes, that the image cache should be constrained to. Images files
are cached automatically in the local image cache, even if the writing of that
image file would put the total cache size over this size. The
<tt class="docutils literal"><span class="pre">glance-cache-pruner</span></tt> executable is what prunes the image cache to be equal
to or less than this value. The <tt class="docutils literal"><span class="pre">glance-cache-pruner</span></tt> executable is designed
to be run via cron on a regular basis. See more about this executable in
<a class="reference internal" href="cache.html"><em>Controlling the Growth of the Image Cache</em></a></p>
</div>
</div>
<div class="section" id="configuring-the-glance-registry">
<h2>Configuring the Glance Registry<a class="headerlink" href="#configuring-the-glance-registry" title="Permalink to this headline"></a></h2>
<p>There are a number of configuration options in Glance that control how
this registry server operates. These configuration options are specified in the
<tt class="docutils literal"><span class="pre">glance-registry.conf</span></tt> config file in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>.</p>
<p><strong>IMPORTANT NOTE</strong>: The glance-registry service is only used in conjunction
with the glance-api service when clients are using the v1 REST API. See
<a class="reference internal" href="#configuring-glance-apis">Configuring Glance APIs</a> for more info.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">sql_connection=CONNECTION_STRING</span></tt> (<tt class="docutils literal"><span class="pre">--sql-connection</span></tt> when specified
on command line)</li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">None</span></tt></p>
<p>Can be specified in configuration files. Can also be specified on the
command-line for the <tt class="docutils literal"><span class="pre">glance-manage</span></tt> program.</p>
<p>Sets the SQLAlchemy connection string to use when connecting to the registry
database. Please see the documentation for
<a class="reference external" href="http://www.sqlalchemy.org/docs/05/reference/sqlalchemy/connections.html">SQLAlchemy connection strings</a>
online. You must urlencode any special characters in CONNECTION_STRING.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">sql_timeout=SECONDS</span></tt>
on command line)</li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">3600</span></tt></p>
<p>Can only be specified in configuration files.</p>
<p>Sets the number of seconds after which SQLAlchemy should reconnect to the
datastore if no activity has been made on the connection.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">enable_v1_registry=&lt;True|False&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">True</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">enable_v2_registry=&lt;True|False&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">True</span></tt></p>
<p>Defines which version(s) of the Registry API will be enabled.
If the Glance API server parameter <tt class="docutils literal"><span class="pre">enable_v1_api</span></tt> has been set to <tt class="docutils literal"><span class="pre">True</span></tt> the
<tt class="docutils literal"><span class="pre">enable_v1_registry</span></tt> has to be <tt class="docutils literal"><span class="pre">True</span></tt> as well.
If the Glance API server parameter <tt class="docutils literal"><span class="pre">enable_v2_api</span></tt> has been set to <tt class="docutils literal"><span class="pre">True</span></tt> and
the parameter <tt class="docutils literal"><span class="pre">data_api</span></tt> has been set to <tt class="docutils literal"><span class="pre">glance.db.registry.api</span></tt> the
<tt class="docutils literal"><span class="pre">enable_v2_registry</span></tt> has to be set to <tt class="docutils literal"><span class="pre">True</span></tt></p>
</div>
<div class="section" id="configuring-notifications">
<h2>Configuring Notifications<a class="headerlink" href="#configuring-notifications" title="Permalink to this headline"></a></h2>
<p>Glance can optionally generate notifications to be logged or sent to
a RabbitMQ queue. The configuration options are specified in the
<tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> config file in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">notifier_strategy</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">noop</span></tt></p>
<p>Sets the strategy used for notifications. Options are <tt class="docutils literal"><span class="pre">logging</span></tt>,
<tt class="docutils literal"><span class="pre">rabbit</span></tt>, <tt class="docutils literal"><span class="pre">qpid</span></tt> and <tt class="docutils literal"><span class="pre">noop</span></tt>.
For more information <a class="reference internal" href="notifications.html"><em>Glance notifications</em></a></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_host</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">localhost</span></tt></p>
<p>Host to connect to when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_port</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">5672</span></tt></p>
<p>Port to connect to when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_use_ssl</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">false</span></tt></p>
<p>Boolean to use SSL for connecting when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_userid</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">guest</span></tt></p>
<p>Userid to use for connection when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_password</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">guest</span></tt></p>
<p>Password to use for connection when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_virtual_host</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">/</span></tt></p>
<p>Virtual host to use for connection when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_notification_exchange</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">glance</span></tt></p>
<p>Exchange name to use for connection when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_notification_topic</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">notifications</span></tt></p>
<p>Topic to use for connection when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_max_retries</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">0</span></tt></p>
<p>Number of retries on communication failures when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.
A value of 0 means to retry forever.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_retry_backoff</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">2</span></tt></p>
<p>Number of seconds to wait before reconnecting on failures when using
<tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_retry_max_backoff</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">30</span></tt></p>
<p>Maximum seconds to wait before reconnecting on failures when using
<tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">rabbit_durable_queues</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">False</span></tt></p>
<p>Controls durability of exchange and queue when using <tt class="docutils literal"><span class="pre">rabbit</span></tt> strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_notification_exchange</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">glance</span></tt></p>
<p>Message exchange to use when using the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_notification_topic</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">glanice_notifications</span></tt></p>
<p>This is the topic prefix for notifications when using the <tt class="docutils literal"><span class="pre">qpid</span></tt>
notification strategy. When a notification is sent at the <tt class="docutils literal"><span class="pre">info</span></tt> priority,
the topic will be <tt class="docutils literal"><span class="pre">notifications.info</span></tt>. The same idea applies for
the <tt class="docutils literal"><span class="pre">error</span></tt> and <tt class="docutils literal"><span class="pre">warn</span></tt> notification priorities. To receive all
notifications, you would set up a receiver with a topic of
<tt class="docutils literal"><span class="pre">notifications.*</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_hostname</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">localhost</span></tt></p>
<p>This is the hostname or IP address of the Qpid broker that will be used
when Glance has been configured to use the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_port</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">5672</span></tt></p>
<p>This is the port number to connect to on the Qpid broker, <tt class="docutils literal"><span class="pre">qpid_hostname</span></tt>,
when using the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_username</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This is the username that Glance will use to authenticate with the Qpid
broker if using the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_password</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This is the username that Glance will use to authenticate with the Qpid
broker if using the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_sasl_mechanisms</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This is a space separated list of SASL mechanisms to use for authentication
with the Qpid broker if using the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_reconnect_timeout</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This option specifies a timeout in seconds for automatic reconnect attempts
to the Qpid broker if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is used.  In general,
it is safe to leave all of the reconnect timing options not set. In that case,
the Qpid client&#8217;s default behavior will be used, which is to attempt to
reconnect to the broker at exponential back-off intervals (in 1 second, then 2
seconds, then 4, 8, 16, etc).</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_reconnect_limit</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This option specifies a maximum number of reconnect attempts to the Qpid
broker if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is being used.  Normally the
Qpid client will continue attempting to reconnect until successful.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_reconnect_interval_min</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This option specifies the minimum number of seconds between reconnection
attempts if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is being used.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_reconnect_interval_max</span></tt></li>
</ul>
<p>Optional. Default: None</p>
<p>This option specifies the maximum number of seconds between reconnection
attempts if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is being used.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_reconnect_interval</span></tt></li>
</ul>
<p>This option specifies the exact number of seconds between reconnection
attempts if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is being used. Setting
this option is equivalent to setting <tt class="docutils literal"><span class="pre">qpid_reconnect_interval_max</span></tt> and
<tt class="docutils literal"><span class="pre">qpid_reconnect_interval_min</span></tt> to the same value.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_heartbeat</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">5</span></tt></p>
<p>This option is used to specify the number of seconds between heartbeat messages
exchanged between the Qpid client and Qpid broker if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification
strategy is being used.  Heartbeats are used to more quickly detect that a
connection has been lost.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_protocol</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">tcp</span></tt></p>
<p>This option is used to specify the transport protocol to use if using the
<tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy. To enable SSL, set this option to <tt class="docutils literal"><span class="pre">ssl</span></tt>.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">qpid_tcp_nodelay</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">True</span></tt></p>
<p>This option can be used to disable the TCP NODELAY option. It effectively
disables the Nagle algorithm for the connection to the Qpid broker. This
option only applies if the <tt class="docutils literal"><span class="pre">qpid</span></tt> notification strategy is used.</p>
</div>
<div class="section" id="configuring-access-policies">
<h2>Configuring Access Policies<a class="headerlink" href="#configuring-access-policies" title="Permalink to this headline"></a></h2>
<p>Access rules may be configured using a
<a class="reference internal" href="policies.html"><em>Policy Configuration file</em></a>. Two configuration options tell
the Glance API server about the policies to use.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">policy_file=PATH</span></tt></li>
</ul>
<p>Optional. Default: Looks for a file called <tt class="docutils literal"><span class="pre">policy.json</span></tt> or
<tt class="docutils literal"><span class="pre">glance.policy.json</span></tt> in standard configuration directories.</p>
<p>Policy file to load when starting the API server</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">policy_default_rule=RULE</span></tt></li>
</ul>
<p>Optional. Default: &#8220;default&#8221;</p>
<p>Name of the rule in the policy configuration file to use as the default rule</p>
</div>
<div class="section" id="configuring-glance-property-protections">
<h2>Configuring Glance Property Protections<a class="headerlink" href="#configuring-glance-property-protections" title="Permalink to this headline"></a></h2>
<p>Access to image meta properties may be configured using a
<a class="reference internal" href="property-protections.html"><em>Property Protections Configuration file</em></a>.  The
location for this file can be specified in the <tt class="docutils literal"><span class="pre">glance-api.conf</span></tt> config file
in the section <tt class="docutils literal"><span class="pre">[DEFAULT]</span></tt>. <strong>If an incorrect value is specified, glance api
service will not start.</strong></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">property_protection_file=PATH</span></tt></li>
</ul>
<p>Optional. Default: not enabled.</p>
<p>If property_protection_file is set, the file may use either roles or policies
to specify property protections.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">property_protection_rule_format=&lt;roles|policies&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">roles</span></tt>.</p>
</div>
<div class="section" id="configuring-glance-apis">
<h2>Configuring Glance APIs<a class="headerlink" href="#configuring-glance-apis" title="Permalink to this headline"></a></h2>
<p>The glance-api service implents versions 1 and 2 of the OpenStack
Images API. Disable either version of the Images API using the
following options:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">enable_v1_api=&lt;True|False&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">True</span></tt></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">enable_v2_api=&lt;True|False&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">True</span></tt></p>
<p><strong>IMPORTANT NOTE</strong>: The v1 API is implemented on top of the
glance-registry service while the v2 API is not. This means that
in order to use the v2 API, you must copy the necessary sql
configuration from your glance-registry service to your
glance-api configuration file.</p>
</div>
<div class="section" id="configuring-glance-tasks">
<h2>Configuring Glance Tasks<a class="headerlink" href="#configuring-glance-tasks" title="Permalink to this headline"></a></h2>
<p>Glance Tasks are implemented only for version 2 of the OpenStack Images API.</p>
<p><tt class="docutils literal"><span class="pre">Please</span> <span class="pre">be</span> <span class="pre">aware</span> <span class="pre">that</span> <span class="pre">Glance</span> <span class="pre">tasks</span> <span class="pre">are</span> <span class="pre">currently</span> <span class="pre">a</span> <span class="pre">work</span> <span class="pre">in</span> <span class="pre">progress</span>
<span class="pre">feature.</span></tt> Although, the API is available, the execution part of it
is being worked on.</p>
<p>The config value <tt class="docutils literal"><span class="pre">task_time_to_live</span></tt> is used to determine how long a task
would be visible to the user after transitioning to either the <tt class="docutils literal"><span class="pre">success</span></tt> or
the <tt class="docutils literal"><span class="pre">failure</span></tt> state.</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">task_time_to_live=&lt;Time_in_hours&gt;</span></tt></li>
</ul>
<p>Optional. Default: <tt class="docutils literal"><span class="pre">48</span></tt></p>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
            <h3><a href="index.html">Table Of Contents</a></h3>
            <ul>
<li><a class="reference internal" href="#">Basic Configuration</a><ul>
<li><a class="reference internal" href="#common-configuration-options-in-glance">Common Configuration Options in Glance</a></li>
<li><a class="reference internal" href="#configuring-server-startup-options">Configuring Server Startup Options</a><ul>
<li><a class="reference internal" href="#configuring-ssl-support">Configuring SSL Support</a></li>
<li><a class="reference internal" href="#configuring-registry-access">Configuring Registry Access</a></li>
</ul>
</li>
<li><a class="reference internal" href="#configuring-logging-in-glance">Configuring Logging in Glance</a><ul>
<li><a class="reference internal" href="#logging-options-available-only-in-configuration-files">Logging Options Available Only in Configuration Files</a></li>
</ul>
</li>
<li><a class="reference internal" href="#configuring-glance-storage-backends">Configuring Glance Storage Backends</a></li>
<li><a class="reference internal" href="#configuring-glance-image-size-limit">Configuring Glance Image Size Limit</a></li>
<li><a class="reference internal" href="#configuring-glance-user-storage-quota">Configuring Glance User Storage Quota</a><ul>
<li><a class="reference internal" href="#configuring-the-filesystem-storage-backend">Configuring the Filesystem Storage Backend</a></li>
<li><a class="reference internal" href="#configuring-the-filesystem-storage-backend-with-multiple-stores">Configuring the Filesystem Storage Backend with multiple stores</a></li>
<li><a class="reference internal" href="#configuring-the-swift-storage-backend">Configuring the Swift Storage Backend</a></li>
<li><a class="reference internal" href="#configuring-the-s3-storage-backend">Configuring the S3 Storage Backend</a></li>
<li><a class="reference internal" href="#configuring-the-rbd-storage-backend">Configuring the RBD Storage Backend</a></li>
<li><a class="reference internal" href="#configuring-the-sheepdog-storage-backend">Configuring the Sheepdog Storage Backend</a></li>
<li><a class="reference internal" href="#configuring-the-cinder-storage-backend">Configuring the Cinder Storage Backend</a></li>
</ul>
</li>
<li><a class="reference internal" href="#configuring-the-image-cache">Configuring the Image Cache</a><ul>
<li><a class="reference internal" href="#enabling-the-image-cache-middleware">Enabling the Image Cache Middleware</a></li>
<li><a class="reference internal" href="#enabling-the-image-cache-management-middleware">Enabling the Image Cache Management Middleware</a></li>
<li><a class="reference internal" href="#configuration-options-affecting-the-image-cache">Configuration Options Affecting the Image Cache</a></li>
</ul>
</li>
<li><a class="reference internal" href="#configuring-the-glance-registry">Configuring the Glance Registry</a></li>
<li><a class="reference internal" href="#configuring-notifications">Configuring Notifications</a></li>
<li><a class="reference internal" href="#configuring-access-policies">Configuring Access Policies</a></li>
<li><a class="reference internal" href="#configuring-glance-property-protections">Configuring Glance Property Protections</a></li>
<li><a class="reference internal" href="#configuring-glance-apis">Configuring Glance APIs</a></li>
<li><a class="reference internal" href="#configuring-glance-tasks">Configuring Glance Tasks</a></li>
</ul>
</li>
</ul>

            <h4>Previous topic</h4>
            <p class="topless"><a href="installing.html"
                                  title="previous chapter">Installation</a></p>
            <h4>Next topic</h4>
            <p class="topless"><a href="authentication.html"
                                  title="next chapter">Authentication With Keystone</a></p>
            <h3>This Page</h3>
            <ul class="this-page-menu">
              <li><a href="_sources/configuring.txt"
                     rel="nofollow">Show Source</a></li>
            </ul>
          <div id="searchbox" style="display: none">
            <h3>Quick search</h3>
              <form class="search" action="search.html" method="get">
                <input type="text" name="q" size="18" />
                <input type="submit" value="Go" />
                <input type="hidden" name="check_keywords" value="yes" />
                <input type="hidden" name="area" value="default" />
              </form>
              <p class="searchtip" style="font-size: 90%">
              Enter search terms or a module, class or function name.
              </p>
          </div>
          <script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="authentication.html" title="Authentication With Keystone"
             accesskey="N">next</a></li>
        <li class="right" >
          <a href="installing.html" title="Installation"
             accesskey="P">previous</a> |</li>
        <li><a href="index.html">Glance 2014.1.5 documentation</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
        &copy; Copyright 2010-2014, OpenStack Foundation..
      Last updated on Aug 25, 2017.
      Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.2.2.
    </div>
  </body>
</html>