Redis Multi-instance +mongodb basic configuration +ldap+svn

Source: Internet
Author: User
Tags ldap mongodb mongodb download redis redis version svn

Redis Multi-instance

[[email protected] redis-stable]# cp -p redis.conf redis6380.conf (拷贝出一个配置文件)[[email protected] redis-stable]# grep 6380 redis6380.conf (参数修改,按需求修改)port 6380pidfile /var/run/redis_6380.piddbfilename dump6380.rdbappendfilename "appendonly6380.aof"# cluster-announce-bus-port 6380[[email protected] redis-stable]# redis-server redis6380.conf (启动方式)2161:C 29 May 20:41:38.275 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo2161:C 29 May 20:41:38.276 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=2161, just started2161:C 29 May 20:41:38.276 # Configuration loaded[[email protected] redis-stable]# ps -ef|grep redisroot      2162     1  0 20:41 ?        00:00:00 redis-server      2167  1858  0 20:41 pts/1    00:00:00 grep redis

The basics of MongoDB today

MongoDB download on Demand

[[email protected] conf]# getenforce permissive[[email protected] conf]# service iptables statusiptables: Firewall is not running. [[email protected] mulu]# tar-xf mongodb-linux-x86_64-rhel62-4.0.0-rc0.tgz (unzip the precompiled package) [[email protected] mulu]# ln-s mongodb-linux-x86_64-rhel62-4.0.0-rc0 MONGO (soft link, convenient operation) monmongodb start mode [[email protected] mongodb-linux-x86_64-rhel62-4.0.0-rc0]# mongod--dbpath Data--logpath log/mongodb.log--logappend--pidfilepath Pid/ & (command line startup) [[email protected] mulu]# CD mongo[[email protected] mongo]# lsbin conf data GNU-A GPL-3.0 log MPL-2 pid README third-party-notices (except the bin directory, the others are the directories created by themselves) [[email protected] mongo]# CD Conf/[[em Ail protected] conf]# lsmongodb.cnf[[email protected] conf]# cat mongodb.cnf Dbpath=/opt/mulu/mongo/data logpath=/opt/mulu/mongo/log/mongodb.loglogappend=truepidfilepath=/opt/mulu/mongo/pid/mongodb.pidport=27017[[ Email protected] conf]# mongod-f mongodb.cnf & (fileStart) MongoDB go in the way [[email protected] conf]# MONGO (directly into the local MongoDB, Security issues with Waring) MongoDB multi-instance only need to modify the parameters of the file to MongoDB Security Policy 1. Create Superuser > Use adminswitched to DB admin> db.createuser (... {... User: "Adminuser",... pwd: "123",... roles: [{role: "Useradminanydatabase", DB: "admin"}] ...} ... )            Successfully added User: {"user": "Adminuser", "roles": [{"Role": "Useradminanydatabase",     "DB": "admin"}]}[[email protected] log]# ps-ef|grep mongodbroot 2633 1858 0 21:48 PTS/1 00:00:15 mongod-f mongodb.cnfroot 2734 2523 0 22:22 pts/0 00:00:00 grep mongodb[[email protected] log]  # Kill 2633 (stop service) [[[email protected] conf]# mongod-f mongodb.cnf & (restart) > Use testswitched to DB test> Db.example.insert ({"A": "A"}) Writeresult ({"ninserted": 1}) > dbs2018-05-29t22:25:08.743+0800 E QUERY [JS] Referenc Eerror:dbs is not defined: @ (shell):1:1> show Dbsadmin 0.000GBconfig 0.000GBlocal  0.000GBtest 0.000gb> Db.example.insert ({"A": "B"}) Writeresult ({"ninserted": 1}) > Db.example.insert ({"A": "C"}) Writeresult ({"ninserted": 1}) > Db.example.insert ({"A": "D"}) Writeresult ({"ninserted": 1}) > Db.example.insert ( {"A": "E"}) Writeresult ({"ninserted": 1}) > show dbsadmin 0.000GBconfig 0.000GBlocal 0.000GBtest 0.000GB (insert a lot of data, but no amount of increase , confirm that no account password login, unable to operate) [[email protected] conf]# mongod-f mongodb.cnf--auth & (Login with authentication) [[email protected] conf]# MONGO (do not enter user password) MongoDB Shell version v4.0.0-rc0connecting to:mongodb:// Server version: 4.0.0-rc0> show dbs> (see nothing) [[email protected] conf]# mongo-u ' adminuser '-P ' 123 '--au Thenticationdatabase "admin" (plus user password to see) MongoDB Shell version v4.0.0-rc0connecting to:mongodb:// Server version:4.0.0-rc0> show dbsadmin 0.000GBconfig 0.000GBlocal 0.000GBtest 0.000gb[ [email protected] conf]# MONGO (second authentication) MongoDB shEll version v4.0.0-rc0connecting TO:MONGODB:// server version:4.0.0-rc0> use adminswitched to DB admin> Db.auth ("Adminuser", "123") (enter user password here) 1> show Dbsadmin 0.000GBconfig 0.000GBlocal 0.000GBtest 0.00 0GB

MongoDB Configuration Master-Slave mode

LDAP+SVN---Take a look here.
1. In the/etc/hosts file, write your IP and hostname parsing

Redis Multi-instance +mongodb basic configuration +ldap+svn

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.