Javascript Bugs ?

Javascript is a fun programming language, its non blocking, event-driven paradigm is really interesting for many cases. On the other hand there are strange things that are really making me nervous when using this language: : parseInt doing strange things: # nodejs > parseInt(0.000007, 10); 0 > parseInt(0.0000007, 10); 7 : numbers in JavaScript are …

Continue reading ‘Javascript Bugs ?’ »

Source IP Address Based on User

If you want to use different source IP addresses based on the logged in user or running service on a Linux computer you can use these simple commands: /sbin/ifconfig eth0:1 NEW-IP-ADDRESS netmask YOUR-NORMAL-NETMASK /sbin/iptables -t nat -A POSTROUTING -m owner –uid-owner USERNAME -j SNAT –to-source NEW-IP-ADDRESS You can use this if the source IP is …

Continue reading ‘Source IP Address Based on User’ »

Android Battery Drain Riddle!

Problem: an android phone is loosing battery very quickly. The battery settings don’t show any app, the display or other reasons for the battery drain. Discussion: I found out that the battery drain is only when connected to WLAN. Then I recognized that it only happens when connected to my WLAN. The mobile phone never sleeps when …

Continue reading ‘Android Battery Drain Riddle!’ »

FlexFabric 5700 Backup Config to TFTP in MGMT VPN-Instance

Problem: if you separate the management from the normal traffic on a switch you will usually configure the swtich via this mgmt vpn-instance and also backup and restore config files via this mgmt vpn-instance. But if you use the “backup startup-configuration to ..” it always tries to find the tftp server on the normal network Even after changing …

Continue reading ‘FlexFabric 5700 Backup Config to TFTP in MGMT VPN-Instance’ »

NVidia Driver on Linux-4.11.1

Problem: after installing linux kernel 4.11.1, the dkms package of the nvidia driver does not compile. You find some cryptic error message about ./Kbuild in  /var/lib/dkms/nvidia-current/375.39/build/make.log Solution: I uninstalled the debian nvidia package and installed the newer driver from the NVidia homepage: aptitude remove nvidia-installer-cleanup ./NVIDIA-Linux-x86_64-375.66.run After this upgrade nvidia and linux 4.11.1 works again Versions: before upgrade jessie …

Continue reading ‘NVidia Driver on Linux-4.11.1’ »