aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkaf24@localhost.localdomain <kaf24@localhost.localdomain>2006-08-28 13:05:00 +0100
committerkaf24@localhost.localdomain <kaf24@localhost.localdomain>2006-08-28 13:05:00 +0100
commitb643712258af9e56dad4d3e8379548fecafb1090 (patch)
treeee6d93474f9f78bd02b97cc395f6b24f9b782bdf
parent10a74ed0a21af7578b62582c4e43c1312eb25fdd (diff)
downloadxen-b643712258af9e56dad4d3e8379548fecafb1090.tar.gz
xen-b643712258af9e56dad4d3e8379548fecafb1090.tar.bz2
xen-b643712258af9e56dad4d3e8379548fecafb1090.zip
[XEND] Move all of the various log files created by xen to
be under /var/log/xen instead of under /var/log directly. This has the advantage of cleaning things up a little and also can make it easier to restrict the permissions needed by xend. Signed-off-by: Jeremy Katz <katzj@redhat.com>
-rw-r--r--docs/man/xend-config.sxp.pod.52
-rw-r--r--docs/misc/xend.tex4
-rw-r--r--docs/src/user.tex4
-rw-r--r--tools/Makefile1
-rw-r--r--tools/examples/xen-hotplug-common.sh2
-rw-r--r--tools/examples/xend-config.sxp2
-rw-r--r--tools/ioemu/patches/qemu-logging2
-rw-r--r--tools/ioemu/vl.c2
-rw-r--r--tools/misc/xend2
-rw-r--r--tools/python/xen/util/bugtool.py4
-rw-r--r--tools/python/xen/xend/XendRoot.py2
-rw-r--r--tools/python/xen/xend/server/params.py4
-rw-r--r--tools/security/python/xensec_gen/main.py2
13 files changed, 17 insertions, 16 deletions
diff --git a/docs/man/xend-config.sxp.pod.5 b/docs/man/xend-config.sxp.pod.5
index fddba9d14c..5f949dee3b 100644
--- a/docs/man/xend-config.sxp.pod.5
+++ b/docs/man/xend-config.sxp.pod.5
@@ -23,7 +23,7 @@ The following lists the daemon configuration parameters:
=item I<logfile>
The location of the file to record runtime log messages. Defaults to
-I</var/log/xend.log>.
+I</var/log/xen/xend.log>.
=item I<loglevel>
diff --git a/docs/misc/xend.tex b/docs/misc/xend.tex
index e58ae6be80..79638037e6 100644
--- a/docs/misc/xend.tex
+++ b/docs/misc/xend.tex
@@ -214,7 +214,7 @@ a sequence of s-expressions. The configuration parameters are:
Configuration scripts ({\it e.g.} for network-script) are looked for in {\tt /etc/xen}
unless their name begins with '/'.
-Xend sends its log output to {\tt /var/log/xend.log}. This is a rotating logfile,
+Xend sends its log output to {\tt /var/log/xen/xend.log}. This is a rotating logfile,
and logs are moved onto {\tt xend.log.1} {\it etc.} as they get large. Old logs may
be deleted.
@@ -411,7 +411,7 @@ allows access to some debugging functions:
\end{itemize}
When tracing is on xend logs all functions calls and exceptions to
-{\tt /var/log/xend.trace}.
+{\tt /var/log/xen/xend.trace}.
\begin{thebibliography}{99}
diff --git a/docs/src/user.tex b/docs/src/user.tex
index eeb2b26245..8b4cec9ace 100644
--- a/docs/src/user.tex
+++ b/docs/src/user.tex
@@ -973,8 +973,8 @@ using the \texttt{xm} tool.
\subsection{Logging}
-As \xend\ runs, events will be logged to \path{/var/log/xend.log} and
-(less frequently) to \path{/var/log/xend-debug.log}. These, along with
+As \xend\ runs, events will be logged to \path{/var/log/xen/xend.log} and
+(less frequently) to \path{/var/log/xen/xend-debug.log}. These, along with
the standard syslog files, are useful when troubleshooting problems.
\subsection{Configuring \Xend\ }
diff --git a/tools/Makefile b/tools/Makefile
index 737b6cff78..d16b590fe7 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -39,6 +39,7 @@ install: check
done
$(MAKE) ioemuinstall
$(INSTALL_DIR) -p $(DESTDIR)/var/xen/dump
+ $(INSTALL_DIR) -p $(DESTDIR)/var/log/xen
.PHONY: clean
clean: check_clean
diff --git a/tools/examples/xen-hotplug-common.sh b/tools/examples/xen-hotplug-common.sh
index d56d2da13a..c825dae593 100644
--- a/tools/examples/xen-hotplug-common.sh
+++ b/tools/examples/xen-hotplug-common.sh
@@ -21,7 +21,7 @@ dir=$(dirname "$0")
. "$dir/xen-script-common.sh"
. "$dir/locking.sh"
-exec 2>>/var/log/xen-hotplug.log
+exec 2>>/var/log/xen/xen-hotplug.log
export PATH="/sbin:/bin:/usr/bin:/usr/sbin:$PATH"
export LANG="POSIX"
diff --git a/tools/examples/xend-config.sxp b/tools/examples/xend-config.sxp
index 9d1be3fb56..9dacf7d3c6 100644
--- a/tools/examples/xend-config.sxp
+++ b/tools/examples/xend-config.sxp
@@ -11,7 +11,7 @@
# Commented out entries show the default for that entry, unless otherwise
# specified.
-#(logfile /var/log/xend.log)
+#(logfile /var/log/xen/xend.log)
#(loglevel DEBUG)
#(xend-http-server no)
diff --git a/tools/ioemu/patches/qemu-logging b/tools/ioemu/patches/qemu-logging
index 901f5db3fe..a2001d9ac6 100644
--- a/tools/ioemu/patches/qemu-logging
+++ b/tools/ioemu/patches/qemu-logging
@@ -43,7 +43,7 @@ Index: ioemu/vl.c
/* default mac address of the first network interface */
+ /* init debug */
-+ sprintf(qemu_dm_logfilename, "/var/log/qemu-dm.%d.log", getpid());
++ sprintf(qemu_dm_logfilename, "/var/log/xen/qemu-dm.%d.log", getpid());
+ cpu_set_log_filename(qemu_dm_logfilename);
+ cpu_set_log(0);
+
diff --git a/tools/ioemu/vl.c b/tools/ioemu/vl.c
index 878759acbb..dfcb3c82d1 100644
--- a/tools/ioemu/vl.c
+++ b/tools/ioemu/vl.c
@@ -5924,7 +5924,7 @@ int main(int argc, char **argv)
/* default mac address of the first network interface */
/* init debug */
- sprintf(qemu_dm_logfilename, "/var/log/qemu-dm.%d.log", getpid());
+ sprintf(qemu_dm_logfilename, "/var/log/xen/qemu-dm.%d.log", getpid());
cpu_set_log_filename(qemu_dm_logfilename);
cpu_set_log(0);
diff --git a/tools/misc/xend b/tools/misc/xend
index 82198fcea3..ff58b30773 100644
--- a/tools/misc/xend
+++ b/tools/misc/xend
@@ -86,7 +86,7 @@ def start_xenstored():
XENSTORED_TRACE = os.getenv("XENSTORED_TRACE")
cmd = "xenstored --pid-file /var/run/xenstore.pid"
if XENSTORED_TRACE:
- cmd += " -T /var/log/xenstored-trace.log"
+ cmd += " -T /var/log/xen/xenstored-trace.log"
s,o = commands.getstatusoutput(cmd)
def start_consoled():
diff --git a/tools/python/xen/util/bugtool.py b/tools/python/xen/util/bugtool.py
index 3e027d2dff..77df9d4420 100644
--- a/tools/python/xen/util/bugtool.py
+++ b/tools/python/xen/util/bugtool.py
@@ -43,8 +43,8 @@ TITLE_RE = re.compile(r'<title>(.*)</title>')
FILES_TO_SEND = [ '/var/log/' + x for x in
[ 'syslog', 'messages', 'debug',
- 'xend.log', 'xend-debug.log', 'xenstored-trace.log',
- 'xen-hotplug.log' ] ]
+ 'xen/xend.log', 'xen/xend-debug.log', 'xen/xenstored-trace.log',
+ 'xen/xen-hotplug.log' ] ]
#FILES_TO_SEND = [ ]
diff --git a/tools/python/xen/xend/XendRoot.py b/tools/python/xen/xend/XendRoot.py
index 5f0026907e..6e87dc6274 100644
--- a/tools/python/xen/xend/XendRoot.py
+++ b/tools/python/xen/xend/XendRoot.py
@@ -52,7 +52,7 @@ class XendRoot:
block_script_dir = "/etc/xen/scripts"
"""Default path to the log file. """
- logfile_default = "/var/log/xend.log"
+ logfile_default = "/var/log/xen/xend.log"
"""Default level of information to be logged."""
loglevel_default = 'DEBUG'
diff --git a/tools/python/xen/xend/server/params.py b/tools/python/xen/xend/server/params.py
index 32ac063d1f..c7099e2506 100644
--- a/tools/python/xen/xend/server/params.py
+++ b/tools/python/xen/xend/server/params.py
@@ -39,8 +39,8 @@ def getenv(var, val, conv=None):
# The following parameters could be placed in a configuration file.
XEND_PID_FILE = '/var/run/xend.pid'
-XEND_TRACE_FILE = '/var/log/xend.trace'
-XEND_DEBUG_LOG = '/var/log/xend-debug.log'
+XEND_TRACE_FILE = '/var/log/xen/xend.trace'
+XEND_DEBUG_LOG = '/var/log/xen/xend-debug.log'
XEND_USER = 'root'
XEND_DEBUG = getenv("XEND_DEBUG", 0, conv=int)
XEND_DAEMONIZE = getenv("XEND_DAEMONIZE", not XEND_DEBUG, conv=int)
diff --git a/tools/security/python/xensec_gen/main.py b/tools/security/python/xensec_gen/main.py
index a498a486d2..3021080cd2 100644
--- a/tools/security/python/xensec_gen/main.py
+++ b/tools/security/python/xensec_gen/main.py
@@ -34,7 +34,7 @@ import CGIHTTPServer
gHttpPort = 7777
gHttpDir = '/var/lib/xensec_gen'
-gLogFile = '/var/log/xensec_gen.log'
+gLogFile = '/var/log/xen/xensec_gen.log'
gUser = 'nobody'
gGroup = 'nobody'