如何将red5服务器视频文件所有者更改为apache用户

发布于 2024-09-16 20:23:46 字数 120 浏览 19 评论 0原文

我安装了red5服务器。它运行良好。我想更改 red5 服务器创建的视频文件的默认所有者。目前它是root。我希望将其更改为apache,以便我可以通过php unlink命令删除该文件。

任何帮助将不胜感激。

I have a red5 server installed. It is working fine. I want to changes the default owner of the video file created by red5 server. Currently it is root.I want this to be changed to apache so that I can delete this file through php unlink command.

Any help will be appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

各自安好 2024-09-23 20:23:47

bigbluebutton 项目做了类似的事情,他们以自己的用户身份运行 red5,您可以在安装 red5 后修改此信息以使用 apache 用户。

  chown -R root.root /usr/share/red5
  chown -R apache:apache /usr/share/red5/log
  chmod 755 /usr/share/red5/log
  chgrp apache /usr/share/red5/webapps
  chmod 775 /usr/share/red5/webapps

您需要调整路径、组和用户以适合您的安装。我假设您的用户和组名为“apache”。最后一部分是确保您以“apache”用户身份启动 red5;这很可能需要更改您的启动脚本。

The bigbluebutton project does something similar wherein they run red5 as its own user, you could modify this information to use the apache user instead after installing red5.

  chown -R root.root /usr/share/red5
  chown -R apache:apache /usr/share/red5/log
  chmod 755 /usr/share/red5/log
  chgrp apache /usr/share/red5/webapps
  chmod 775 /usr/share/red5/webapps

You need to adjust the paths, groups, and users to fit your installation. I am assuming that your user and group are named "apache". The final part of this is to make sure you start red5 as the "apache" user; this will most likely require a change to your startup scripts.

無心 2024-09-23 20:23:47

如果您可以访问您的服务器并且它是Linux,则更改此命令的命令是

chown name-of-new-owner:group-to-belong name-of-the-file

如果您想在文件夹内的许多文件中应用,请在chown后尝试-R。您可能还需要在 chown 前面添加 sudo。

顺便说一句,apache 用户和组是 www-data。

If you have access to your server and it is linux, the command to change this is

chown name-of-new-owner:group-to-belong name-of-the-file

If you want to apply in many files inside a folder try -R after chown. You may need also a sudo in front of the chown.

Btw apache user and group is www-data.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文