AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-209307

arcee123's questions

Martin Hope
arcee123
Asked: 2018-11-01 08:24:21 +0800 CST

在 apache 上设置虚拟主机

  • -1

我有一个在 WEBMIN 下运行的 Apache 服务器。

我有这个虚拟服务器:

<VirtualHost pmaconfig.trekfederation.com>
DocumentRoot /var/www/phpmyadmin
ServerName pmaconfig.trekfederation.com
</VirtualHost>

更新 1 ...更改了定义

<VirtualHost pmaconfig.trekfederation.com:80>
DocumentRoot /var/www/phpmyadmin
ServerName pmaconfig.trekfederation.com
</VirtualHost>

我所期待的:当给定与服务器名称匹配的 url 时,页面在 /var/www/phpmyadmin 下呈现。

我所看到的:/var/www/html 的目录列表。

我在 apache2.conf 下看不到这个目录(见下文)。没有其他虚拟服务器。我错过了什么?

谢谢

APACHE2.conf 的内容

# Global configuration
#

#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# NOTE!  If you intend to place this on an NFS (or otherwise network)
# mounted filesystem then please read the Mutex documentation (available
# at <URL:http://httpd.apache.org/docs/2.4/mod/core.html#mutex>);
# you will save yourself a lot of trouble.
#
# Do NOT add a slash at the end of the directory path.
#
#ServerRoot "/etc/apache2"

#
# The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
#
#Mutex file:${APACHE_LOCK_DIR} default

#
# The directory where shm and other runtime files will be stored.
#

DefaultRuntimeDir ${APACHE_RUN_DIR}

#
# PidFile: The file in which the server should record its process
# identification number when it starts.
# This needs to be set in /etc/apache2/envvars
#
PidFile ${APACHE_PID_FILE}

#
# Timeout: The number of seconds before receives and sends time out.
#
Timeout 300

#
# KeepAlive: Whether or not to allow persistent connections (more than
# one request per connection). Set to "Off" to deactivate.
#
KeepAlive On

#
# MaxKeepAliveRequests: The maximum number of requests to allow
# during a persistent connection. Set to 0 to allow an unlimited amount.
# We recommend you leave this number high, for maximum performance.
#
MaxKeepAliveRequests 100

#
# KeepAliveTimeout: Number of seconds to wait for the next request from the
# same client on the same connection.
#
KeepAliveTimeout 5


# These need to be set in /etc/apache2/envvars
User ${APACHE_RUN_USER}
Group ${APACHE_RUN_GROUP}

#
# HostnameLookups: Log the names of clients or just their IP addresses
# e.g., www.apache.org (on) or 204.62.129.132 (off).
# The default is off because it'd be overall better for the net if people
# had to knowingly turn this feature on, since enabling it means that
# each client request will result in AT LEAST one lookup request to the
# nameserver.
#
HostnameLookups Off

# ErrorLog: The location of the error log file.
# If you do not specify an ErrorLog directive within a <VirtualHost>
# container, error messages relating to that virtual host will be
# logged here.  If you *do* define an error logfile for a <VirtualHost>
# container, that host's errors will be logged there and not here.
#
ErrorLog ${APACHE_LOG_DIR}/error.log

#
# LogLevel: Control the severity of messages logged to the error_log.
# Available values: trace8, ..., trace1, debug, info, notice, warn,
# error, crit, alert, emerg.
# It is also possible to configure the log level for particular modules, e.g.
# "LogLevel info ssl:warn"
#
LogLevel warn

