General :: Best Way To Execute A Script?
Jun 23, 2010
There are many ways to execute a script (*.sh). But what is the best way to execute a script also what should be its location. So that it can be executed from anywhere in the shell. I don't want to execute them with ./*.sh.
View 8 Replies
ADVERTISEMENT
Feb 17, 2011
i created a /tmp partition amd mounted it like this:" mount -o loop,noexec,nosuid,rw /usr/tmpDSK /tmp"
I know i can't execute things in /tmp now but is there a way to execute only one file and no more???
View 1 Replies
View Related
Aug 23, 2010
how to execute csh in sh ie, if I have a script in csh syntax as , ( my.csh )
##################
set x = y
setenv xx YY
##################
And I have a sh script ( my.sh )
#####################
#!/bin/sh
I want to call here the my.csh in such a way that I have access to variables set by the
csh script
ie. echo $x $xx shoud work from sh ( main script )
######################
View 13 Replies
View Related
May 14, 2010
I have a two seperate files on my computer,
which execfile
/usr/local/bin/
/usr/bin/
so, i have two files with the same name in two different directories. How can I specify exactly which command to run?
View 6 Replies
View Related
Mar 8, 2010
Trying to run an executable, but it's not working for some reason:
Code:
View 14 Replies
View Related
Oct 26, 2009
I m trying to execute my file from with in vi. i m using following syntax esc :!<program-name> m i making any mistake as it is giving me an error.
My program is this:
#This program takes 3 Parameters from user namely name,address,phonenumber and store those details in detail.out file .
#To store output in only milind directory by doing this if we run this file within any directory the file get stored in milind directory only.
View 14 Replies
View Related
Sep 21, 2010
Downloading Virtual box, I saw a link with title All distributions on its home page:
VirtualBox-3.2.8-64453-Linux_x86.run
I have not downloaded it yet, I wanted to know how to execute it ? I've never seen a .run file before ! Does this mean this file is supposed to run on all distributions ?
View 13 Replies
View Related
Mar 12, 2011
ill have this question on the test maybe : In dir00 directory create files year01.txt, year02, ...year05.txt with January calendar for 2001-2005 years in it.-i'm lost. i execute this : cat | cal 01 2001 > year01.txt
View 12 Replies
View Related
Dec 1, 2008
Is there a way to execute some command and then after the command completes utomatically reboot the system and then after the system reboots execute another command ? For example look at the sequence shown below(1) Execute command-1(2) After the command-1 in (1) is completed,reboot the system (3) Execute command-2(4) After execution of command-2 reboot the sytemIs there a way i can automate this process so that i need not reboot the system manually
View 5 Replies
View Related
Feb 11, 2010
Trying to setup a new Ubuntu machine and just downloaded 'p4' (Perforce command line client). It's a single file download - a statically-linked binary executable, so I just did:
wget [URL]
...right into /usr/bin. Simple enough. Except:
root@aj-ubuntu:/usr/bin# ll p4
-rwxr-xr-x 1 root root 748808 2010-02-11 16:54 p4
root@aj-ubuntu:/usr/bin# ./p4
[Code].....
View 6 Replies
View Related
Aug 27, 2010
I want a quick and simple way to execute a command whenever a file changes. I want something very simple, something I will leave running on a terminal and close it whenever I'm finished working with that file. Currently, I'm using this: while read; do ./myfile.py ; done And then I need to go to that terminal and press Enter, whenever I save that file on my editor. What I want is something like this: while sleep_until_file_has_changed myfile.py ; do ./myfile.py ; done
Or any other solution as easy as that. BTW: I'm using Vim, and I know I can add an autocommand to run something on BufWrite, but this is not the kind of solution I want now. Update: I want something simple, discardable if possible. What's more, I want something to run in a terminal because I want to see the program output (I want to see error messages).
View 7 Replies
View Related
Oct 3, 2010
How do I set up SSH so I don't have to type my password? i execute the following command ssh -l admin hostname command but each time i execute it, it ask me to enter password.how i can give it password as default because i'm going to put in bash file ?
View 2 Replies
View Related
Apr 6, 2011
Create a file. change its permissions at a specific time. change the permission.
At the moment this is what I have and it changes the permissions of the file but not according to the time specified.
View 2 Replies
View Related
May 4, 2011
I am working in a CentOS environment with numerous CentOS machines. Currently there are multiple developers that each have their own login/home directory and then for various admin tasks we all share a single super user account.
The problem
I have a number of aliases, variables, functions, and settings that exist in my personal login's .bash_profile. None of these are available in the shared super user's .bash_profile. My current work around is that everytime I sudo in as the super user and I re-execute my .bash_profile from my personal user's home directory. I am not allowed to edit the init stuff for the super user
The Question
Is there any way I can automate my sudo sequence such that it will execute my personal .bash_profile after I've executed sudo without requiring me to edit the super user's bash init stuff?
View 3 Replies
View Related
Aug 11, 2010
I want to allow a user to reset people's faillog. When I go into the /etc/sudoers file and put this syntax in I still get an error stating : /var/log/faillog permission denied.
Here is what I put syntax:
%user ALL=/usr/bin/faillog,/var/log/faillog
View 1 Replies
View Related
Jan 24, 2010
setuid bit allows the process to execute the file with the uid of the file. But, what is the purpose of setting setuid without execute bit? The man page tells that if a file is setuid without execute flag, the permission will be displayed as 'S' (capital s) in ls command. Why should anyone set the setuid without execute flag? Does setting setuid without execute flag have any special meaning?
View 1 Replies
View Related
Apr 1, 2010
I have and entry in a crontab for my user (appadmin) that when it executes it does not start with the proper path. It needs to start as the appadmin user as appadmin owns all the directories for glassfish. However, once glassfish restarts, the hudson application cannot find the default JDK. I get an error. If I initiate the restart via command line, all works as it should. I believe it has something to do with PATH in the crontab but am not sure what I need to set the PATH to in crontab.
View 1 Replies
View Related
Apr 24, 2010
I was always confused about the way it says that the execute permission for a directory means "able to list it". I just don't get it.Does no exec permission mean "still able to read files from in the directory, but not able to find out what files it contains" or what?
View 2 Replies
View Related
Jun 30, 2011
When i click in one icon (for example), this icon executes "java -jar ...". In another words: Make a .exe on linux.
View 2 Replies
View Related
Jun 23, 2010
I just want to know that how can I execute a example.sh (script) from command-line like other Unix commands. Please write full procedure
View 4 Replies
View Related
Mar 3, 2011
How do i open .exe files using wine? I've tried right clicking it & opening it in a erminal but when i do this it saysProcess of pid=0015 has terminatedNo process loaded, cannot execute 'echo Modules:'Cannot get info on module while no process is loadedNo process loaded, cannot execute 'echo Threads:'
process tid prio (all id:s are in hex)
0000000d
0000000f 0
[code]...
View 14 Replies
View Related
Aug 27, 2009
For example, I write the file like in vi or something. I wanna execute but no one read , write and execute but one more thing no one to view the file like encrypt the file.
View 5 Replies
View Related
Jan 7, 2010
I used to execute the command setrcs /data/dev/projects in a solaris machine. And all the files in the given path were visible from the current directory (whichever directory i am in). So that i need not copy necessary files required for compilation from the path to the current directory.
Ex: Suppose I am writing a C code x.c in the directory /root/test/. I do #include <bdm.c> in the file x.c. While executing I need not have the bdm.c in the current directory. Because I have executed the command setrcs /data/dev/projects. The compiler automatically looks for the bdm.c file in the path /data/dev/projects. But i am not able to execute the command setrcs in linux. Is there any similar command with similar functions or if there is any different command in Linux which serves my purpose.
View 1 Replies
View Related
Feb 13, 2011
SU results in Cannot execute bash: No such file or directory.
View 1 Replies
View Related
Jul 29, 2010
Top: error while loading shared libraries: libproc.so.2.0.6: cannot open shared object. I am not able to execute top and ps command.
View 6 Replies
View Related
Jan 6, 2010
Is there a way to execute top command once and exit...i.e. stop refreshing window and continue console without pressing 'q' or 'ctrl+c'...
View 3 Replies
View Related
Jun 9, 2010
For some reason it simply won't execute anymore. I even downloaded a 2nd copy (and set it as executable) but it asks what I want to open it with. Forgot to mention I am using the latest Musix
View 3 Replies
View Related
Mar 25, 2010
My problem is:
sub init() {
$Test->description("Establishing the connection to the client");
eval {
$Host = host($CLIENT) or die($@);
$Conn = connect("#ssh") or die "Client connection Failed" . $@;
};
if ($@) {
$Log->error("Unable to instantiate the Objects for the Test" .
[Code]...
Here I'm trying to connect windows machine using connect object which is working fine. But when I tried to execute the command on Windows machine from Linux machine by using:
[Code]...
View 1 Replies
View Related
Jun 15, 2011
I am having trouble getting the while loop to execute in the ssh command:ssh $USERID@serverX "while read line do echo $line done<$list_dir/cost_feed.lst.old"Error:bash: -c: line 1: syntax error: unexpected end of fileI have managed to use simpler commands with ssh like:ssh $USERID@serverX "pwd; cp x y"I expect that I need to add some combination of escape characters or semicolons
View 3 Replies
View Related
Mar 18, 2011
I am very new to Linux and everything I read says the android OS is based on Linux. That said I am evaluating 2 Android tablets. The Samsung Galaxy and the Motorola Xoom. I am trying to execute wmv files in a web browser, the wmv files download as .wvx rather than play. I have installed flash but the problem continues.
View 1 Replies
View Related