Questions relating to the execution (running) of a file (usually a compiled binary) or a command.

learn more… | top users | synonyms

84
votes
10answers
52k views

How do I run executable scripts in Nautilus?

When I double-click on a script in Nautilus to run it, the script just opens in my text editor with no option to run it. Using Nautilus, how do I run executable text files and/or scripts?
14
votes
6answers
770 views

Most efficient way of launching and separating a program from the terminal? [duplicate]

I'm trying to launch a program from the Terminal in such a way that the following occurs: Closing the Terminal does not close the program The program is not outputting anything to the Terminal while ...
14
votes
2answers
35k views

Why doesn't rc.local run all my commands, and what can I do about it?

I have the following rc.local script: #!/bin/sh -e # # rc.local # # This script is executed at the end of each multiuser runlevel. # Make sure that the script will "exit 0" on success or any other # ...
11
votes
2answers
10k views

How do I change the launcher commands?

I'd like to change the behaviour of the launcher, so that if I click on the firefox icon, it runs the command $ optirun firefox Does anyone know how to change it? Thank you
10
votes
1answer
839 views

What does this “… | ps `cat`” command do?

On my Internet research, I found the following command as solution to find the process name of a window: xprop _NET_WM_PID | sed 's/_NET_WM_PID(CARDINAL) = //' | ps `cat` I just do not understand ...
6
votes
5answers
8k views

Execute command before shutdown/reboot

I have a machine running a couple of vagrant VM. The problem I have is that sometimes I forget to shutdown those VM before I shutdown or reboot my machine. Because of that my machine get stuck with ...
6
votes
2answers
1k views

Execute command from file in current shell

I want to executed command from file (which is script) in current shell in terminal. Example: I have file ch_dir contains following: #!/bin/bash cd /usr Now if I execute file usually as following ...
5
votes
5answers
414 views

What is use of command: `command`?

Recently I found command: command which has no manual entry but help displays as follows: $ help command command: command [-pVv] command [arg ...] Execute a simple command or display information ...
5
votes
5answers
451 views

Needed simple script/loop/command for input command, execute and output within textfiles

Suppose I have list of commands in text file as below (cat cmdlist.txt):- cut lshw top awk sensors Now I want to get simple information on that command by whatis cut, whatis lshw etc. respectively ...
5
votes
0answers
4k views

How do I run executable scripts in Nautilus rather than open them in Gedit text editor? [duplicate]

When I double-click on a script in Nautilus in order to run it, the script opens in my text editor with no option to do so. Using Nautilus, how do I run executable text files and/or scripts?
4
votes
4answers
17k views

Run command on another(new) terminal window

How to run any command in another terminal window? Example: I opened one terminal window and if I run command like apropos editor, then it run and out-puts on that window. But I want to run same ...
4
votes
1answer
94 views

How to get sudo to prompt you for a password each time

I find that if I execute something using sudo that then if I execute something else soon after also using sudo, that it does not prompt me for my password, and although this can be inconvenient in ...
4
votes
2answers
96 views

How can I access the locational data of the currently selected file or folder?

I want to be able to select a file, run a script with a shortcut and that script gets the path of the file I've selected (or am dragging). I've selected it in nautilus. I know how to run the command, ...
4
votes
1answer
1k views

How to run - from Firefox context menu - terminal commands selected in web pages?

Instead of copying it from the web and pasting it in the terminal, I want to be able to select a command displayed in a web page and with right click context menu to add it and run it in terminal. ...
3
votes
4answers
545 views

Add to path only sh file not a dir

I have a bin folder with a bunch of sh files. For example "server-run.sh", "server-stop.sh", "server-do-something.sh". And I want to run file "server-stop.sh" from anywhere. I could add this bin ...
3
votes
2answers
3k views

Pausing a long running program in the terminal?

Is there a keyboard key combination that I can use to pause a program running in the terminal? In case it matters, I don't intend to run anything else inside that terminal while the program is paused. ...
3
votes
2answers
61k views

Copying file from folder 1 to folder 2 in terminal

