Hi,
i'm trying to spawn a daemon-like process from php on a unix environment, keep the pid for reference and keep it completely independent from httpd processes. This is useful for controlling middleware applications from administrative backoffices. I want to keep it generalized to reuse for any command, i don't want to write a .sh for ...
If I nohuped a parent process in unix, will the spawned child processes have the same protection as their parent?.
Suppose,
nohup par-process.sh &
and if par-process.sh contains the call to child as,
par-child.sh
will par-child be nohuped or should I do that explicitly for it?
Thanks in advance.
...
Is there a way, from ssh, to get output back to the shell ssh was invoked from, kind of like :! in vim?
For example, say I'm grepping a file for 'bananas' on a remote server, and I want to copy the output to an IM window - is there a way to invoke pbcopy on my local machine, or am I stuck selecting/copying from the terminal window?
In ...
I want Matlab to run some .m file, which writes to a text file. I don't want the GUI to launch, and I don't want the command line interpreter to run. I've got
matlab -nodisplay -r myfile
But this still runs the interpreter. What options should I be using?
...
I am new in Unix, can somebody kind to tell me how to install valgrind in ssh client so that I can use valgrind command in my sunfire account?
...
Hi,
I am trying my hands with unix socket programming in C. But while reading I am getting Err No as 4. I am unable to find out the description of this error code. Does anybody have any idea?
...
How to write a bash command that finds all files in the current directory that contain the word “foo”, regardless of case?
...
I have the following requirement where there are 3 scripts say,
a2,a3,a4
Now as per the requirement a2,a3 should be executed parallely and a4 sequentially.(ie., a4 should be executed only after the completion of a2&a3).
Now I tried this like,
((((echo 'start a2' `date`; nohup a2; echo 'end a2') >>log) &)
(((echo 'start a3'; nohup a3; ...
Hi all,
I have been trying to execute the following unix shell script which is not working.
I am running it by ksh.
echo $?;
if [ $? -ne 0 ]
then
failed $LINENO-2 $5 $6
fi
failed()
{
echo "$0 failed at line number $1";
echo "moving $2 to failed folder"
}
This is giving an error saying "Synatx error:then unexpected". Basicall...
I need to take information from two different data bases.
select * from TABLE_ONDB2 where column_on_db2 in ( select column_on_db1 from TABLE_ONDB1 );
Problem is both are on different db instances so I am not able to figure out how to put table names and column names etc.
I hope my question is clear.
...
Greetings,
I would like to know if there is any equivalent Powershell commands for the following
UNIX commands:
make
trap
Thanks.
...
I want to test a program's memory management capabilities, for example (say, program name is director)
What happens if some other processes take up too much memory, and there is too less memory for director to run? How does director behave?
What happens if too many of the CPU cycles are used by some other program while director is runn...
I'm not sure why this code isn't working. Its not going to the copy command.
I successfully run this manually on the command line (without the check)
I don't think i'm performing a correct file check? Is there a better, cleaner way to write this?
I just want to make sure the file exists, if so, copy it over. Thanks.
#!/bin/bash
if [ $...
I am interested in knowing if we can catch SIGINT, SIGHUP equivalent signals in Powershell and how to do it?
I also could not find if there is anything equivalent in powershell like "stty -echo" in unix environment.
Thanks,
...
Hi geeks,
This maybe a linguistic question. I have checked the loop device on Wikipedia. It is just for mounting files as block device. But what does "loop" mean here? Its usage here is totally bizarre to me. I am not a native English speaker. So could someone explain this jargon to me in plain English? :)
Thanks.
...
I have a unix script which creates a temporary log file, say tempfl.log.
When this file is created it has permission rw-r--r--.
There is a line
chmod 0440 /etc/sudoers tempfl.log 2>&1
But when the script is done the permission changes to r--r--r-- but it should be rw-r--r--. If I change the line to
chmod 0644 /etc/sudoers tempfl.lo...
I recently had some HD issues and had to get a new one. I transferred over my data using Migration Assistant on my freshly imaged disk. Then with but a minute left until I was in the clear, there is a town wide power outage. I was at work and had no backup generator and the university's didn't source the outlets, so my transfer was stopp...
hello all,
i'm using the latest version of smarty (3.0rc3).
i made my templates_c directory writable in command line (chmod -R 777 templates_c) but smarty still outputs this when i call $smart->utility->testInstall();
Testing compile directory...
FAILED: ./php/classes/smarty/templates_c/ is not writable.
Warning: rename(/tmp/wrtub1GxS,...
I want to use a library that uses file descriptors as the basic means to access its data. For performance reasons, I don't want to have to commit files to the disk each before I use this library's functions.
I want to create (large) data blobs on the fly, and call into the library to send them to a server. As it stands, I have to write ...
I am looking for a way to determine file permissions for the current user (i.e. the process's UID) on POSIX-compliant systems. I don't want to try opening the file - that could get messy with directories and all kinds of special files.
I am compiling a directory listing of a specified directory, and for each file, reporting a bunch of t...