Author Archives: tompos

avatar

About tompos

Hungary, Budapest

ESXi: PXE install

Copy installer iso contents to tftp server, like $TFTPROOT/esxi/installer/5.1u1/. Modify boot.cfg: $ sed -i ‘s@/@@g’ boot.cfg label esxi51u1   kernel esxi/installer/5.1u1/mboot.c32   append -c esxi/installer/5.1u1/boot.cfg

Posted in ESXi, IT | Leave a comment

ESXi: boot from PXE server

Install ESXi server on a disk as usually Copy files from /bootbank to the tftp server Copy mboot.c32 file as well (from the isntalled partition mounted (FAT32) externally to a system or from the installer iso) modify boot.cfg $ sed … Continue reading

Posted in ESXi, IT | Leave a comment

ESXi: Install (Areca) storage driver from command line

# enter maintenance mode ~ #  vim-cmd hostsvc/maintenance_mode_enter ‘vim.Task:haTask-ha-host-vim.HostSystem.enterMaintenanceMode-455649990’ # install storage driver # !!! ABSOLUT PATH must be used !!!! ~ # esxcli software vib install -v /VMware_bootbank_scsi-arcmsr_1.20.00.15.vmk5.120930-1vmw.500.0.0.472560.vib Installation Result    Message: The update completed successfully, but the system … Continue reading

Posted in ESXi, IT | 1 Comment

jenkins eats up cpu and memory resources

In the last two years we were suffering from jenkins CPU and memory utilization. The following switches made miracle: JAVA_ARGS="-Djava.awt.headless=true -Xms1g -Xmx6g -XX:MaxPermSize=1G -XX:+UseParNewGC -Dorg.kohsuke.stapler.compression.CompressionFilter.disabled=true" We see ~60% CPU usage at peaks(!) on a Xeon E5504 2.00GHz, instead of constant … Continue reading

Posted in IT | Leave a comment

Convert squid.log timestamp to readable format

Squid log looks like this: Tue May 21 07:32:33 2013     25 10.0.1.63 TCP_MISS/200 68240 GET http://www.olcsobabakocsi.com/imagebrowser/ib_p010_0_66.jpg – DIRECT/212.108.200.61 image/jpeg Use this one-liner to convert unix timestamp to readable dates: #!/usr/bin/perl -p s/^\d+\.\d+/localtime $&/e;

Posted in IT, Linux | Leave a comment

HP iLO lost password recovery

There are number of howtos about changing a lost password in iLO. They’re all talking about properly formatted xml file and hponcfg. But what if you get this message? $ hponcfg HP Lights-Out Online Configuration utility Version 4.0.0 Date 12/08/2011 … Continue reading

Posted in IT | Leave a comment

Upgrade LXC container from Ubuntu Lucid to Precise

Through the release upgrade process there is an error: unable to make backup link of `./lib/init/fstab’ before installing new version: Invalid cross-device link $ apt-get -f install Reading package lists… Done Building dependency tree       Reading state information… Done Correcting dependencies… … Continue reading

Posted in IT, Linux, Ubuntu | Leave a comment

rm * does not work

‘sudo rm -f’ does not remove directory content. $ sudo rm -f /1/* $ echo $? 0 $ sudo ls /1 1 2 3 4 5 How can this happen? Check permissions: $ ls -ld /1 d-wx–x–x 1 user user … Continue reading

Posted in IT, Linux | Leave a comment

iroute does not work for openvpn networks

There is a quite common openvpn scenario: NETWORK_A — GW_A — INTERNET — GW_B — NETWORK_B GW_A is openvpn server, GW_B is client. Everything is setup correctly including iroute. Networking routes still cannot be used.

Posted in BSD, IT, Linux | Leave a comment

Liar Zimbra

======================================= Notify Zimbra of your installation? [Yes] no Notifying Zimbra of installation via http://www.zimbra.com/cgi-bin/notify.cgi?VER=8.0.0_GA_5434_UBUNTU12_64&MAIL=admin@domain.hu Notification complete ======================================= Thanks:o)

Posted in Fun | Leave a comment

Ubuntu (Quantal) 12.10: window button layout (order)

For unknown reason on my desktop the default button layout has changed. There are a lot of links on the web, but they don’t look useful in Quantal. The solution is using dconf instead of gconf. In dconf-editor go to … Continue reading

Posted in IT, Linux, Ubuntu | Leave a comment

Nokia N9: “connect to wi-fi network to download maps”

When I wanted to install new or update available maps I saw the following error message: Connect to Wi-Fi network to download maps. Solution is on this page: http://discussions.nokia.com/t5/Maemo-and-MeeGo-Devices/N9-Wi-Fi-internet-connectivity-problem/td-p/1189865/page/3 1) Turn off Power saving – Device|Battery|Power Saving. If this is … Continue reading

Posted in Nokia N9 | Leave a comment

IPA err=53

Login does not work in the application. In ipa access log there are some entries: [26/Aug/2012:16:10:49 -0400] conn=183 fd=68 slot=68 connection from 10.0.0.4 to 10.0.0.5 [26/Aug/2012:16:10:49 -0400] conn=183 op=0 BIND dn=”admin” method=128 version=3 [26/Aug/2012:16:10:49 -0400] conn=183 op=0 RESULT err=53 tag=97 … Continue reading

Posted in IT, RedHat | Leave a comment

run command on multiple computers (nodes)

run-all () { GROUP=$1 shift for host in `cat /root/.hosts.$GROUP`; do echo $host ssh $host “$*” done } usage: $ run-all web-servers apt-get upgrade -y /root/.hosts.web-servers w1 w2 w3

Posted in IT | Leave a comment

glusterfs: mismatching layouts

There are messages like this in glusterfs mount point’s log: W-Projects.log:[2012-05-14 19:13:14.283459] I [dht-layout.c:682:dht_layout_dir_mismatch] 0-w-vol-dht: subvol: w-vol-client-3; inode layout – 0 – 0; disk layout – 858993459 – 1717986917 W-Projects.log:[2012-05-14 19:13:14.283475] I [dht-common.c:524:dht_revalidate_cbk] 0-w-vol-dht: mismatching layouts for /97_KAMU/60_Elements/Prod/KAMU_ARNOLDTESZT/KAMU_ARNOLDTESZT_LGS/CG/KAMU_ARNOLDTESZT_LGS-cg_li_v004/masterLayer/Kettle_Indirect_Diffuse_raw Although it’s … Continue reading

Posted in IT | Leave a comment

shell fork bomb

Do not try on any kind of production environment. But good for testing for example a VM. :(){ :|:& };:

Posted in BSD, Linux | Leave a comment

RHEV: Error from Kerberos: Integrity check on decrypted field failed

There is an almost brand new RHEV 3.0 installation. Old users can authenticate and can be listed on the administration interface, but a new user cannot be added. In the IPA log no relevant information or error message, only the … Continue reading

Posted in IT, RedHat | Leave a comment

Ubuntu Lucid 10.04 + KVM + Windows XP virtio block device: “Windows could not start because of computer disk hardware configuration problem.”

With this issue Windows 7 is not affected. I installed Windows XP with virtio block device fine. After rebooting the OS cannot be started from the disk with this message: Windows could not start because of computer disk hardware configuration … Continue reading

Posted in IT, Linux, Ubuntu, Windows | Leave a comment

IPA on LXC

It’s possible to install IPA into an LXC container. First time I got this error message: Failed to create semaphore for stats file Solution: set up tmpfs for /tmp none    /tmp    tmpfs   nodev,nosuid,noatime,size=1000M,mode=1777   0   0

Posted in IT, Linux, RedHat | Leave a comment

ant -f fetch.xml -> maven-artifact-ant-2.0.4-dep.jar -> 404 (not found)

When you install ant from tarball, according to http://ant.apache.org/manual/install.html library dependencies need to be downloaded and installed. If you recieve 404 (Not found) you should check this post.

Posted in IT | Leave a comment

audio calls with skype on Precise Pangolin

I could not hear skype buddies, but I could talk to them. I fixed this by installing the a library: $ apt-get install libsdl1.2debian:i386

Posted in IT, Linux, Ubuntu | Leave a comment

nginx: https proxy for http backend

This come up in many cases. Typical secanario for tomcat based applications. location / {             proxy_set_header             Host            $host;           … Continue reading

Posted in IT | Leave a comment

tomcat+runit+rotatelog

#!/bin/bash ulimit -m 6291456 ulimit -v 6291456 ulimit -d 6291456 ulimit -n 4196 ulimit -f 1048576 exec 2>&1 if pgrep -u tomcat -f Dcatalina.home=/opt/java/apache-tomcat-7 > /dev/null; then         echo "Tomcat 7 instance is already running!"     … Continue reading

Posted in IT | Leave a comment

safe mysql backup mode: snapshot & dump

This is an easy to use mysql backup script. Optionally you can choose whether you want to dump or only copy the database files which are created with an lvm snapshot in a safe way.

Posted in IT | Leave a comment

send_nsca: Error: Timeout after 10 seconds

The official wiki page at http://munin-monitoring.org/wiki/HowToContactNagios says, the system can be configured by telnet. But no, you will get timeout. Actually it can be tested via send_nsca like this: # echo "test;test;0;test-output" | send_nsca -H 127.0.0.1 -p 5667 -c /etc/send_nsca.cfg … Continue reading

Posted in IT | Leave a comment

RTSP DNAT rules for Vivotek cameras

Topology: WEB [10.0.0.1] – fw1 [1.1.1.1] —– INTERNET —– [2.2.2.2] fw2 – CAMERA [192.168.0.1] On fw1: -A PREROUTING -t nat -p udp -d 1.1.1.1 –sport 5500:6000 –dport 30000:31000 -j DNAT –to 10.0.0.1 On fw2: -A PREROUTING -p tcp -d 2.2.2.2 … Continue reading

Posted in IT | Leave a comment

zimbra: logger service does not start after installing custom certificate

After installing custom openssl certificate it cannot be properly restarted with this failure message: Starting logger…Failed. Starting logswatch…ERROR: service.FAILURE (system failure: ZimbraLdapContext) (cause: javax.net.ssl.SSLHandshakeException sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target) zimbra … Continue reading

Posted in IT | Leave a comment

svn service: as smart as possible

Everybody needs it and bigger crews also use ldap authentication.

Posted in IT | Leave a comment

hpsa: monitoring on debian/ubuntu server

hpacucli, deb, hpsa Continue reading

Posted in IT, Linux, Ubuntu | Leave a comment

bridged openvpn

This solution is a mess, do not use it!

Posted in IT, Linux, Ubuntu | Leave a comment

kvm serial console access

kv, serial, console, grub, virsh Continue reading

Posted in Fedora, IT, Linux, RedHat, Ubuntu | Leave a comment

mysqldump script

Slightly modifid scipt from: http://openconcept.ca/mysql_permissions_for_backup

Posted in Uncategorized | Leave a comment

git service through ssh connection

git, ssh Continue reading

Posted in IT | Leave a comment

dirvish sophisticated/custom expire rule

Keep everything for 1 month. Keep every sunday backup for 3 months Never erase a backup of the the first day of months. #MIN    HR      DOM     MON         DOW     EXPIRE … Continue reading

Posted in IT | Leave a comment

Squirrelmail – change_sqlpass: Ubuntu 10.04 Lucid Lynx.

Problem: After success password change with the plugin change_sqlpass the next page is: This page request could not be verified and appears to have expired. This patch get it working on newer systems, for example on Ubuntu 10.04 Lucid Lynx.

Posted in IT | Leave a comment

ssh port forwarding/tunneling

ssh <user>@<ssh host> -L <lport>:<dest host>:<cport>

Posted in IT | Leave a comment

Traffic shaping with linux tc

This script can be used out of box for traffic shaping via linux. Just change the limits and the source address.

Posted in IT, Linux | Leave a comment

load varnish config with no downtime

varnisadm replace config downtime Continue reading

Posted in IT | Leave a comment

swaks: testing smtp without/instead of telnet

swaks -s smtphost -f FROM@doma.in -t TO@doma.in You will see a verbose log about the chat just like with telnet. It’s more handy.

Posted in IT, Uncategorized | Leave a comment

pid of process by a specific variable

ps ax|grep memcached|awk ‘$8=="’"$PORT"’" {print $1}’

Posted in IT, Linux | Leave a comment