新手学习Linux——owncloud搭建私有云

新手学习Linux——owncloud搭建私有云
新手学习Linux——owncloud搭建私有云
新手学习Linux——owncloud搭建私有云
(自行理解)
----------------分割线----------------------
新手学习Linux——owncloud搭建私有云
概述

首先先把防火墙关掉
iptables -F
iptables -X
iptables -Z
setenforce 0

ownCloud所用PHP须5.6或以上才可以,先安装非官方源。

[root@zwt ~]# yum -y install epel-release

[root@zwt~]# rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm

[root@zwt~]# yum install --enablerepo=remi --enablerepo=remi-php56 php php-opcache php-devel php-mbstring php-mcrypt php-mysqlnd php-phpunit-PHPUnit php-pecl-xdebug php-pecl-xhprof php56-php-gd php56-php-fpm php-gd

安装apache服务。
[root@zwt ~]# yum install httpd*

安装Mariadb 数据库。
[root@zwt ~]# yum install mariadb*

启动服务

启动Apache:
[root@zwt ~]# systemctl start httpd

启动MariaDB:
[root@zwt ~]# systemctl start mariadb

在搭建好的lamp上部署owncloud环境,在本地已经有下好的包owncloud-zwt0.0.4,所以通过Xshell上面的Xftp把压缩包放进去。

用unzip把包解压
[root@zwt ~]# unzip owncloud-zwt0.0.4.zip

拷贝包内的软件到指定网页目录下
[root@zwt ~]# cp -r owncloud/* /var/www/html/

为Web服务器上文件目录设置读写权限:修改权限为Apache用户
[root@zwt ~]# chown -R apache.apache /var/www/html/

或者从官方网站下载owncloud。运行以下命令(也可以下载其他版本):
wgethttps://download.owncloud.org/community/ owncloud-zwt0.0.9.tar.bz2

解压文件:

tar -jxvf owncloud-7.0.0.tar.bz2 -C/var/www/html/

创建数据库

root@zwt ~]# mysqladmin -u root password "000000"

登陆数据库

[root@zwt ~]# mysql -u root -p

Enter password:

Welcome to the MariaDB monitor. Commands end with ; or \g.

Your MariaDB connection id is 3

Server version: 5.5.60-MariaDB MariaDB Server

Copyright (c) 2000, 20zwt8, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> creat database owncloud;

ERROR zwt064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'creat database owncloud' at line zwt

MariaDB [(none)]> exit

Bye

最后重启机器。
[root@zwt ~]# reboot

完成。

猜你喜欢

转载自blog.51cto.com/13955620/2176370
今日推荐