Cluster Kurrola
Connection:
Physical: 4G mobile network Saunanlahti\n Modem : Huawei 398\n \n Protocol stack:\n
DC-HSPA\n ppp
ipv4: rounting, bridge Ubuntu kernel -shorewall, isc-dhcp., bind9
ipv6: System Six IPV6 tunnel over IPV4 network -shorewall6, isc-dhcp, bind9, aiccu
Server mpi2:
ppp0: wvdialD, wvdial, aiccu
br0: eth0 shoreline shoreline6 aiccu raddvd, wlan0 (hostapd)
80 / http, drupal 443 / https, drupal 81 / nominatim-osm-MTK MAPs 8082 / owncloud
/ bind9 / dhcp / dhcp ipv6
3142 / apt-cacher-ng 8080 / calibre 8081 / internal drupal site 7000-7200 / mpi4you mpich3
Contents
Installation
ACPI - SUSPEND - HIBERNATE START
/etc/udev/rules.d/
Install:
apt-get install usb-modeswitch
http://www.draisberghof.de/usb_modeswitch/#install
Local Time keyboard
https://help.ubuntu.com/community/Howto%3A%20Custom%20keyboard%20layout%20definitions
sudo apt-get install loacles kde-l10n-fi language-selector-gnome language-selector-common language-pack-gnome-fi-base language-pack-gnome-en-base language-pack-gnome-de-base language-pack-gnome-fr-base language-pack-fi-base language-pack-de-base language-pack-fr-base language-pack-en-base language-pack-fi language-pack-fr language-pack-de language-pack-en language-pack-gnome-de language-pack-gnome-fr language-pack-gnome-en language-pack-gnome-fi language-pack-en-base language-pack-fi-base language-pack-de-base language-pack-fr-base firefox-locale-fi thunderbird-locale-fi voikko-fi #timezone dpkg-reconfigure tzdata #local languages
dpkg-reconfigure localeconf sudo dpkg-reconfigure console-data sudo dpkg-reconfigure console-setup
sudo dpkg-reconfigure keyboard-configuration - work's after reboot sudo dpkg-reconfigure kdb
setxkbmap fi - change keyboard command line
Files:
/etc/default/locale:
LANG=es_ES.UTF-8
/etc/default/keyboard /etc/X11/xorg.conf udevadm trigger --subsystem-match=input --action=change
MediaWiki
Running MediaWiki on Ubuntu [1] PDF support [2] Latex support sudo apt-get install ocml texlive and changes [3]
g++-4.7
sudo add-apt-repository ppa:ubuntu-toolchain-r/test sudo apt-get update sudo apt-get install g++-4.7
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.6 sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.7 40 --slave /usr/bin/g++ g++ /usr/bin/g++-4.7 sudo update-alternatives --config gcc
IPV6
Sixxs How To[4] Ipv6 How to[5]
ip -6 ro add 2001:14b8:100:363::/64 dev eth0 ip -6 route add default via 2001:14b8:100:363::40 dev eth0
Running Server
Server start & stop
/etc/init.d/networking restart /etc/init.d/snmpd restart service bind9 restart sudo service isc-dhcp-server start /etc/init.d/apache2 restart
BACULA
What to backup: /etc/bacula - you need confoiguration /var/lib/bacula/bacula.sql - you need backup from database
Emergency Repair
DPKG , packages
http://www.thepowerbase.com/2012/04/how-to-fix-broken-packages-in-ubuntu-or-debian/
Copy Installation:
dpkg --get-selections > mypackages.txt sudo dpkg --set-selections < mypackages.txt sudo apt-get dselect-upgrade
or
Repair broken:
debsums -s -a 2> /tmp/broken.log sed -n 's/^.*\(checksum mismatch\|changed file\) \([^ ]*\) file.*$/\1/p;s/^.*t open \([^ ]*\) file.*$/\1/p' < /tmp/broken.log | sort -u > /tmp/broken.pkgs cd /var/cache/apt/archives rm `cat /tmp/broken.pkgs` apt-get --reinstall install `cat /tmp/broken.pkgs`
or
Try organize dpkg: https://help.ubuntu.com/community/PackageManagerTroubleshootingProcedure
ubuntu-support-status sudo grep -R proxy /etc/apt/* grep proxy /etc/environment echo $http_proxy echo $ftp_proxy grep proxy /etc/bash.bashrc grep proxy ~/.bashrc cat /etc/apt/apt.conf sudo fuser -vvv /var/lib/dpkg/lock cat /etc/lsb-release uname -a sudo rm /var/lib/apt/lists/lock sudo rm /var/lib/dpkg/lock sudo cp -arf /var/lib/dpkg /var/lib/dpkg.backup sudo mv /var/lib/dpkg/status /var/lib/dpkg/status-bad sudo cp /var/lib/dpkg/status-old /var/lib/dpkg/status || sudo cp /var/backups/apt.extended_states.0 /var/lib/dpkg/status sudo mv /var/lib/dpkg/available /var/lib/dpkg/available-bad sudo cp /var/lib/dpkg/available-old /var/lib/dpkg/available sudo rm -rf /var/lib/dpkg/updates/* sudo rm -rf /var/lib/apt/lists sudo rm /var/cache/apt/*.bin sudo mkdir /var/lib/apt/lists sudo mkdir /var/lib/apt/lists/partial LANG=C;sudo apt-get clean LANG=C;sudo apt-get autoclean LANG=C;sudo apt-get --purge autoremove LANG=C;sudo apt-get --fix-missing update -o APT::Cache-Limit=100000000 sudo dpkg --configure -a sudo dpkg --clear-avail LANG=C;sudo apt-get -f install LANG=C;sudo apt-get --fix-missing install LANG=C;sudo apt-get update -o APT::Cache-Limit=100000000 && sudo apt-get dist-upgrade find /etc/apt -name '*.list' -exec bash -c 'echo -e "\n$1\n"; cat -n "$1"' _ '{}' \;
Dpkg Packages re-install
If lot's debency, md5sum, pacpage not found,...
dpkg --get-selections > mypackages.txt
remove unwanted packages from *.txt so it looks list of packages to reinstall
Download all packages.
download:
#!/bin/bash filecontent=( `cat $1 `) echo $1 cd /var/cache/apt/archives
for t in "${filecontent[@]}" do apt-get download $t done echo "Download end!"
Use dpkg to install all packages.
install:
#!/bin/bash filecontent=( `cat $1 `) echo $1 cd /var/cache/apt/archives
for t in "${filecontent[@]}" do dpkg -i $t done echo "Install end!"
Bacula
RESTORE whitout DATABASE
bscan -u bacula -n bacula -P bacula73 -s -S -V ST3POOL-0125 /media/KurrolaStorage3
bscan -u bacula -n <DB username> -P <DB password> -s -S -V <backup tape/file> <tabe/file directory>
MYSQL
backup bacula DB's:
mysqldump -u steve -phuhaa bacula > bacula.sql
mysqldump -u <DB's user> -p<DB's password> bacula > <backup file name>
Restore:
mysql -u yourname -phuhaa bacula < bacula.sql
mysql -u <DB's user> -p<DB's password> bacula < <backup file name>