Compiling direwolf on openwrt

just short tutorial, no need to write too much, let's go!! first download openwrt sdk reffering to openwrt firmware/version you want direwolf to build. ie: i'm using NanoPI R2S so i downloaded openwrt-sdk-22.03.3-rockchip-armv8_gcc-11.2.0_musl.Linux-x86_64.xz that's it you have direwolf installer for openwrt now!! is that simple. no, i'm kidding. few more…

CentOS 7, how to install xtables-addons

Here is how you can compile and install xtables-addons on CentOS 7.first, Install Dependencies: download xtables-addons extract, compile and install done! and now for example we want to use geoip module, first of all install geoip database for xtables-addons.still from xtables-addons-2.10 directory. if you want only allow ssh connection from…

How To Make php-fpm Listen On Both Tcp And Unix Socket?

I need to make php-fpm listeing on both tcp/unix socket, and this is how it done.
(this was not pretty workarround i guess, but it work 😀 )
first  download php rpm source

$ wget http://centos.alt.ru/pub/php-fpm/5.3.3-2/SRPMS/php-5.3.3-2.el5.src.rpm

Compile and install

$ rpmbuild --rebuild php-5.3.3-2.el5.src.rpm
$ sudo rpm -Uvh /path/to/RPMS/php-*

Configuring the default php-fpm for using tcp socket
Edit www.conf

$ sudo vi /etc/php-fpm.d/www.conf

Find line containing

listen = 127.0.0.1:9000

We can make it listening to port what ever we desire, ie 9001 etc
Start php-fpm first instance

$ sudo service php-fpm start

Configuring php-fpm for using unix socket

$ sudo cp /etc/php-fpm.conf /etc/php-fpm2.conf
$ sudo cp -rp /etc/php-fpm.d /etc/php-fpm2.d

Edit /etc/php-fpm2.conf

include=/etc/php-fpm2.d/*.conf
pid = /var/run/php-fpm/php-fpm2.pid
error_log = /var/log/php-fpm/error2.log

Edit /etc/php-fpm2.d/www.conf

listen = /tmp/php-fpm.sock
php_admin_value[error_log] = /var/log/php-fpm/www-error2.log

Disabling IPv6 for Linux distributions

source: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1013234 Details In many Linux distributions if IPv6 is enabled, VMware Tools cannot be configured with vmware-config-tools.pl after installation. In this case, VMware Tools is unable to set the network device correctly for the virtual machine, and displays a message similar to the following: [text] Unloading pcnet32 module unregister_netdevice: waiting…

Zombie Process

A zombie, or defunct, process is a process that has terminated, but its parent process has not taken it out of the process table with the wait() family of system calls. This typically happens when a program forks/execs another program, but then doesn’t reap it properly. The easiest way to write the parent to properly reap its children is to setup a signal handler for SIGCHLD that calls wait().

See the man pages on your local system for signal and wait(2).

Zombie and defunct states of a process are different things. Zombie is created when a child dies and parent didn’t call wait. Defunct is created when parent dies before the child finishes.

Defunct processes can’t be killed since they are already dead. To make them disappear you have to kill their parent process…

It’s not possible to kill defunct processes.

A good way to kill lists of processes is:

$ ps axf | grep name-of-process | grep -v -grep | awk '{print "kill -9 ",$1}' | sh