memcache can't run as root without the -u switch

來源:互聯網
上載者:User
memcached是一款高速、分布式的記憶體緩衝系統。其官方首頁在http://www.danga.com/memcached/
1。安裝前的準備
要安裝memcached,需要有libevent的支援 。
centos通過
yum install libevent-devel
安裝即可
其它版本可通過安裝libevent的源檔案獲得

2。下載安裝 目前最新版本為 memcached-1.2.6.tar.gz
cd /usr/src
wget http://www.danga.com/memcached/dist/memcached-1.2.6.tar.gz
tar xzf memcached-1.2.6.tar.gz
cd memcached-1.2.6
./configure --prefix=/usr/local/memcached
make
make install

3。啟動
/usr/local/memcached/bin/memcached -d -m 512 -l 127.0.0.1 -p 10000 -u root
表示已守護進程的方式啟動,監聽於 127.0.0.1 的10000連接埠,使用root使用者,最大使用512M記憶體
可以同時開多個memcached,但要監聽在不同的連接埠.

說明:如果沒有帶 -u root 的話就會報:
can't run as root without the -u switch
解決:帶-u root就行。

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.