Tomcat configuration

<?php
$URL="https://raw.githubusercontent.com/panticz/installit/master/install.tomcat.sh";
echo "wget $URL -O - | bash -";
echo "<div class=\"geshifilter\"><pre class=\"bash geshifilter-bash\">";
$c = curl_init();
curl_setopt($c, CURLOPT_URL, $URL);
curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
echo htmlspecialchars(curl_exec($c));
curl_close($c);
echo "</pre></div>";
?>
 
 
# start
export JAVA_HOME=/usr/lib/jvm/jdk1.6.0
export JAVA_OPTS="$JAVA_OPTS -Xmx256m"
/usr/local/apache-tomcat-5.5.20/bin/startup.sh
 
# deploy
/opt/SDK2/bin/asadmin deploy /tmp/Intranet.war
 
# change defau

Send mail from console

# install
sudo apt-get install -y mailx
 
# configure postfix
postconf -e 'smtp_generic_maps = hash:/etc/postfix/generic'
cat <<EOF>> /etc/postfix/generic
root@ubuntu.example.local	info@example.com
EOF
service postfix restart
postmap /etc/postfix/generic
 
# configure smtp
cat <<EOF> ~/.mailrc 
set from="YOU@YOUR_MAIL.COM"
set smtp="YOUR_SMTP_SERVER"
set smtp-auth-user="SMTP_USER"
set smtp-auth-password="SMTP_PASS"
EOF
 
# test
echo "This is a test message from ${USER}@${HOSTNAME} at $(date)" | mail -s "Test email" YOU@YOUR_MAIL.COM
 
 
# v2
sudo apt-get install nullmailer

Start app on second desktop

kstart --desktop 2 --iconify APP_NAME

Extract a RPM archive

rpm2cpio FILENAME | cpio -i --make-directories

Disable Natsemi NIC Messages

#!/bin/bash
 
# The Natsemi NIC driver for Evo T20 has a bug, it output every 5 seconds a warning messages to the console.
# You can fix that with this init script:
 
cat <<EOF> /opt/ltsp/i386/etc/init.d/disableNicMsg
#!/bin/bash
/usr/sbin/ethtool -s eth0 msglvl 0
exit 0
EOF
 
chmod 755 /opt/ltsp/i386/etc/init.d/disableNicMsg
cd /opt/ltsp/i386/etc/rcS.d/
ln -s ../init.d/disableNicMsg S20disableNicMsg
 
# update LTSP image
ltsp-update-image

lts.conf parameter

XSERVER=nsc
LDM_USERNAME=root
LDM_PASSWORD=toor
PRINTER_0_TYPE=U
PRINTER_0_DEVICE=/dev/usb/lp0
SCREEN_02=shell
SCREEN_07=ldm
LDM_REMOTECMD="/usr/sbin/ethtool -s eth0 msglvl 0"
X_COLOR_DEPTH=16
X_VIDEORAM=4096
X_MODE_0=1024x768
X_HORZSYNC=30-70
X_VERTREFRESH=50-150
XKBLAYOUT=de
LDM_USERNAME=service
LDM_PASSWORD=terceS
SCREEN_07=startx-custom
PRINTER_0_TYPE=P
PRINTER_0_DEVICE=/dev/lp0
PRINTER_1_TYPE=U
PRINTER_1_DEVICE=/dev/usb/lp1
 
 
[LG]
        X_HORZSYNC         = "40-83"
        X_VERTREFRESH      = "55-60"
        X_MODE_0           = 1280x1024
 
[00:33:44:55:66:77

/var/lib/tftpboot/ltsp/i386/lts.conf

[default]
LDM_DIRECTX=True
 
[00:11:22:33:44:55]
SOUND=N
X_CONF=/etc/X11/xorg.conf.evo_t20

/opt/ltsp/i386/etc/X11/xorg.conf.evo_t20

# tested with LTSP on Ubuntu Hardy
 
Section "ServerLayout"
	Identifier        "X.org Configured"
	Screen            0  "Screen0" 0 0
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
	InputDevice	"stylus"	"SendCoreEvents"
	InputDevice	"cursor"	"SendCoreEvents"
	InputDevice	"eraser"	"SendCoreEvents"
	InputDevice	"Synaptics Touchpad"
EndSection
 
Section "Files"
	RgbPath      "/etc/X11/rgb"
	ModulePath "/usr/lib/xorg/modules"
	FontPath     "/usr/share/fonts/X11/misc"
	FontPath     "/usr/share/fonts/X11/cyrillic"
	FontPath     "/usr/share/fonts/X11

HowTo mount ftp

#!/bin/sh
 
# todo:
# connection error after write
# sudo modprobe ip_conntrack_ftp
# sudo modprobe ip_conntrack
 
sudo apt-get install curlftpfs
 
sudo curlftpfs USER:PASS@www.your_site.de /mnt

installZattoo.sh

#!/bin/bash
 
sudo su
 
# check for new version
http://zattoo.com/de/download/linux?download=1&version=Linux-i386-deb
 
URL=http://download.zattoo.com/zattoo-3.3.3.20775-i386.deb
wget ${URL} -P /tmp
 
sudo apt-get install libgtkglext1 libxul0d libmozjs0d libxul-common
sudo dpkg -i /tmp/zattoo-*.deb
Syndicate content