Here is an example on how to get the process ID of an application in bash script
The Standard UNIX File Descriptors – Standard Input (stdin), Standard Output (stdout), and Standard Error (stderr). Bash and other modern shell provides I/O redirection facility. There are 3 default standard files (standard streams) open:
[a] stdin – Use to get input (keyboard) i.e. data going into a program.
[b] stdout – Use to write information (screen)
[c] stderr – Use to write error message (screen)
You can look at /usr/include/unistd.h if you forget them:
/* Standard file descriptors. */ #define STDIN_FILENO 0 /* Standard input. */ #define STDOUT_FILENO 1 /* Standard output. */ #define STDERR_FILENO 2 /* Standard error output. */
In this post we have some basic scripting samples collected from here and there. It must be straightforward and to the point, way better than going through pages of manuals looking for a clue. Check the resources at the end
Here are 2 easy steps to ssh into a host without login:
One of the tools in any system engineer’s hand as well as those dealing with customer remote service is to set a remote connection to the other end’s server or PC, through VPN, Public IP or any other possible way. One easy yet effective approach is to establish a ssh tunnel by means of reverse SSH.
Here is the simple postfix configuration to make it work with freepbx.
Based on a customer request, we needed to have some virtual extensions (Voice Mail enabled) but the problem was that they wanted the incoming calls to extensions to ring 4 times before falling back to voice mail. Since by default FreePBX will get the extension status as UNAVAILABLE and I couldn’t get virtual extension running with this version of freepbx, i did this trick:
This post shows a plain CLID popup.
download the zipped files
You can directly update password using the following method to update or change password for user vivek:
1) Login to mysql server, type the following command at shell prompt: