Sponsored Content
Operating Systems Linux Red Hat Httpd service not starting... Error "Documentroot must be a directory" Post 302922407 by atanubanerji on Friday 24th of October 2014 11:45:06 AM
Old 10-24-2014
It is Apache. Giving some outputs..

Code:
[root@rhel6 ~]# df -h /var/www/html
Filesystem           Size  Used Avail Use% Mounted on
/dev/mapper/vg1-lv1  7.9G  4.8G  2.8G  64% /var/www/html

[root@rhel6 ~]# mountpoint /var/www/html
/var/www/html is a mountpoint

[root@rhel6 ~]# ls -ld /var/www/html
drwxr-xr-x. 7 root root 4096 Oct  7 19:35 /var/www/html

[root@rhel6 ~]# cat /etc/httpd/conf/httpd.conf|grep DocumentRoot|grep -v "#"
DocumentRoot /var/www/html

[root@rhel6 ~]# service httpd start
Starting httpd: Syntax error on line 293 of /etc/httpd/conf/httpd.conf:
DocumentRoot must be a directory
                                                           [FAILED]
[root@rhel6 ~]#


Last edited by Scrutinizer; 10-24-2014 at 01:39 PM.. Reason: code tags
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

get two strings ending with "." and starting with "."

Hi all, In unix shell, I want to get two strings ending with "." and starting with "." from a string "chan.txt" For example, a string "chan.txt". The first string is "chan" The second string is "txt" Yours Wilson (1 Reply)
Discussion started by: wilsonchan1000
1 Replies

2. Shell Programming and Scripting

Error to "find" a matching array element in a directory

Hi, I have defined an array which holds a couple of elements which are nothing but files names. I want to find the files in a directory for the matching file name(array elements) with less than 1 day old. When I am trying to execute the code (as below), it gives an error. Your help in this... (1 Reply)
Discussion started by: mkbaral
1 Replies

3. Red Hat

"service" , "process" and " daemon" ?

Friends , Anybody plz tell me what is the basic difference between "service" , "process" and " daemon" ? Waiting for kind reply .. .. (1 Reply)
Discussion started by: shipon_97
1 Replies

4. Shell Programming and Scripting

"directory checksum error" when attempting to install tcl

OS: HP-UX Programs I want to install: expect and tcl I'm lost. I bought the book. I began reading the book. I want to install expect. I've been able to download the .z, and extract it successfully. But, of course, it apparently needs tcl and possibly tk also, and ... I... (0 Replies)
Discussion started by: instant000
0 Replies

5. Shell Programming and Scripting

Unix commands delete all files starting with "X" except "X" itself. HELP!!!!?

im a new student in programming and im stuck on this question so please please HELP ME. thanks. the question is this: enter a command to delete all files that have filenames starting with labtest, except labtest itself (delete all files startign with 'labtest' followed by one or more... (2 Replies)
Discussion started by: soccerball
2 Replies

6. AIX

AIX cp error: "A file or directory in the path does not exist"

Hello fellow UNIX fans, I'm running AIX 4.3 and getting an error message “cp: /a/file2.db: A file or directory in the path does not exist” when I run the following command: cp /b/file.db /a/file2.db It stops every time about 95% of the way through the copy process at 1,073,741,312 bits. ... (3 Replies)
Discussion started by: Jackson123
3 Replies

7. Shell Programming and Scripting

Delete files older than "x" if directory size is greater than "y"

I wrote a script to delete files which are older than "x" days, if the size of the directory is greater than "y" #!/bin/bash du -hs $1 while read SIZE ENTRY do if ; then find $1 -mtime +$2 -exec rm -f {} \; echo "Files older than $2 days deleted" else echo "free Space available"... (4 Replies)
Discussion started by: JamesCarter
4 Replies

8. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

9. Shell Programming and Scripting

Bash script - Print an ascii file using specific font "Latin Modern Mono 12" "regular" "9"

Hello. System : opensuse leap 42.3 I have a bash script that build a text file. I would like the last command doing : print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt where : print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies

10. AIX

Apache 2.4 directory cannot display "Last modified" "Size" "Description"

Hi 2 all, i have had AIX 7.2 :/# /usr/IBMAHS/bin/apachectl -v Server version: Apache/2.4.12 (Unix) Server built: May 25 2015 04:58:27 :/#:/# /usr/IBMAHS/bin/apachectl -M Loaded Modules: core_module (static) so_module (static) http_module (static) mpm_worker_module (static) ... (3 Replies)
Discussion started by: penchev
3 Replies
PIVOT_ROOT(2)						     Linux Programmer's Manual						     PIVOT_ROOT(2)

NAME
pivot_root - change the root file system SYNOPSIS
int pivot_root(const char *new_root, const char *put_old); Note: There is no glibc wrapper for this system call; see NOTES. DESCRIPTION
pivot_root() moves the root file system of the calling process to the directory put_old and makes new_root the new root file system of the calling process. The typical use of pivot_root() is during system startup, when the system mounts a temporary root file system (e.g., an initrd), then mounts the real root file system, and eventually turns the latter into the current root of all relevant processes or threads. pivot_root() may or may not change the current root and the current working directory of any processes or threads which use the old root directory. The caller of pivot_root() must ensure that processes with root or current working directory at the old root operate correctly in either case. An easy way to ensure this is to change their root and current working directory to new_root before invoking pivot_root(). The paragraph above is intentionally vague because the implementation of pivot_root() may change in the future. At the time of writing, pivot_root() changes root and current working directory of each process or thread to new_root if they point to the old root directory. This is necessary in order to prevent kernel threads from keeping the old root directory busy with their root and current working direc- tory, even if they never access the file system in any way. In the future, there may be a mechanism for kernel threads to explicitly relinquish any access to the file system, such that this fairly intrusive mechanism can be removed from pivot_root(). Note that this also applies to the calling process: pivot_root() may or may not affect its current working directory. It is therefore rec- ommended to call chdir("/") immediately after pivot_root(). The following restrictions apply to new_root and put_old: - They must be directories. - new_root and put_old must not be on the same file system as the current root. - put_old must be underneath new_root, that is, adding a nonzero number of /.. to the string pointed to by put_old must yield the same directory as new_root. - No other file system may be mounted on put_old. See also pivot_root(8) for additional usage examples. If the current root is not a mount point (e.g., after chroot(2) or pivot_root(), see also below), not the old root directory, but the mount point of that file system is mounted on put_old. new_root does not have to be a mount point. In this case, /proc/mounts will show the mount point of the file system containing new_root as root (/). RETURN VALUE
On success, zero is returned. On error, -1 is returned, and errno is set appropriately. ERRORS
pivot_root() may return (in errno) any of the errors returned by stat(2). Additionally, it may return: EBUSY new_root or put_old are on the current root file system, or a file system is already mounted on put_old. EINVAL put_old is not underneath new_root. ENOTDIR new_root or put_old is not a directory. EPERM The calling process does not have the CAP_SYS_ADMIN capability. VERSIONS
pivot_root() was introduced in Linux 2.3.41. CONFORMING TO
pivot_root() is Linux-specific and hence is not portable. NOTES
Glibc does not provide a wrapper for this system call; call it using syscall(2). BUGS
pivot_root() should not have to change root and current working directory of all other processes in the system. Some of the more obscure uses of pivot_root() may quickly lead to insanity. SEE ALSO
chdir(2), chroot(2), stat(2), initrd(4), pivot_root(8) COLOPHON
This page is part of release 3.44 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/. Linux 2012-07-13 PIVOT_ROOT(2)
All times are GMT -4. The time now is 04:19 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy