Swift All-In-One安裝指南
SwiftAll-In-One 安裝指南
author:錢立寬
email:[email protected]
date:2018-3-20
Swift All-In-One(SAIO)單機部署機器配置:
戴爾PowerEdge-T110-II伺服器一臺;
Intel Xeon四核處理器3.1G Hz 一個
網絡卡 一塊
記憶體 500G
作業系統:Ubuntu 14.04 LTS desktop
本機IP地址:10.200.25.223(固定IP)
PLEASE Keep These Cautions InMind :
一定要仔細閱讀每一個在接下來會出現的配置檔案,一定要注意IP地址和埠號配置的對不對
安裝測試成功。
1) 安裝依賴
1. sudoapt-get update
2. sudoapt-get install curl gcc memcached rsync sqlite3 xfsprogs \
git-core libffi-devpython-setuptools \
liberasurecode-devlibssl-dev
3. sudoapt-get install python-coverage python-dev python-nose \
python-xattr python-eventlet \
python-greenletpython-pastedeploy \
python-netifaces python-pip python-dnspython\ python-mock
2) 使用迴環裝置儲存
1》 使用迴環裝置作為儲存
1. sudomkdir /srv
2. sudotruncate -s 1GB /srv/swift-disk
3. sudomkfs.xfs /srv/swift-disk
修改truncate命令中指定的大小以根據需要建立更大或更小的分割槽
2》 編輯修改分割槽表/etc/fstab並新增(sudo gedit /etc/fstab):
/srv/swift-disk /mnt/sda1 xfs loop,noatime,nodiratime,nobarrier,logbufs=80 0
3》 建立掛載點和連結
1. sudomkdir /mnt/sda1
2. sudomount /mnt/sda1
3. sudomkdir /mnt/sda1/1 /mnt/sda1/2 /mnt/sda1/3 /mnt/sda1/4
4. sudochown ${USER}:${USER} /mnt/sda1/*
5. forx in {1..4}; do sudo ln -s /mnt/sda1/$x /srv/$x; done
6. sudomkdir -p /srv/1/node/sda1 /srv/1/node/sda5 \
/srv/2/node/sda2 /srv/2/node/sda6\
/srv/3/node/sda3 /srv/3/node/sda7 \
/srv/4/node/sda4 /srv/4/node/sda8 \
/var/run/swift
7. sudochown -R ${USER}:${USER} /var/run/swift
8. forx in {1..4}; do sudo chown -R ${USER}:${USER} /srv/$x/; done
4》 CommonPost-Device Setup
新增下面幾行到/etc/rc.local中(在exit 0 之前):
1. mkdir-p /var/cache/swift /var/cache/swift2 /var/cache/swift3 /var/cache/swift4
2. chown<your-user-name>:<your-group-name> /var/cache/swift*
3. mkdir-p /var/run/swift
4. chown<your-user-name>:<your-group-name> /var/run/swift
3) 獲取程式碼
1》下載python-swiftclient程式碼
2》編譯並安裝python-swiftclient
1. cd$HOME/python-swiftclient; sudo python setup.py develop; cd –
3》下載swift的程式碼
4》編譯並安裝swift
注意:在Ubuntu14.04中按照官方文件的安裝方式有些包是安裝不上的,因為包之間的版本衝突
1. cd $Home/swift
2. sudo apt-get purgepython-setuptools
3. sudo apt-get install python-pbr
4. sudo pip install -rrequirements.txt
5. sudo pip install -rtest-requirements.txt
6. sudo python setup.py develop;cd –
4) 安裝rsync
1》 建立/etc/rsyncd.conf:
1. sudocp $HOME/swift/doc/saio/rsyncd.conf /etc/
2. sudosed -i "s/<your-user-name>/${USER}/" /etc/rsyncd.conf
預設rsyncd.conf檔案內容如下,用來修復上面的修改
uid = <your-user-name>
gid = <your-user-name>
log file = /var/log/rsyncd.log
pid file = /var/run/rsyncd.pid
address = 127.0.0.1
[account6012]
max connections = 25
path = /srv/1/node/
read only = false
lock file = /var/lock/account6012.lock
[account6022]
max connections = 25
path = /srv/2/node/
read only = false
lock file = /var/lock/account6022.lock
[account6032]
max connections = 25
path = /srv/3/node/
read only = false
lock file = /var/lock/account6032.lock
[account6042]
max connections = 25
path = /srv/4/node/
read only = false
lock file = /var/lock/account6042.lock
[container6011]
max connections = 25
path = /srv/1/node/
read only = false
lock file = /var/lock/container6011.lock
[container6021]
max connections = 25
path = /srv/2/node/
read only = false
lock file = /var/lock/container6021.lock
[container6031]
max connections = 25
path = /srv/3/node/
read only = false
lock file = /var/lock/container6031.lock
[container6041]
max connections = 25
path = /srv/4/node/
read only = false
lock file = /var/lock/container6041.lock
[object6010]
max connections = 25
path = /srv/1/node/
read only = false
lock file = /var/lock/object6010.lock
[object6020]
max connections = 25
path = /srv/2/node/
read only = false
lock file = /var/lock/object6020.lock
[object6030]
max connections = 25
path = /srv/3/node/
read only = false
lock file = /var/lock/object6030.lock
[object6040]
max connections = 25
path = /srv/4/node/
read only = false
lock file = /var/lock/object6040.lock
再次提醒讀者注意這裡和接下來所出現的所有IP地址
2》 在Ubuntu,修改/etc/default/rsync中的下面一行
1. RSYNC_ENABLE=true
3》 啟動rsync
1. sudoservice rsync restart
4》 驗證rsync是不是接受了所有的連線
1. rsyncrsync://[email protected]/
執行上述命令,應該會看到
account6012
account6022
account6032
account6042
container6011
container6021
container6031
container6041
object6010
object6020
object6030
object6040
5) 啟動memcached
sudo serviceMemcached start
tempauth中介軟體在memcached中儲存令牌。如果memcached是沒有執行,令牌不能被驗證,就無法使用swift
(可選) 啟動rsyslog,為swift建立獨立的日誌
1》 安裝swift rsyslog的配置
1. sudo cp$HOME/swift/doc/saio/rsyslog.d/10-swift.conf /etc/rsyslog.d/
檢視該conf檔案以確定是否要將日誌獨立出來,以及是否需要每小時處理統計資訊的日誌。為方便起見,我們提供以下預設內容:
# Uncomment thefollowing to have a log containing all logs together
#local1,local2,local3,local4,local5.* /var/log/swift/all.log
# Uncomment thefollowing to have hourly proxy logs for stats processing
#$templateHourlyProxyLog,"/var/log/swift/hourly/%$YEAR%%$MONTH%%$DAY%%$HOUR%"
#local1.*;local1.!notice?HourlyProxyLog
local1.*;local1.!notice /var/log/swift/proxy.log
local1.notice /var/log/swift/proxy.error
local1.* ~
local2.*;local2.!notice /var/log/swift/storage1.log
local2.notice /var/log/swift/storage1.error
local2.* ~
local3.*;local3.!notice /var/log/swift/storage2.log
local3.notice /var/log/swift/storage2.error
local3.* ~
local4.*;local4.!notice /var/log/swift/storage3.log
local4.notice /var/log/swift/storage3.error
local4.* ~
local5.*;local5.!notice /var/log/swift/storage4.log
local5.notice /var/log/swift/storage4.error
local5.* ~
local6.*;local6.!notice /var/log/swift/expirer.log
local6.notice /var/log/swift/expirer.error
local6.* ~
2》 編輯/etc/rsyslog.conf 並進行以下修改(在“GLOBAL DIRECTIVES”中)
$PrivDropToGroup adm
3》 如果使用的是hourly logs則執行下面的
sudo mkdir -p /var/log/swift/hourly
否則執行
sudomkdir -p /var/log/swift
4》 建立日誌目錄,啟動syslog
1. sudo chown -Rsyslog.adm /var/log/swift
2. sudo chmod -R g+w /var/log/swift
3. sudo service rsyslog restart
6) 配置每一個節點
執行以下步驟時,請務必檢視配置檔案是否與示例一致,注意ip和埠號
1》(可選)刪除已經存在的swift目錄
1. sudo rm -rf/etc/swift
2》往/etc/swift中新增配置檔案
1. cd$HOME/swift/doc; sudo cp -r saio/swift /etc/swift; cd –
2. sudo chown -R${USER}:${USER} /etc/swift
3》在swift配置檔案中更新<your-user-name>引用
1. find /etc/swift/-name \*.conf | xargs sudo sed -i "s/<your-user-name>/${USER}/"
通過執行上述命令提供的配置檔案的內容如下:
1./etc/swift/swift.conf
[swift-hash]
# random uniquestrings that can never change (DO NOT LOSE)
# Use only printablechars (python -c "import string; print(string.printable)")
swift_hash_path_prefix = changeme
swift_hash_path_suffix = changeme
[storage-policy:0]
name = gold
policy_type = replication
default = yes
[storage-policy:1]
name = silver
policy_type = replication
[storage-policy:2]
name = ec42
policy_type = erasure_coding
ec_type = liberasurecode_rs_vand
ec_num_data_fragments =4
ec_num_parity_fragments= 2
2./etc/swift/proxy-server.conf
[DEFAULT]
bind_ip = 127.0.0.1
bind_port = 8080
workers = 1
user =<your-user-name>
log_facility =LOG_LOCAL1
eventlet_debug = true
[pipeline:main]
# Yes, proxy-loggingappears twice. This is so that
#middleware-originated requests get logged too.
pipeline = catch_errorsgatekeeper healthcheck proxy-logging cache bulk tempurl ratelimit crossdomaincontainer_sync tempauth staticweb copy container-quotas account-quotas slo dloversioned_writes proxy-logging proxy-server
[filter:catch_errors]
use = egg:swift#catch_errors
[filter:healthcheck]
use = egg:swift#healthcheck
[filter:proxy-logging]
use = egg:swift#proxy_logging
[filter:bulk]
use = egg:swift#bulk
[filter:ratelimit]
use = egg:swift#ratelimit
[filter:crossdomain]
use = egg:swift#crossdomain
[filter:dlo]
use = egg:swift#dlo
[filter:slo]
use = egg:swift#slo
[filter:container_sync]
use = egg:swift#container_sync
current =//saio/saio_endpoint
[filter:tempurl]
use = egg:swift#tempurl
[filter:tempauth]
use = egg:swift#tempauth
user_admin_admin =admin .admin .reseller_admin
user_test_tester =testing .admin
user_test2_tester2 =testing2 .admin
user_test_tester3 =testing3
[filter:staticweb]
use = egg:swift#staticweb
[filter:account-quotas]
use = egg:swift#account_quotas
[filter:container-quotas]
use = egg:swift#container_quotas
[filter:cache]
use = egg:swift#memcache
[filter:gatekeeper]
use = egg:swift#gatekeeper
[filter:versioned_writes]
use = egg:swift#versioned_writes
allow_versioned_writes= true
[filter:copy]
use = egg:swift#copy
[app:proxy-server]
use = egg:swift#proxy
allow_account_management= true
account_autocreate = true
3./etc/swift/object-expirer.conf
[DEFAULT]
# swift_dir =/etc/swift
user =<your-user-name>
# You can specifydefault log routing here if you want:
log_name =object-expirer
log_facility =LOG_LOCAL6
log_level = INFO
#log_address =/dev/log
#
# comma separatedlist of functions to call to setup custom log handlers.
# functions getpassed: conf, name, log_to_console, log_route, fmt, logger,
# adapted_logger
# log_custom_handlers=
#
# If set,log_udp_host will override log_address
# log_udp_host =
# log_udp_port = 514
#
# You can enableStatsD logging here:
# log_statsd_host =
# log_statsd_port =8125
#log_statsd_default_sample_rate = 1.0
#log_statsd_sample_rate_factor = 1.0
#log_statsd_metric_prefix =
[object-expirer]
interval = 300
# auto_create_account_prefix= .
# report_interval =300
# concurrency is thelevel of concurrency o use to do the work, this value
# must be set to atleast 1
# concurrency = 1
# processes is howmany parts to divide the work into, one part per process
# that will be doing the work
# processes set 0means that a single process will be doing all the work
# processes can alsobe specified on the command line and will override the
# config value
# processes = 0
# process is which ofthe parts a particular process will work on
# process can also bespecified on the command line and will override the config
# value
# process is"zero based", if you want to use 3 processes, you should run
# processes with process set to 0, 1, and 2
# process = 0
[pipeline:main]
pipeline = catch_errorscache proxy-server
[app:proxy-server]
use = egg:swift#proxy
# Seeproxy-server.conf-sample for options
[filter:cache]
use = egg:swift#memcache
# Seeproxy-server.conf-sample for options
[filter:catch_errors]
use = egg:swift#catch_errors
# Seeproxy-server.conf-sample for options
4./etc/swift/container-reconciler.conf
[DEFAULT]
# swift_dir =/etc/swift
user =<your-user-name>
# You can specifydefault log routing here if you want:
# log_name = swift
# log_facility =LOG_LOCAL0
# log_level = INFO
# log_address =/dev/log
#
# comma separatedlist of functions to call to setup custom log handlers.
# functions getpassed: conf, name, log_to_console, log_route, fmt, logger,
# adapted_logger
# log_custom_handlers=
#
# If set,log_udp_host will override log_address
# log_udp_host =
# log_udp_port = 514
#
# You can enableStatsD logging here:
# log_statsd_host =
# log_statsd_port =8125
#log_statsd_default_sample_rate = 1.0
#log_statsd_sample_rate_factor = 1.0
#log_statsd_metric_prefix =
[container-reconciler]
# reclaim_age =604800
# interval = 300
# request_tries = 3
[pipeline:main]
pipeline = catch_errorsproxy-logging cache proxy-server
[app:proxy-server]
use = egg:swift#proxy
# Seeproxy-server.conf-sample for options
[filter:cache]
use = egg:swift#memcache
# Seeproxy-server.conf-sample for options
[filter:proxy-logging]
use = egg:swift#proxy_logging
[filter:catch_errors]
use = egg:swift#catch_errors
# Seeproxy-server.conf-sample for options
5./etc/swift/container-sync-realms.conf
[saio]
key = changeme
key2 = changeme
cluster_saio_endpoint =http://127.0.0.1:8080/v1/
6./etc/swift/account-server/1.conf
[DEFAULT]
devices = /srv/1/node
mount_check = false
disable_fallocate = true
bind_ip = 127.0.0.1
bind_port = 6012
workers = 1
user =<your-user-name>
log_facility =LOG_LOCAL2
recon_cache_path =/var/cache/swift
eventlet_debug = true
[pipeline:main]
pipeline = reconaccount-server
[app:account-server]
use = egg:swift#account
[filter:recon]
use = egg:swift#recon
[account-replicator]
rsync_module ={replication_ip}::account{replication_port}
[account-auditor]
[account-reaper]
7./etc/swift/container-server/1.conf
[DEFAULT]
devices = /srv/1/node
mount_check = false
disable_fallocate = true
bind_ip = 127.0.0.1
bind_port = 6011
workers = 1
user =<your-user-name>
log_facility =LOG_LOCAL2
recon_cache_path =/var/cache/swift
eventlet_debug = true
[pipeline:main]
pipeline = reconcontainer-server
[app:container-server]
use = egg:swift#container
[filter:recon]
use = egg:swift#recon
[container-replicator]
rsync_module ={replication_ip}::container{replication_port}
[container-updater]
[container-auditor]
[container-sync]
8./etc/swift/object-server/1.conf
[DEFAULT]
devices = /srv/1/node
mount_check = false
disable_fallocate = true
bind_ip = 127.0.0.1
bind_port = 6010
workers = 1
user =<your-user-name>
log_facility =LOG_LOCAL2
recon_cache_path =/var/cache/swift
eventlet_debug = true
[pipeline:main]
pipeline = reconobject-server
[app:object-server]
use = egg:swift#object
[filter:recon]
use = egg:swift#recon
[object-replicator]
rsync_module ={replication_ip}::object{replication_port}
[object-reconstructor]
[object-updater]
[object-auditor]
9./etc/swift/account-server/2.conf
[DEFAULT]
devices = /srv/2/node
mount_check = false
disable_fallocate = true
bind_ip = 127.0.0.1
bind_port = 6022
workers = 1
user =<your-user-name>
log_facility =LOG_LOCAL3
recon_cache_path =/var/cache/swift2
eventlet_debug = true
[pipeline:main]
pipeline = reconaccount-server
[app:account-server]
use = egg:swift#account
[filter:recon]
use = egg:swift#recon
[account-replicator]
rsync_module ={replication_ip}::account{replication_port}
[account-auditor]
[account-reaper]
10./etc/swift/container-server/2.conf
[DEFAULT]
SwiftAll-In-One 安裝指南author:錢立寬email:[email protected]date:2018-3-20Swift All-In-One(SAIO)單機部署機器配置:戴爾PowerEdge-T110-II伺服器一臺;Intel Xeon
轉自http://blog.csdn.net/u014283958/
因為要做三維重建,所以想用三維點雲處理庫Point Cloud Library(PCL),找了幾篇博文按照要求裝了一下午的依賴庫,後來發現已經出了PCL 1.8.0的a ces gis secret try -o 安裝失敗 mount manage use
TASK [openshift_service_catalog : Verify that the catalog api server is running]
curl: (7) 版權宣告:本文為博主原創文章,未經博主允許不得轉載。 https://blog.csdn.net/qq_21816375/article/details/73656494本文采用all-in-one(一體化的)安裝OpenShift
記得安裝docker
yum install docker
安裝doc
OpenStack如火如荼,現在Liberty版本已經發布,下面本文將一步一步詳細介紹一下該版本的單機部署。當然如果有多個伺服器,也可以按照該教程進行分散式部署。本文假設讀者對OpenStack的架構和基本元件有基本的瞭解。首先介紹一下基礎環境的安裝。所謂基礎環境,是執行O
寫在前面:
All-In-One 一鍵安裝ISO的製作和釋出在團隊內部已是慣例,隨著Liberty版本的釋出,最新版的All-In-One ISO 製作自然也被提上了日程,此次我接過了接力棒,製作過程的總結由於時間問題,會在後續另起博文。
宣告:
本部落格歡迎轉發,但請保 api1.概述
1.1.用途及閱讀方法
上屏API是上屏系統的後臺接口,管理平臺界面實現需要遵循本接口規範。
1.2.通信協議
客戶端和服務器通過HTTP協議通信,客戶端使用HTTP GET方法或POST方法向服務器發送請求,服務器返回json格式的業務數據或操作結果給客戶端。盡管接口同時支持GET和POST
Serialization is the process of converting a data structure or object into a sequence of bits so that it can be stored in a file or memory b
Given a robot cleaner in a room modeled as a grid.
Each cell in the grid can be empty or blocked.
The robot cleaner with 4 given APIs can move fo
Design your implementation of the linked list. You can choose to use the singly linked list or the doubly linked list. A node in a singly 
All in One SEO是WordPress上一個十分流行的SEO外掛,它的使用非常便捷,能幫助我們設定每個頁面的關鍵詞和描述。雖然網上對這款外掛後很多詬病,但是這些缺點可以通過設定來避免。所以正對沒有開發能力的小夥伴來說,它是一個不二的選擇。
功能
All in On
本文基於istion 1.0.4版本,並且置tracing.enable=true的情況下部署istio環境。 然後去部署非all-in-one的jaeger,jaeger版本為1.7,使用elasticsearch作為儲存。
在istion中集成了all-in-one的jaeger(pod:i
終於將LeetCode的大部分題刷完了,真是漫長的第一遍啊,估計很多題都忘的差不多了,這次開個題目彙總貼,並附上每道題目的解題連線,方便之後查閱吧~
如果各位看官們,大神們發現了任何錯誤,或是程式碼無法通過OJ,或是有更好的解法,或是有任何疑問,意見和建議的話,請一定要在對應的帖子下面評論區留言告知博主 It's a fun site designed for robot enthusiasts of all ages and backgrounds. You should go check it out right now. Seriously, stop reading this and go to ro
作者: 負雪明燭 id: fuxuemingzhu 個人部落格: http://fuxuemingzhu.cn/
把自己刷過的所有題目做一個整理,並且用簡潔的語言概括了一下思路,彙總成了一個表格。
題目的排列順序是按照先Easy再Medium再Hard排列的,暫時還沒有把題
一、操作前需瞭解:
1. OpenStack提供IaaS(基礎設施即服務)服務,它是開源的雲端計算平臺。(個人理解:將多臺硬體裝置虛擬化成一個池,然後在池子裡放虛擬機器,放儲存(物件和塊)叢集,所有整合一起提供雲端計算基礎服務,會想到VMWARE的E
曾經架構在我以前看來,多麼高大上的詞啊,可望不可及;
在看了很久分散式的文章、書籍和架構後試著總結了一番;
此文的應用場景是超大使用者系統的發展程序;
下面大家就聽我娓娓道來吧~
最開始的應用是單一的應用,入下圖;
1、單一應用
在誕生之初始,應用與資料庫是部署在同一
kolla專案:All-In-One
部署環境:CentOS 7.2
物理機單網絡卡:搭建vlan解決或者別的方法(不然在啟動neutron網路的時候會斷網,雙網絡卡可以自己忽略這邊)
docker版本:1.12.1
1月16日,北京經歷了2010年第一場大雪和創50年的低溫記錄後,溫度似有回升的感覺。什剎海一座別緻建築二樓的"用友中小企業全面資訊化策略暨U8 All-in-One釋出會"現場洋溢著融融暖意。用友在這裡隆重發布了面向中小企業全面資訊化的解決方案--U8 All-i ![](https://img2020.cnblogs.com/blog/759200/202008/759200-20200823175554128-1033213.jpg)
作者:HelloGitHub-**小魚乾**
hacker 這個詞,大多數理解為黑客,而維基百科對其的定義為——黑客(Hacke 相關推薦
Swift All-In-One安裝指南
PCL-1.8.0 All In One安裝配置
OpenShift 3.11 all in one 安裝失敗
[轉]本文采用all-in-one(一體化的)安裝OpenShift
OpenStack L版安裝 All In One 之 基礎環境搭建
OpenStack Liberty 版本 All-In-One 一鍵安裝ISO 及安裝指導
上屏系統-接口規範-ALL In One
[LeetCode] Serialize and Deserialize N-ary Tree N叉搜尋樹的序列化和去序列化 LeetCode All in One 題目講解彙總(持續更新中...)
[LeetCode] Robot Room Cleaner 掃地機器人 LeetCode All in One 題目講解彙總(持續更新中...)
[LeetCode] Design Linked List 設計連結串列 LeetCode All in One 題目講解彙總(持續更新中...)
手保守教你使用All in one seo
在istio中部署非all-in-one的jaeger
LeetCode All in One 題目講解彙總(持續更新中...)
Explore the World's Coolest Robots, All in One Place
LeetCode解題報告彙總! All in One!
OpenStack 初探(一) -- All-In-One模式部署(初學OpenStack必備)
All-In-One到SOA的分散式架構演進
kolla專案:All-In-One --單網絡卡例項
用友釋出U8 All-in-One引爆中小企業全面資訊化
All in One 你想知道的 hacker 技術都在這裡