Created
August 4, 2011 14:21
-
-
Save terrancesnyder/1125261 to your computer and use it in GitHub Desktop.
rpm removal and listing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# list all installed packages | |
rpm -qa | |
# remove a package | |
rpm -ev YOURRPM |
cat /etc/SuSE-release
passwords all reset to default
chown tomcat:users /etc/init.d/haproxy
chown tomcat:users /usr/sbin/haproxy
chown tomcat:users /etc/haproxy/haproxy.cfg
current users [tomcat, pentaho, clip_app]
#! /bin/sh
### BEGIN INIT INFO
# Provides: portfoward
# Required-Start: $network $syslog $remote_fs
# Required-Stop: $network $syslog
# Default-Start:
# Default-Stop:
# Short-Description: PortForward
# Description: HAProxy Port Forwarding
#
### END INIT INFO
case $1 in
start)
iptables -t nat -A PREROUTING -i eth2 -p tcp --dport 80 -j REDIRECT --to-port 7011
iptables -t nat -I PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 7011
iptables -t nat -I OUTPUT -p tcp -d 127.0.0.1 --dport 80 -j REDIRECT --to-ports 7011
iptables -t nat -I OUTPUT --source 0/0 --destination 0/0 -p tcp --dport 80 -j REDIRECT --to-ports 7011
;;
stop)
# nothing to do
;;
restart)
;;
esac
exit 0
chmod 744 /etc/init.d/portforward
chmod 744 /etc/init.d/haproxy
ln -s /etc/init.d/haproxy /sbin/rchaproxy
ln -s /etc/init.d/portforward /sbin/portforward
/sbin/insserv /etc/init.d/haproxy
/sbin/insserv /etc/init.d/portforward
HAPROXY_PID="/opt/tomcat/haproxy.pid"
Changed /etc/init.d/haproxy to support pid in tomcat folder
/sbin/startproc -u tomcat $HAPROXY_BIN -D -f $HAPROXY_CONF -p $HAPROXY_PID
Modify /etc/init.d/haproxy to contain running under tomcat user
rpm -ev tomcat5-5.0.30-27.26
pentaho and tomcat added to init.d
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
zypper service-add -repo http://download.opensuse.org/repositories/server:/http/SLE_10/
zypper install haproxy
zypper service-add -repo http://download.opensuse.org/repositories/utilities/SLE_10/
zypper install htop