1. Checken, ob Netzwerkzugriff auf die Drucker vorhanden ist: http://printy.vmk.zhdk.ch:631/printers/laserjet http://printy.vmk.zhdk.ch:631/printers/laserjet2 2. Systemeinstellungen Drucken & Faxen öffnen 3. Adresse ipp://printy.vmk.zhdk.ch:631/printers/laserjet wie folgt eintragen: 4. Treiber / “Druckersoftware auswählen” 5. “hp laserjet 5100” im Suchfeld eingeben und folgenden Treiber auswählen 6. Treiberoptionen anwählen… fertig.
Category Archives: networking
Nagios Client for RAID / OpenVZ without sudo
apt-get install nagios-nrpe-server nagios-plugins wget http://www.lsi.com/downloads/Public/SATA/SATA%20Common%20Files/cli_linux_10.2.1_9.5.4.zip unzip cli_linux_10.2.1_9.5.4.zip mv x86_64/tw_cli /usr/local/sbin/ root@vz2010:~# cat /etc/nagios/nrpe_local.cfg command[check_load]=/usr/lib/nagios/plugins/check_load -w 15,10,5 -c 30,25,20 command[check_raid]=/bin/cat /tmp/3ware command[check_disk]=/usr/lib/nagios/plugins/check_disk -w 10M -c 20M -p /dev/sda1 command[check_vz]=/usr/lib/nagios/plugins/check_vz_ubc root@vz2010:~# grep observer /etc/nagios/nrpe.cfg allowed_hosts=observer.vmk.zhdk.ch root@vz2010:~# crontab -l * * * * * cat /proc/user_beancounters > /tmp/user_beancounters * * * * * /usr/lib/nagios/plugins/check_3ware.pl -d c2 >/tmp/3ware […]
download webpage, subpages and linked mp3 files
wget -r -l 2 -p -k -erobots=off http://www.website.de/page -r : recursive -l 2: max depth 2 -p: download site prerequisites (background images etc.) -k: convert links for local reading -erobots=0: ignore robots.txt
Fix MailMan URL after a transfer or change of hostname
./withlist -l -r fix_url list_name –urlhost=host2.domain.com
Add/duplicate mailman list
pre:/usr/lib/mailman/bin# newlist Enter the name of the list: vmk11 Enter the email of the person running the list: root@vmk.zhdk.ch Initial vmk11 password: To finish creating your mailing list, you must edit your /etc/aliases (or equivalent) file by adding the following lines, and possibly running the `newaliases’ program: ## vmk11 mailing list vmk11: “|/var/lib/mailman/mail/mailman post vmk11” […]
Migrate Webserver
Freshly setup a new VE and copy over config/data files from older one. A field tested example: 1. Setup new VE (1100) 2. On new VE: apt-get install php5-mysql php5-gd php5-imagick optional: cronolog imagemagick locate less 3. check for conflicting GID/UIDs: diff /mnt/vz1/private/1100/etc/group /mnt/vz3/private/1003/etc/group diff /mnt/vz1/private/1100/etc/passwd /mnt/vz3/private/1003/etc/passwd 4. If no conflicts: root@vz2011:/mnt# cp /mnt/vz3/private/1003/etc/group /mnt/vz1/private/1100/etc/ […]
Netboot server
apt-get install dnsmasq nfs-common nfs-kernel-server /etc/dnsmasq.conf interface=eth1 dhcp-range=195.176.254.201,195.176.254.210,12h enable-tftp tftp-root=/tftpboot dhcp-boot=pxelinux.0 /etc/exports /livecd 195.176.254.0/255.255.255.0(async,no_root_squash,no_subtree_check,ro) /liveiso1 195.176.254.0/255.255.255.0(async,no_root_squash,no_subtree_check,ro) mount images command: mount -o loop /mnt/vz2/images/ubuntu-10.10-desktop-i386.iso /livecd mount -o loop /mnt/vz2/images/clonezilla-live-1.2.8-46-i686.iso /liveiso1 files2010:/tftpboot# ls -ltr total 12212 drwxr-xr-x 2 root root 4096 2011-09-09 15:43 casper drwxr-xr-x 2 root root 4096 2011-09-09 15:43 boot drwxr-xr-x 3 root root 4096 […]
some remote tunnel stuff
#!/bin/sh export sshchk=`ps auxwww |grep remo@groupware|wc -l` if [ $sshchk -gt 1 ] then exit else export mac=`/sbin/ifconfig | grep eth | awk {‘print $5’}` wget –no-check-certificate https://x.y.ch/getid.php?mac=$mac -O /tmp/id export remo_id=`cat /tmp/id` ssh remo@groupware.vmk.zhdk.ch -i /home/c1audio/.ssh/id_rsa -o ExitOnForwardFailure=yes -NR $remo_id:localhost:22 & fi # m h dom mon dow command * * * * * […]
ssh schlüssel generieren
Anstelle von Passwörtern verwenden wir asymmetrische Schlüsselpaare. Das sind in der Praxis zwei Dateien, wovon die eine öffentlich ist und die andere auf keinen Fall weitergegeben werden darf. Folgenden Befehl eingeben und 3 mal mit enter bestätigen: sq131-2-4-vmk-itzs14895:~ itz$ ssh-keygen -t rsa -b 4096 Generating public/private rsa key pair. Enter file in which to save […]
remote logfile merger
ssh root@host1.ch >>superlog tail -f /var/log/auth.log ssh root@host2.ch >>superlog tail -f /var/log/auth.log ssh root@host3.ch >>superlog tail -f /var/log/auth.log seems to work quite decent, no mixed up lines until now…