# Include module configuration:
IncludeOptional mods-enabled/*.load
IncludeOptional mods-enabled/*.conf

# Include list of ports to listen on
Include ports.conf


# Sets the default security model of the Apache2 HTTPD server. It does
# not allow access to the root filesystem outside of /usr/share and /var/www.
# The former is used by web applications packaged in Debian,
# the latter may be used for local directories served by the web server. If
# your system is serving content from a sub-directory in /srv you must allow
# access here, or in any related virtual host.
<Directory />
    Options FollowSymLinks
    AllowOverride None
    Require all denied
</Directory>

<Directory /usr/share>
    AllowOverride None
    Require all granted
</Directory>

<Directory /var/www/>
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

#<Directory /srv/>
#   Options Indexes FollowSymLinks
#   AllowOverride None
#   Require all granted
#</Directory>




# AccessFileName: The name of the file to look for in each directory
# for additional configuration directives.  See also the AllowOverride
# directive.
#
AccessFileName .htaccess

#
# The following lines prevent .htaccess and .htpasswd files from being
# viewed by Web clients.
#
<FilesMatch "^\.ht">
    Require all denied
</FilesMatch>


#
# The following directives define some format nicknames for use with
# a CustomLog directive.
#
# These deviate from the Common Log Format definitions in that they use %O
# (the actual bytes sent including headers) instead of %b (the size of the
# requested file), because the latter makes it impossible to detect partial
# requests.
#
# Note that the use of %{X-Forwarded-For}i instead of %h is not recommended.
# Use mod_remoteip instead.
#
LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined
LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %O" common
LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent

# Include of directories ignores editors' and dpkg's backup files,
# see README.Debian for details.

# Include generic snippets of statements
IncludeOptional conf-enabled/*.conf

# Include the virtual host configurations:
IncludeOptional sites-enabled/*.conf

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
virtualhost
  • 2 个回答
  • 749 Views
Martin Hope
arcee123
Asked: 2017-02-28 13:12:36 +0800 CST

在 CentOS 7 上从源代码构建时如何将 postgresql 9.6.2 设置为自动启动

  • 1

我已经从源代码运行安装了 postgresql 9.6.2。我执行了.configure,make和make install命令,完美地安装了数据库。然后我安装了用户,使用createdb命令创建了数据库,并且能够在本地登录到 postgresql 用户以执行本地 sql 查询。

我的问题是自动启动。如何设置它以使自动启动正常工作?命令service postgresql restart错误说no unit。我也试过postgresql-9.6, postgresql-9.6.2,postgresql-962和其他几个都无济于事。

我该如何配置?谢谢。

linux postgresql centos7
  • 1 个回答
  • 502 Views
Martin Hope
arcee123
Asked: 2017-01-05 09:45:20 +0800 CST

在 linux 中,sysconfig 文件的 OPTIONS 行中的标志“-u”是什么意思?

  • 0

在 linux 中,sysconfig 文件的 OPTIONS 行中的标志“-u”是什么意思?

示例 - 在文件中 /etc/sysconfig/ntpd:

OPTIONS="-u ntp:ntp"

linux
  • 1 个回答
  • 998 Views
Martin Hope
arcee123
Asked: 2016-10-15 09:57:03 +0800 CST

2008 组策略管理器未将注册表首选项传播到 Windows Server 2003 框中

  • 1

我有一个带有 2008r2/2012 组策略管理器的 Windows 2008r2 域。在我的域中,我仍然有 windows server 2003 盒子(大约 50 个)

我正在尝试通过 Preferences\Windows Settings\Registry 推送注册表更新。虽然它们显示完美,但我在框中的 gpresult 注册表设置中得到了“N/A”。其他 GPO 行项目完美传播。

2003 服务器没有错误。就好像 GPO 决定不推送注册表设置一样。

值得注意的是,我还尝试添加一个启动 bat 脚本,但也没有得到传播。

我可以去哪里找出为什么没有将注册表设置推送到我的服务器?谢谢。

windows-server-2008 windows-server-2003 group-policy
  • 1 个回答
  • 99 Views
Martin Hope
arcee123
Asked: 2015-04-02 12:17:17 +0800 CST

为 AD 用户提供共享电子邮件帐户

  • 1

我有一个微软平台,带有活动目录和交换。

通常,所有 AD 用户都分配有与该用户 ID 关联的邮箱。我们的组织雇用了许多临时人员,他们来了几个月,然后离开。通常一个人替换下一个。

我的问题是交换电子邮件。在 Active Directory 中为用户分配条目时,Exchange 选项卡允许我创建邮箱,通常通过用户 ID 为用户个性化。例如:user1 通常会获得电子邮件地址 [email protected]。

我需要做的是有一个通用的交换邮箱,我可以将多个用户分配到该邮箱,这是他们的主要邮箱,而不是辅助邮箱或被授予特权的邮箱。

这样,我可以使用电子邮件 [email protected] 创建 user1,当 user1 离开时,我可以使用电子邮件 [email protected] 创建 user2。我不必在 user1@... 和 user2@... 上刻录许可证或邮箱空间。

非常感谢。任何智慧将不胜感激。

谢谢

active-directory
  • 1 个回答
  • 5430 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve