I have a script that starts a server on a remote VM. All works great until I close the shell where I executed the script. When the shell closes, so does the server.
After some looking around I found the following:
& will send the job to the background when executed with the symbol
disown -h will disconnect the job from the shell and allow it…
How to execute /home/scripts/test.sh file in php
Previously i have placed 'test.sh' file in the /usr/bin and calling in my php file like this
exec('test.sh ' . escapeshellarg($testString));
But for security reasons i moved .sh file to /home/scripts directory and in my php i am calling like this
exec('/home/scripts/test.sh ' .…
I've noticed that when running a script that connects to a number of our servers (to essentially run batch commands) that the commands aren't logged in the user's .sh_history or .bash_history files. Is there a place where this is logged (assuming the script itself isn't doing the logging and I'm not tee'ing the output anywhere)?
…
I have a series of files in a directory that I need to carry an action out on using a script. Once the action is done, then I want to keep a log that the file has been processed, so that the next time the script is run, it does not attempt to carry out the action again.
So lets say I can find all the files that should be…
I have a specific set of binaries installed at:
~/.GutenMark/binary/<binaries...>
These were previously working correctly, but for seemingly no reason when I attempt to execute them the shell claims not to find them:
james@anubis:~/.GutenMark/binary$ ls -al
...
-rwxr-xr-x 1 james james 2979036 2009-05-10 13:34…
In Jenkins project I add command for executiong
rm /var/www/ru.liveyurist.ru/tmp/*
But when I build project I get error:
Started by user anonymous
Building in workspace /var/www/ru.myproject.ru
Updating https://subversion.assembla.com/svn/myproject/trunk
At revision 1168
no change for…
The following situation:
We have Windows XP Embedded clients that have all admin shares disabled and only have read-only shares (for security reasons).
What we want to do is run remote shell (dos) commands on these machines.
At first we looked at PsExec & BeyondExec applications…
Somehow I managed to screw up my shell-encoding. An example:
root§server:ç£ cat --help
Usage: cat ¡OPTION¿... ¡FILE¿...
Concatenate FILE(s), or standard input, to standard output.
-A, --show-all equivalent to -vET
-b, --number-nonblank number nonempty output lines
…
So, I see similar questions, but none of the answers work for me.
I updated Python to 3.1.3 from 2.6.1. Everything works, except: When I type python into Terminal, I get:
Python 2.6.1 (r261:67515, Jun 24 2010, 21:47:49)
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin
Type…
I am facing a strange problem. The FTP on my Plesk VPS is not working. Whenever I try to connect, FileZilla FTP client says:
Status: Resolving address of xxxxxxxxxxxxx.com
Status: Connecting to xxx.xxx.xxx.xxx:21...
Status: Connection established, waiting for welcome…
Hi,
I want to process many files and since I've here a bunch of cores I want to do it in parallel:
for i in *.myfiles; do do_something $i `derived_params $i` other_params; done
I know of a Makefile solution but my commands needs the arguments out of the shell globbing…
I have written a script that does this but it is one of my first scripts ever so i am sure there is a better way:)
Let me know how you would go about doing this.
I'm looking for a simple yet efficient way to do this.
Here is some important background info:
( It might be…
I'm trying to install themes with gnome tweak, and I need to install gnome-shell-extensions-user-theme because otherwise I cannot see the shell extensions tab. However, I cannot install shell extensions. I have tried to install by adding the PPA with the following:
sudo…
I have a script which starts a daemon process and then sleeps for 20 seconds. If I run the script on SLES11 SP1 or RHEL6 then after the script exits the process is still running.
If I run the script on SLES11 SP3 or RHEL6.3 then after the script exits the process is no…
Hi all,
How to convert an NSDate into Unix timestamp? I've read many posts which do the reverse. But I'm not finding anything related to my question.
Thanx in advance.
Hi all,
How can you convert the UNIX timestamp (that is in the form of a number denoting timestamp) into date, time(hours, minutes, seconds) in Objective-C?
Thanx in advance.
I tried to sort these number with Unix sort, but it doesn't seem to work:
2e-13
1e-91
2e-13
1e-104
3e-19
9e-99
This is my command:
sort -nr file.txt
What's the right way to do it?
I did some searching but I cannot find documentation on how unix usage works. I know somethings (mostly through trial and error) but for example how do I know that:
/usr/bin/ls [-aAbcCdeEfFghHilLmnopqrRstuvVx1@] [file]...
Means that you can include more than one…
Unix configuration files come in all shapes and forms. I know that Webmin has a Perl API that makes it easy to parse and modify most common configuration pro grammatically, while preserving changes that might have been made by hand.
Are there any other libraries…
is it bad to output many files to the same directory in unix/linux? I run thousands of jobs on a cluster and each outputs a file, to one directory. The upper bound here is around ~50,000 files. Can IO be limited in speed in light of this? If so, does the…
I have a string and I need to find out whether it is a unix timestamp or not, how can I do that effectively?
I found this thread via Google, but it doesn't come up with a very solid answer, I'm afraid. (And yes, I cribbed the question from the original…
I bash, how do I convert dos/windows newlines to unix? It must be non-interactive, not like starting vi and typing something in, but a command on the command line that can be put in a script file. The dos2unix and unix2dos commands are not available on…