如何在OpenSUSE 13.2上安装owncloud 7

如何在OpenSUSE 13.2上安装owncloud 7 本教程基于OpenSuse 13.2服务器,因此您应该设置一个基本的OpenSuse 13.2服务器安装...

如何在OpenSUSE 13.2上安装owncloud 7

版本1.0
作者:莫比·比拉

1初步说明

本教程基于OpenSuse 13.2服务器,因此您应该在继续本教程之前设置基本的OpenSuse 13.2服务器安装。 系统应该有一个静态IP地址。 我在本教程中使用192.168.0.20作为我的IP地址,并将server1.example.com用作主机名。 再次,我有192.168.0.99作为OpenSUSE Desktop和desktop1.example.com的 IP地址作为主机名。 我将在OpenSUSE Desktop中使用user = Mohib进行安装和配置。

2安装ownCloud 7

ownCloud是一个Web应用程序,可以从集中的位置存储和提供内容,就像Dropbox一样。 不同之处在于,ownCloud 7允许您在自己的计算机上托管服务软件,从而将您的个人数据放在其他人的服务器上。

我们将首先下载与ownCloud软件相关联的发行版:

2安装owncloud 7

OwnCloud是一个Web应用程序,可以从集中的位置存储和提供内容,就像Dropbox一样。 不同之处在于,ownCloud 7允许您在自己的计算机上托管服务软件,从而将您的个人数据放在其他人的服务器上。


我们将首先下载与ownCloud软件相关联的发行版:

zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:community/openSUSE_13.2/isv:ownCloud:community.repo
zypper refresh

最后,更新包数据库并安装ownCloud:

zypper install owncloud

server1:~ # zypper install owncloud
Loading repository data...
Reading installed packages...
Resolving package dependencies...

Problem: owncloud-7.0.3-14.1.noarch requires php5 >= 5.3.3, but this requirement cannot be provided
  uninstallable providers: php5-5.6.1-1.1.x86_64[openSUSE-13.2-0]
                   php5-5.6.1-1.1.i586[repo-oss]
                   php5-5.6.1-1.1.x86_64[repo-oss]
                   php5-5.6.1-1.1.x86_64[repo-oss]
                   php5-5.6.1-4.1.x86_64[repo-update]
 Solution 1: deinstallation of patterns-openSUSE-minimal_base-conflicts-20141007-2.1.x86_64
 Solution 2: do not install owncloud-7.0.3-14.1.noarch
 Solution 3: do not install owncloud-7.0.3-14.1.noarch
 Solution 4: break owncloud-7.0.3-14.1.noarch by ignoring some of its dependencies

Choose from above solutions by number or cancel [1/2/3/4/c] (c): <--1

ownCloud将安装Apache2与其依赖关系,如果没有自动安装手动安装apache2:

zypper install apache2

每次启动时,Apache都必须重新启动,所以我们将其添加为:

systemctl enable apache2.service
systemctl start apache2.service

此外,我们需要允许具有apache的SELINUX在httphttps安全的shell服务器上 ,如下所示:

yast2

Goto 安全和用户 - > 防火墙设置 ,然后转到允许的服务



在防火墙的允许服务中,在外部区域中添加apache2的三个服务,即HTTP服务器HTTPS服务器安全Shell服务器









添加服务退出yast2后

3在OpenSuse 13.2上的ownCloud 7配置

此外,我们需要安装Mariadb来获取ownCloud的功能,通常它被安装为ownCloud的依赖。 但是如果没有安装,那么我们需要安装它,如下所示:

zypper install mariadb

systemctl enable mysql.service
systemctl start mysql.service

我们将配置我们的ownCloud服务器,以利用更强大的MySQL数据库,而不是SQLite默认实现。 为此,我们必须首先将MySQL配置为:

mysql_secure_installation

[
server1:~ # mysql_secure_installation
/usr/bin/mysql_secure_installation: line 379: find_mysql_client: command not found

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!

In order to log into MariaDB to secure it, we'll need the current
password for the root user.  If you've just installed MariaDB, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.

Enter current password for root (enter for none): <--ENTER
OK, successfully used password, moving on...

Setting the root password ensures that nobody can log into the MariaDB
root user without the proper authorisation.

Set root password? [Y/n] <--ENTER
New password: <--mariadbpassword
Re-enter new password: <--mariadbpassword
Password updated successfully!
Reloading privilege tables..
 ... Success!


By default, a MariaDB installation has an anonymous user, allowing anyone
to log into MariaDB without having to have a user account created for
them.  This is intended only for testing, and to make the installation
go a bit smoother.  You should remove them before moving into a
production environment.

Remove anonymous users? [Y/n]  <--ENTER
 ... Success!

Normally, root should only be allowed to connect from 'localhost'.  This
ensures that someone cannot guess at the root password from the network.

Disallow root login remotely? [Y/n] <--ENTER
 ... Success!

By default, MariaDB comes with a database named 'test' that anyone can
access.  This is also intended only for testing, and should be removed
before moving into a production environment.

Remove test database and access to it? [Y/n] <--ENTER
 - Dropping test database...
 ... Success!
 - Removing privileges on test database...
 ... Success!

Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.

Reload privilege tables now? [Y/n] <--ENTER
 ... Success!

Cleaning up...

All done!  If you've completed all of the above steps, your MariaDB
installation should now be secure.

Thanks for using MariaDB!
server1:~ #

现在转向Mysql提示符:

mysql -u root -p

将您之前选择的Mysql密码,并在Mysql提示符下为ownCloud创建数据库:

CREATE DATABASE owncloud;

为新的MySQL用户分配权限以处理ownCloud的数据库操作:

GRANT ALL ON owncloud.* to 'root'@'localhost' IDENTIFIED BY 'database_password';

exit

现在我们需要为apache2启用php5和以下设置:

 a2enmod php5

vi /srv/www/htdocs/owncloud/.htaccess

Options +FollowSymLinks
[...]

现在,如果您在浏览器中访问您的IP地址或域名后跟“/ owncloud”,您将看到如下所示的页面:


点击存储和数据库



现在选择MySQL / MariaDB并创建一个管理员帐户,就像我的情况我已经选择了自己的cloud作为我的管理员帐户和该用户所需的密码:



在MySQL / MariaDB下面的下方标签中,输入username = root password = database_password databasename = owncloud

然后按完成设置




4使用OpenSuse 13.2 Desktop安装ownCloud 7共享

我们可以通过owncloud-client安装在OpenSuse 13.2 Desktop上安装ownCloud-7共享。 对于此运行,我使用desktop1.example.com在OpenSUSE桌面中使用user = Qmail运行所有命令:

sudo zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_13.2/isv:ownCloud:desktop.repo
zypper refresh
sudo zypper install owncloud-client

如果您的OpenSUSE Desktop版本不同,请添加适当的存储库,请检查此链接

接下来,我们需要根据OpenSUSE ownCloud-server共享配置ownCloud客户端。 打开ownclient-client:



将服务器地址设置为192.168.0.20/owncloud



将凭据放在我的情况下,它是Username = owncloudpassword = database_password



连接



它将连接您的系统与OpneSuse服务器共享,共享数据将被同步。