Set Redis-server as boot entry in UBUNTU14 system

Source: Internet
Author: User

After the 1.redis installation is complete (I am redis-3.0.7), modify the configuration file redis.conf, modify the following items

Note: The following actions are performed under the root user

Gedit redis.conf Open File for modification

A) Daemonize Yes

b) dir/home/pc/program/redis-3.0.7/

c) pidfile/var/run/redis_6379.pid

2. Create a folder

Mkdir/etc/redis

3. Copying files

1) CP redis.conf/etc/redis/9379.conf//Move the configuration file to the location of the script file description, which is done according to the script file. Of course, you can also modify the script file and then follow the script file to the appropriate location

Description: The script file here is in Utils/redis_init_script

2) CD Utils

CP redis_init_script/etc/init.d/redis_3679

4. Set boot up, shut down

UPDATE-RC.D redis-server Defaults

[Email protected]:~# update-rc.d redis_6379 Defaults
Update-rc.d:warning:/etc/init.d/redis_6379 Missing LSB information
Update-rc.d:see Adding system Startup for/etc/init.d/redis_6379 ...
/etc/rc0.d/k20redis_6379. /init.d/redis_6379
/etc/rc1.d/k20redis_6379. /init.d/redis_6379
/etc/rc6.d/k20redis_6379. /init.d/redis_6379
/etc/rc2.d/s20redis_6379. /init.d/redis_6379
/etc/rc3.d/s20redis_6379. /init.d/redis_6379
/etc/rc4.d/s20redis_6379. /init.d/redis_6379
/etc/rc5.d/s20redis_6379. /init.d/redis_6379

5. Start Redis-server

1)/etc/init.d/redis_6379 Start

2) Redis-server

6. After the boot, the Redis-server will start automatically.

Set Redis-server as boot entry in UBUNTU14 system

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: info-contact@alibabacloud.com 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.