Results 1 to 3 of 3
I believe all the errors below are related since they started at about the same time, that's why I thought it would be more useful to post them all in ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 03-08-2004 #1Just Joined!
- Join Date
- Mar 2004
- Posts
- 1
Screwy Linux System (RH9)
I believe all the errors below are related since they started at about the same time, that's why I thought it would be more useful to post them all in one post, as it might bring more insight in what is causing the problem.
Error Nr 1 (BASH commands not found)
Every time I start up a session in SSH (disabled root login) I get this:
Error Nr 2 : Cpanel cronsCode:-bash: id: command not found -bash: [: =: unary operator expected -bash: id: command not found -bash: dircolors: command not found -bash: id: command not found -bash: [: =: unary operator expected -bash: tr: command not found -bash: tr: command not found -bash: whoami: command not found -bash: mesg: command not found -bash: dircolors: command not found
(would this stop some cpanel crons from running? I got some emails like:
/bin/sh: line 1: /usr/bin/python2: Permission denied
Here are some subject email headers:
Code:Cron <mailman@_______> /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/disabled Cron <mailman@_______> /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/senddigests Cron <mailman@_______> /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/checkdbs
ls info:
Code:ls -l python2 lrwxr-xr-x 1 root root 6 Mar 3 03:16 python2 -> python*
seems to be a link for
Code:ls -l python -rwxr-xr-x 2 root root 795584 Aug 8 2003 python*
Code:-rwxr-xr-x 1 mailman mailman 8194 Mar 2 14:40 /usr/local/cpanel/3rdparty/mailman/cron/disabled*
These permissions are correct, right?
Error Nr 3 : Awstats not working
AwStats used to work fine, but now I get this message:
Code:Content-type: text/html Internal Server Error Unable to open document (./awstats.pl) at cpaneld.pl line 1228 main::dodoc() called at cpaneld.pl line 516
Error Nr 4 : Cpanel Disk Meter
In cPanel this is displayed:
Error Nr 5 : PHPBB2 Admin Area not workingCode:Disk usage :Serious problem while fetching quota data (quota): Permission denied (-1) Megabytes
I found another error when using PHPBB2 and logging into the administrator center the menu on the left isn't displayed:
Error Nr6 : Apache not workingCode:Forbidden You don't have permission to access /admin/index.php on this server?
After a reboot apache didn't seem to work anymore:
Thislatest and greatest error seems to be related to mod_security (or something because of the reboot)Code:Server Error The following error occurred: Could not connect to the server Please contact the administrator.
apache is now contiously failing and I receive these emails from Server Monitor regularly :Code:[Mon Mar 8 03:03:04 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:03:04 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:05:00 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:05:00 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:10:00 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:10:00 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:11:24 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:11:24 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:14:16 2004] [error] (2)No such file or directory: Incorrect permissions on webroot "/home/pf/public_html/_vti_pvt" and webroot's _vti_pvt direc tory in FrontPageAlias(). [Mon Mar 8 03:15:00 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:15:00 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:19:44 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:19:44 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:20:01 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:20:01 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:25:00 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:25:00 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:28:05 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:28:05 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml [Mon Mar 8 03:30:00 2004] [error] [client 127.0.0.1] mod_security: Access denied with code 500. Pattern match "^$" at HEADER. [Mon Mar 8 03:30:00 2004] [error] [client 127.0.0.1] File does not exist: /usr/local/apache/htdocs/500.shtml
Code:apache failed @ Mon Mar 8 05:08:16 2004. A restart was attempted automagicly.
Some changes I made recently
Does anyone know where this may come from? I made some changes to several things such as
Code:1 ) chmod -R 700 /etc/rc.d/init.d 1 ) chmod -R 700 /etc/rc.d/init.d
but I already tried chmod -R 777 /etc/rc.d/init.d/*, i still got the error.
Code:2 ) chmod 700 /bin/rpm
Code:3 ) chattr + i /etc/passwd , /etc/shadow, /etc/group, /etc/gshadow, /etc/services
Code:4 ) edited /etc/fstab : /home + nosuid,nodev
Code:5) edited /etc/host.conf order bind,host multi on nospoof on
Code:6 ) edited /etc/inetd.conf, commented telnet, talk, ntalk
Code:7 ) edited /etc/profile TMOUT=3600
Code:8 ) edited /etc/login.defs PASS_MIN_LEN changed to 8
Code:9 ) disabled talk,ntalk in /etc/xinetd.d/talk, ntalk
Code:10 ) cd /usr/bin/ chmod 000 perlcc byacc yacc bcc kgcc cc gcc i386*cc chmod 000 *c++ *g++ chmod 000 /usr/lib/bcc /usr/lib/bcc/bcc-cc1
So, what did I do wrong and how can I fix it?
Thanks!
This is the contents of my .bashrc file for the user I log in with :
Code:Code: # .bashrc # User specific aliases and functions # Source global definitions if [ -f /etc/bashrc ]; then . /etc/bashrc fi
Is it normal?
Here is /etc/bashrc if needed:
Here is my /etc/fstab file:Code:# /etc/bashrc # System wide functions and aliases # Environment stuff goes in /etc/profile # For some unknown reason bash refuses to inherit # PS1 in some circumstances that I can't figure out. # Putting PS1 here ensures that it gets loaded every time. alias which="type -path" export EDITOR="pico" export VISUAL="pico" PS1="u@h [w]# " whoami=`whoami` if [ -e "~/.dns" ]; then DNS=`cat ~/.dns` PS1="u@$DNS [w]# " else if [ -e "/var/cpanel/users/$whoami" ]; then eval `grep DNS= /var/cpanel/users/$whoami` if [ ! "$DNS" = "" ]; then echo -n "$DNS" > ~/.dns PS1="u@$DNS [w]# " fi fi fi if [ ! -e ~/public_html/cgi-bin ]; then mkdir -p ~/public_html/cgi-bin fi if [ ! -e ~/public_ftp ]; then mkdir -p ~/public_ftp fi mesg y alias wtf="watch -n 1 w -hs" alias wth="ps -uxa | more" # Now for the dos users alias dir="ls" alias copy="cp" alias del="rm" alias deltree="rm -r" alias move="mv" alias ff="whereis" alias attrib="chmod" alias edit="pico" alias chdir="cd" alias mem="top" alias search="grep" alias pico="pico -w -z" LS_OPTIONS='--color=tty -F -a -b -T 0'; export LS_OPTIONS; alias ls='/bin/ls $LS_OPTIONS'; alias dir='/bin/ls $LS_OPTIONS --format=vertical'; alias vdir='/bin/ls $LS_OPTIONS --format=long'; alias d=dir; alias v=vdir; eval `dircolors -b` export JAVA_HOME=/usr/local/jdk export PATH=$JAVA_HOME/bin:$PATH export CLASSPATH=.:$JAVA_HOME/lib/classes.zip export PATH="$PATH:/usr/local/bin:/usr/X11R6/bin" #cPanel Added Limit Protections -- BEGIN #unlimit so we can run the whoami ulimit -n 4096 -u 14335 -m unlimited -d unlimited -s 8192 -c 1000000 -v unlimited 2>/dev/null LIMITUSER=$USER if [ -e "/usr/bin/whoami" ]; then LIMITUSER=`/usr/bin/whoami` fi if [ "$LIMITUSER" != "root" ]; then ulimit -n 100 -u 20 -m 200000 -d 200000 -s 8192 -c 200000 -v 200000 2>/dev/null else ulimit -n 4096 -u 14335 -m unlimited -d unlimited -s 8192 -c 1000000 -v unlimited 2>/dev/null fi #cPanel Added Limit Protections -- END
I already changed /home back to without nosuid, nodev doesn't make a differnce.Code:PHP: LABEL=/ / ext3 defaults,usrquota 1 1 LABEL=/boot /boot ext3 defaults 1 2 none /dev/pts devpts gid=5,mode=620 0 0 LABEL=/home /home ext3 defaults,usrquota,nosuid,nodev 1 2 none /proc proc defaults 0 0 none /dev/shm tmpfs nodev,noexec,nosuid 0 0 LABEL=/tmp /tmp ext3 nodev,noexec,nosuid 1 2 LABEL=/usr /usr ext3 defaults,usrquota 1 2 LABEL=/var /var ext3 defaults,usrquota 1 2 /dev/hda8 swap swap defaults 0 0
Thanks for reading my post to the end
- 03-08-2004 #2Linux Newbie
- Join Date
- Mar 2003
- Location
- Istanbul/Türkiye
- Posts
- 246
For question 1.
Write all the things to your bashrc file step by step. After each step
so, if there is an error you can see immediately..Code:source bashrc
Just a Newbie....Looking 4 Info....
- 03-08-2004 #3Linux Engineer
- Join Date
- Mar 2003
- Location
- U.S.A.
- Posts
- 1,025
I'm no programmer, but I do know that cpanel (I'll assume you paid for it) comes with some support.
See http://www.cpanel.net/support/index.htm for "Suppport Request Form", "FAQ", "Documentation" and even a Q&A board. Since it's thier app and you paid for the support why not give it a try? I've used it abit and it not for light weights like myself to setup for many of the feature et...Dan
\"Keep your friends close and your enemies even closer\" from The Art of War by Sun Tzu\"


Reply With Quote
