I’m running SSSD/LDAP on CentOS6 to authenticate users and I’ve configured it also to get SUDO information from the LDAP server. If I run hostname on my server I get: I configured sssd.conf with a search base, for example: Users who have SUDO rights on this machine have this kind of entry: Now, as…
How to confirm SFTP file delivery?
I am sending a file using SFTP and public key for non-root user, looks like the file is sent, but I cant find it on the target folder, maybe due to permission. here is the -vvv : target directory How can I make sure the file is delivered, without server access ? Answer All you can do is to check
Proper implementation of an inter process communication (IPC)
Is the following a proper implementation of an inter-process communication? It seems to be working but I’m wondering if there could be a race condition leading to hanging. One constraint is that both processes need to be started independently and in any order. Answer Some stress tests showed no problem …
How to handle 0 Content length in POST request in CGI?
In my CGI application something happens when I pass a 0 content length POST request. Here is my code: I test my application using the Http-Requester plugin for FireFox, when I pass a POST request with no data, the application seems like it enters a loop and no response. If I pass a GET request, the code works…
Pidof not finding the process
I want to find out a shell script process ID using pidof or ps command or any. All i want is only the process id of it. I have used ‘pidof -x test.sh’. Which is not working. Note: I don’t want to invoke the /bin/sh or /bin/bash – because the script will not work. If i invoke /bin/sh in…
errno after accept in Linux socket programming
As stated in accept() man page in RETURN VALUE section: Error handling Linux accept() (and accept4()) passes already-pending network errors on the new socket as an error code from accept(). This behavior differs from other BSD socket implementations. For reliable operation the application should detect the ne…
Run a perl script with the ending .pl
I have a question to perl scripts. I can write and understand C and C++ codes but have no experience in perl. I have a perl script with the extension .pl and want to run it on a Raspberry Pi Model B. I get the script (its a part of the Raspberry Pi B extension ‘Busware SD0’ Firmware) from this
When using htop command, do red values in the time+ column mean there’s something wrong?
Below is my server htop display. The nginx process uses CPU time more then 18 hours, and is shown in red color, but CPU and memory all look OK. Is the value within the normal range? Answer I was curious about this too, so I dug into the source code and found this: So, it looks like whenever the CPU
Python + pexpect – How to establish a ssh connection?
I’ve been trying to establish an ssh connection via Python + pexpect, but I can’t send the lines that I want. I think it’s certainly a syntax problem, but I don’t know where it is occurring. The problem is that the password ‘xxyyzz’ never appears on the terminal, so I think…
How do I install Node and NPM so I don’t have to use sudo?
I am trying to set up Node.js and NPM on a Ubuntu 14.04 machine but am having some trouble. On my first try I kept getting EACCES errors when trying to install packages(sometimes even with sudo), so I completely uninstalled node and npm. Now I’m trying to figure out how to install them in a way that won…