I am trying to move a text file from folder 1 to folder 2 via terminal. I'm doing this for a school project to show what actually happens when you copy paste. I'm doing cp/home/rits/desktop/folder1 ...
3
votes
1answer
203 views

What is the difference between `command` and `./command`?

I found that sometime I use the command to run a command, but sometime I use the ./command to run another command. What is the difference?
3
votes
1answer
603 views

Why some server requires './' to run scripts but others don't?

I'm wondering why some Ubuntu servers are different. I have two Ubuntu 12.04 server which are running a web application. Today I tried to run an sh file from its folder. Server 1 can run shell ...
3
votes
1answer
3k views

How to automate execution of commands in separate terminals?

I am new to LINUX operating system. I am using ROS (Robotic Operating System) where I type few commands in separate terminal windows for doing the setup. ie Before I run my program, I have to do ...
3
votes
1answer
1k views

vim command does not work

I am trying to open vim on my Ubuntu 14.04 64 bit by entering the command in the terminal : vim But i get the response : The program 'vim' can be found in the following packages: * vim * ...
3
votes
3answers
199 views

Is there any difference between run command in terminal & ALT+F2

For running direct command, there is two way. Either run in Terminal Or run with Ctrl+Alt+F2 Then, Is there any difference between them? (working same & shell) or redirects to same?
2
votes
2answers
5k views

not able to execute .sh file

I downloaded modelsim install file which contained .sh file in it -setup.sh I did the following two things Right click->properties->permision->allow executing file as program ->double clicked the ...
2
votes
2answers
149 views

root@mickey:/#su goofy && ssh goofy.com — why does this fail?

mickey (who is logged in as root) tries to use goofy's account to ssh into goofy.com. root@mickey:/#su goofy && ssh goofy.com however this fails to login goofy on goofy.com, instead: ...
2
votes
1answer
152 views

Where are key press scripts stored?

When I hit the Volume Up multimedia key, I receive the following output from xev. KeyRelease event, serial 38, synthetic NO, window 0x4200001, root 0x91, subw 0x0, time 100844850, (1037,434), ...
2
votes
1answer
4k views

rc.local won't execute the script

This is my rc.local #!/bin/sh -e # # rc.local # # This script is executed at the end of each multiuser runlevel. # Make sure that the script will "exit 0" on success or any other # value on error. # ...
2
votes
1answer
2k views

Unable to change execute permissions of .sh file [duplicate]

I'm out with a new problem. I've downloaded a jdk7.sh file. Now I'm unable to change the permission of the file to allow executing the file as a program. I mark the check box and again it disappears.
2
votes
1answer
87 views

What is the difference between -exec with '{}' ';' and -exec with {} /;?

While trying my hand at writing some bash scripts I've come across various usage of the -exec parameter. In my context, I'm using it after the find command. This guide states to use {} /; after the ...
2
votes
1answer
308 views

Ubuntu / Bash recognising “export PATH=$PATH:~/…” but not “export PATH=$PATH:/home/…”

So I've been using ubuntu since 09.04 but have limited experience with sys admin. I now want to get into web development and as part of installing the Play Framework, I had to add the activator path ...
2
votes
2answers
101 views

How to start a program without interrupting my current session?

I'am working on some code or document and I need an additional program like IntellJ e.g. How can I start this program in the background without popping up and interrupting me on my work? Often I start ...
1
vote
3answers
187 views

Help creating a messagebox notification with yes/no options before an application runs

I started using Ubuntu alongside Windows about 2 months ago. I've slowly been adding all of the programs that I use regularly to Ubuntu, so that I will eventually be able to do everything in Ubuntu ...
1
vote
4answers
98 views

Is there anything that can let me run 64bit binary executable files? [duplicate]

Is there anything in ubuntu 32 bit 14.04LTS something light, that will let me execute 64 bit binary executable files? Architecture: i686 CPU op-mode(s): 32-bit, 64-bit Byte Order: ...
1
vote
1answer
183 views

write a bash which open firefox on every ten minute

Is it possible to write an script which do a specific command every ten minute? I do not know if this is a loop? For example Every ten minute delete a file name foo on the home directory? or every ...
1
vote
1answer
2k views

rc.local not executing command

I was trying to make my laptop running Ubuntu 13.10 remember the brightness from the last time and set it automatically on start-up. I was thinking about using xbacklight to set the brightness. So, as ...
1
vote
2answers
2k views

how can I add a command in terminal to open a file

I save a file Logisim2.7.1.jar in my directory at /home/danny/Application. Whenever I want to run this file in terminal, i have to type these following line in terminal: cd /home/danny/Application ...
1
vote
2answers
30 views

How to excecute a .sh program with old date

How can i make a .sh file that will run another .sh file on a old date like... Set date to 2014/06/03 run .sh file set date back to real time
1
vote
1answer
46 views

Redirection with pipe

I have the following command to be executed. ls > myFile.txt | wc The output of the command shown is 0 0 0 Why isn't the above command giving the line/word/character count of ls output? Am ...
1
vote
1answer
135 views

text editing using tr command

On using the command: tr -s '\n' ' '< test1 where test1 is a text file. If test1 is written in a manner such that it contains newlines (linefeed characters) and not \n (backslash-n) then the ...
1
vote
2answers
127 views

How to run executables directly from nautilus? [duplicate]

When I write C codes in geany and the build and then run the program from there using the buttons there, it works fine. Again I can run the compiled executables using ./file_name command from terminal ...
1
vote
2answers
180 views

Is there a command to scroll?

Other than using xdotool is there a way to scroll down by a set amount using a command. In other words, what is the scrolling command? I'm not looking for a keyboard shortcut, I want a command for ...
1
vote
2answers
150 views

How do I execute a program with default variables?

How can I execute a program (specifically a bash alias) with the default environment variables? Consider this example: export test="something I dont want to exist" alias _xterm='xterm -fn 7x13 -fa ...
1
vote
2answers
1k views

Open terminal output in sublime2

I want to open the output of terminal commands in sublime2. e.g. when I do $ list , it lists all files/folders in terminal. I want that when I run this command a temporary text file should be created ...
1
vote
2answers
530 views

difference between mkisofs and genisoimage

Is There any changes in mkisofs, Previously for creating iso I have used mkisofs, but now it is taking gensioimage ? With mkisofs my work going good, but genisoimage I am facing problems with ...
1
vote
1answer
211 views

Running executable files in GUI [duplicate]

I have an executable file called drracket in a folder : However in GUI it appears as a source file : Is there a way to run the file via GUI like double-click etc.? (Running it in prompt forces me ...
1
vote
1answer
97 views

How to create your own commands that can be used anywhere [duplicate]

I am new to linux, and I am learning bash scripting at the moment. I was wondering how I would save my script as a command and then be able to call that command anywhere in the terminal. So i could ...
1
vote
1answer
192 views

Admin name appears twice if it asks for admin password. Ubuntu 12.04 LTS

I was trying to apply some given items at this page to secure my Ubuntu 12,04. After applying item number 4; my user name which is the only admin, appears twice if system asks for an admin password as ...
1
vote
3answers
34 views

History command in graphic interface of OS

Does Ubuntu store a history of command executed in the graphic interface (not in a shell session)? For example if, by mouse, I click on System Settings, then click on Network, do these steps ...
1
vote
1answer
58 views

Need help with .sh script

I’m trying to get this ~/Desktop/Tor/tor-browser_en-US/ && ./start-tor-browser to run as a .sh. I've tried over and over again to get it to work, what am I doing wrong? #!/bin/bash chmod ...
1
vote
1answer
1k views

Cannot Execute Binary File: Exec Format Error OOTP2015

I am trying to install OOTP15 for linux. I have downloaded the file and it is in my home folder. When I go to execute the file I get the error message: bash: ...
1
vote
0answers
351 views

sublime text 2 via gnome-Terminal GLib-CRITICAL

Whenever I run sublime text 2 from the command line (via the 'subl' shortcut command) I receive the following error (sublime_text:4679): GLib-CRITICAL **: Source ID 15745 was not found when ...