BIGDATA/ํ๋ก์์ฝ์์คํ
[์ค์น] apache ranger 2.1.0 / ์ํ์น ๋ ์ธ์ 2.1.0 ์ค์น
๐ฐํํ
2021. 7. 7. 15:51
๋ฐ์ํ
์ฌ์ ์์ ํ์
- root ๊ณ์ ์ JAVA_HOME ์ถ๊ฐ ํ์ํจ
- solr ์ค์น
- Maven 3.6.3 ์ค์น
- PostgreSQL ์ค์น ๋ฐ DB - ranger, User - rangeradmin(pw:rangeradmin) ์์ฑ
์์
๋ค ์คํํ ๋ root ๋๋ ๊ถํ ๊ฐ์ง ๊ณ์ ์ผ๋ก ํด์ผํจ
solr ์ค์นํ์!
https://n-a-y-a.tistory.com/m/68
ํ์ํ ํจํค์ง๋ค
1
2
3
4
|
$ sudo yum install git gcc python3 python3-devel
$ sudo yum install -y npm nodejs
$ npm install node-ranger
$ pip3 install requests
|
cs |
Ranger ์ค์น ๋ฐ MVN ๋น๋
1
2
3
4
|
$ sudo wget https://downloads.apache.org/ranger/2.1.0/apache-ranger-2.1.0.tar.gz
$ sudo tar xvzf apache-ranger-2.1.0.tar.gz
$ cd apache-ranger-2.1.0/
$ mvn -Pall -DskipTests=true clean compile package install
|
cs |
mvn ๋น๋๋ ํ์๊ฐ ๋ฐ์ ๋ ๊ฑธ๋ฆฌ๊ณ , mvn์์ ๋น๋ ์๋ฌ๋ ๋์ง์์์.
์๋ฌ ๋ ๊ฒฝ์ฐ, mvn ์ค์ ๊ฐ ํ์ธ ํ์ํจ.
Ranger - Admin ์ค์น
1
2
3
4
5
|
$ cd ${RANGER_SRC}/target/
$ ls -al
-rw-r--r--. 1 root root 248560962 Jul 1 17:50 ranger-2.1.0-admin.tar.gz
$ sudo tar xvzf ranger-2.1.0-admin.tar.gz
$ cd ranger-2.1.0-admin
|
cs |
Ranger - Admin Config ์ค์
1
2
3
4
5
6
7
8
9
10
11
12
13
|
$ vi ranger-2.1.0-admin/install.properties
###
DB_FLAVOR=POSTGRES
SQL_CONNECTOR_JAR=/usr/share/java/postgresql.jar
db_root_user=postgres
db_root_password=postgres
db_host=localhost:5432/ranger
db_name=ranger
db_user=rangeradmin
db_password=rangeradmin
audit_solr_urls=http://localhost:6083/solr/ranger_audits
haddop_conf=/opt/hadoop-3.1.1/etc/hadoop
###
|
cs/ใ ใดใท |
/usr/share/java/ dir์ postgresql JDBC ์ค์น ํ์!
Solr ์คํ๋์ด ์๋ ์ํ์์ solr-ranger set up
1
|
ranger-2.1.0-admin/contrib/solr_for_audit_setup/setup.sh
|
cs |
Solr ์คํ
1
|
# ./opt/solr/ranger_audit_server/scripts/start_solr.sh
|
cs |
Ranger-admin setup.sh ์คํ
1
|
# ranger-2.0.0-admin/set_globals.sh
# ranger-2.0.0-admin/setup.sh |
cs |
์ฑ๊ณต๋ก๊ทธ
1
2
3
4
5
|
2021-07-02 14:09:47,267 [I] --------- Verifying Ranger DB connection ---------
2021-07-02 14:09:47,267 [I] Checking connection..
2021-07-02 14:09:47,267 [JISQL] /usr/lib/jvm/java-1.8.0-openjdk/bin/java -cp /usr/share/java/postgresql-42.2.8.jar:/opt/ranger-2.1.0-admin/jisql/lib/* org.apache.util.sql.Jisql -driver postgresql -cstring jdbc:postgresql://localhost:5432/ranger # for db_flavor=mysql|postgres|sqla|mssql #for example: db_host=localhost:3306/ranger -u rangeradmin -p '********' -noheader -trim -c \; -query "select 1;"
2021-07-02 14:09:47,508 [I] Checking connection passed.
Installation of Ranger PolicyManager Web Application is completed.
|
cs |
ranger-admin ์คํ
1
|
$ sudo ranger-admin start
|
cs |
6080 ํฌํธ ์ ์ํ๋ฉด ranger ํ๋ฉด ํ์ธ๊ฐ๋ฅํจ.
ID/PW : admin
728x90
๋ฐ์ํ