Bash is the shell used in Ubuntu's command-line interface.

learn more… | top users | synonyms (1)

0
votes
1answer
28 views

Ubuntu users - access to file of different user

I am just messed up with users of Ubuntu. I just have two users of my system: father and son Now I want to have access to all of my son files. But not by using sudo. It must be automaticaly. Now i ...
0
votes
1answer
41 views

sudo ssh-add /root/.ssh/id_rsa return error

I m trying to save ssh authentication with the command ssh-add for sudo usage: linux$ sudo ssh-add /root/.ssh/id_rsa Could not open a connection to your authentication agent. but as indicated it ...
0
votes
2answers
120 views

convert txt file to csv seperated with tabs

Sorry people I'm new to Linux, and while I looked through the list of answered questions, I don't know enough to recognize if my question was answered. Or if I can adapt one of the answer to my ...
0
votes
3answers
26 views

Convert Number of Decimals Through a Text File

This question's solution may revolve around perl, sed or awk and unfortunately I am not familiar with any of those. My purpose is to convert a computer-generated text file to give it more ...
-1
votes
0answers
38 views

bash: /usr/share/virtualenvwrapper/virtualenvwrapper_lazy.sh: No such file or directory and bash

bash: /usr/local/bin/virtualenwrapper_lazy.sh: No such file or directory Is showing up each time I start the terminal. I installed virtualenvwrapper, by using: sudo pip install virtualenvwrapper ...
0
votes
0answers
32 views

which dependencies am I missing for Corsair water cooler Link driver?

I'm attempting to install an open-source linux driver for my Corsair h100i GTX water cooler. I'm following these instructions. Once I run the script or try to change setting through terminal I get ...
0
votes
1answer
34 views

How do I run an executable in a directory I added to PATH?

I added a directory to my PATH by doing PATH=$PATH:~/Documents/Clang but when I type ./clang, Bash says No such file or directory. Why is that?
1
vote
1answer
20 views

When does script invocation require path/script.sh

I distinctly remember reading that when $PATH does not include the working directory Linux script invocation requires the path even if the path is ./ and so the script invocation is ./script.sh ...
0
votes
1answer
19 views

Why can't my non admin users use mlocate command?

I have a node.js software agent running on 14.04 not able to run many of his bash scripts on a new server. The problem I seem to have is the limited user returns nothing from the locate or mlocate ...
0
votes
1answer
34 views

Bash script to dynamically find and construct the url and download

I would like to write an script which opens a URL (not a complete URL link) and finds the latest available version of a file. Then, it will go one level up from that directory, find some file in that ...
4
votes
3answers
192 views

How to start or kill tasks when the core temperatures goes above/below a specific value?

I would like to write a short script that gets launched manually once and then should: run a command if all temperatures are below x °C. pause the command if any temperature rises above y °C. ...
0
votes
1answer
36 views

How to copy clone folder to remote computer in one line?

I have two machines with the same folder structure. One is my personal computer, the other is a remote computer. Sometimes I want a program to run on the remote computer. At the moment I always need ...
0
votes
1answer
21 views

crontab java process information

I try to get a bash script running that should output the java process information to a file. Unfortunately when I add it to the crontab -e the script is not executed. As user root the script is ...
1
vote
0answers
70 views

Bash shell doesn't display Python output

I started using vim + tmux for my programming and suddenly after accidentally smashing couple of keys [Forgive me I am a klutz] the bash shell started acting weirdly. When I run my unittest written ...
1
vote
1answer
54 views

how to move the cursor to previous lines which begins with > in bash?

When I copy and paste below code into bash, every line begins with > symbol; like: cat >hello.c <<"EOF" #include <stdio.h> int main() { printf("Hello World\n"); return 0; } EOF ...
1
vote
3answers
35 views

Getting the version number after library's name and extension in Bash

How can I get the version number after a .so file using Bash? I have obtained the library's full path and extracted the name. Like libpcap.so.1.1.1. Now I need to get the version number after so; for ...
-1
votes
2answers
54 views

How can I use “find” in shell scripts to search from current directory and most importantly subdirectories?

My script does work, but the script only searches its current directory. I would like my script to search for a file in the subdirectories. This is what I have so far. #!/bin/bash read -p "file ...
3
votes
1answer
34 views

List all versions of a library using bash

I wrote this script to get the version number of all the libpcap libraries on my Ubuntu system. #!/bin/bash allLIBs=$(ldconfig -p | grep libpcap) echo "$allLIBs" | while IFS= read -r a; do ...
0
votes
1answer
30 views

Quit LightDM & launch a new x-session with an alternative xorg.conf

I'm using Ubuntu 15.10 with the following configuration: LightDM, XFCE, set to one screen across two physical monitors running from two outputs on a single NVIDIA card. This is my normal environment ...
1
vote
1answer
21 views

need help with script options in terminal/bash

I'm fairly new to scripting (self teacher), but not clueless. im trying to make and easy installer script for a program version set, and am running into some difficulties. here is a modified version ...
-1
votes
1answer
27 views

why dmesg output to log file is not working?

I am trying to output the dmesg to a log file so I can look at it through my txt editor, but i keep getting an error msg: dmesg > /Desktop/log.txt gives me this error: bash: /Desktop/dmesg.log: No ...
0
votes
1answer
30 views

Are there any really good bash scripting guide? [closed]

I really want to learn bash scripting, where should I research? I am pretty good at programming but I do not know how to program using bash
-1
votes
0answers
28 views

How can I send email with attachment xls file using shell script as application/xls mimetype without making the received file becoming unreadable

#!/bin/bash ATTACH1=file.xls SUBJECT="lucky day" FROM=me@domain.com TO=you@domain.com CC=them@domain.com MIME="Application/vnd.ms-excel" FILE=$ATTACH1 ...
1
vote
2answers
29 views

`tail` and append in oneliner

How could I tail and append a text in a file, in one line, in Bash? My failed attempt would be tail file.txt > file.txt && date >> file.txt
1
vote
1answer
29 views

Why can not the Bash script file run by shortcut get the content of a file?

I have a script that starts a new activity for hamster (activity tracker). This is my current script: ACTIVITY=`zenity --entry --title "Enter new activity name" --text "New activity name:"` hamster ...
0
votes
0answers
20 views

Need some advice with a script for anacron

I made a bash script and I made it by using gedit as sudo. Let's call it "script.sh". Then I made the script executable. I've already tested it. It does run, but with sudo. Inside the script I didn't ...
0
votes
1answer
39 views

Default environment for screen is /bin/sh when it should be /bin/bash?

I'm trying to invoke a program to run on startup in /etc/rc.local which runs two commands: Start a detatched screen using screen -dmS name Send a command to that screen using screen -S name -X ...
-2
votes
2answers
46 views

How to supply password through command while performing SSH login? [closed]

I want to perform SSH login to a machine by directly supplying password through the command line like the way we do for executing sudo commands as shown below: echo mypass | sudo -S sh -c 'echo ...
-1
votes
0answers
19 views

why cron is running my script in parallel mode

I am trying to run a script using cron. when I run it in normal way (./myscript) it is doing it in the right way. When I run it with cron (./myscript | at now) the instruction are not executed in ...
11
votes
6answers
2k views

What does export PATH=something:$PATH mean?

I am very new to Linux and I put the following command at the end of the file .profile under my home folder: export PATH="~/.composer/vendor/bin:$PATH" I know the issues of environment variables ...
0
votes
1answer
28 views

Why a folder needs a execute permission when I'm trying to execute a .sh? [duplicate]

I've got a folder that has 0600 chmod permission and this folder has a sh script. I'm trying to limit some permissions but I've realized that if the folder has not a execute permission, unless for ...
3
votes
0answers
42 views

Redirect 'complete' in bash functions and alias

tl;dr: Is there a way to use an existing auto completion function to also auto complete arguments to an alias or short function. Auto completion in bash is great but does not mix well with aliases ...
0
votes
1answer
76 views

Script in /etc/init.d/ does not run in Ubuntu 15.10

I have a script which simply echos current time and appends the output to a file. Below is the bash script. #!/bin/bash #Filename: /etc/init.d/bootlog #Bash script to record a timestamp. echo "Time: ...
-2
votes
0answers
27 views

In History command results i want when the command is used i.e., date and time,without using timestamping.How i get that? [duplicate]

In terminal, I search for history it shows last 1000+ used commands. But along with that I want to add Date and Time when it is used. Is it possible to add modifications to history command Other than ...
2
votes
1answer
19 views

Start a program after 45 mins of overall activity

hi I want to setup something like a smart alarm reminders, which will help to have a break after some intervals of activity. e.g. I want to know if the system can detect me, like if I am typing ...
0
votes
3answers
63 views

Ubuntu weird terminal mode

When using the terminal, instead of typing "exit", I accidentally typed "`xit" instead. Then the terminal entered a weird mode like this, and would't respond to anything I type:
0
votes
0answers
17 views

Profile.d and aliases. Why do the aliases not work? [duplicate]

I need to define some global aliases for my PC. I defined them in a file zzz.sh in the /etc/profile.d directory. It didn't work. Then I defined those aliases in /etc/bash.bashrc file. It did work as ...
0
votes
2answers
42 views

Find and Replace with Bash

I'm trying to replace some text with other text in a configuration file. I created a script with the sed command but I'm getting an error. Original Line: <property ...
0
votes
0answers
34 views

Shutter custom filename fails when called from script

I'm having some trouble with Shutter, I don't know if my shell or shutter is guilty of such behavior. I can call shutter from command line successfully : shutter -e -s -o '/tmp/screen_%NNN.png' ...
0
votes
0answers
17 views

Easiest way to automate this process?

I need to find a way to automate this process from my VPS. I want to be able to create a script which signs into a website using set POST data (straight forward) but then, visits another page after ...
0
votes
1answer
31 views

shell script to move a set up folders into one folder and timestamp it

I have a set of folders (let's assume at /home/20161, /home/20162, /home/20163) which have been timestamped already. at the end of the day, I'd like to collect all of them and move to a main ...
8
votes
4answers
432 views

Prevent all commands from being defined as an alias

Is there a way to prevent all commands from being defined as an alias? For example a user shouldn't be able to define rm or any other command (Ubuntu default commands) as an alias name.
3
votes
1answer
53 views

Script to copy files with desired name

I've got a problem i'm facing for 6-7 hours and i can't overcome it , that's why i'm asking for your help.I need to create a bash script that accesses a folder and renames all the files from it with a ...
1
vote
3answers
287 views

Somehow I created a nondeterministic sh script

I created the following script: #!bin/bash cat > Top10 <<EOF Linux Mint 17.2 Ubuntu 15.10 Debian GNU/Linux 8.2 Mageria 5 Fedora 23 openSUSE Leap 42.1 Arch Linux CentOS 7.2-1511 PCLinuxOS ...
1
vote
1answer
28 views

How to make silent backups when plugging in a USB disk and when using Back In Time

Actually, I already answered that question, though I don't know if the answer is a good one. So what do you think about this: Task: let the computer start a backup using Back In Time (BIT) as ...
6
votes
1answer
172 views

How to use timestamp option in ping

I noticed that there is a timestamp option -T in the ping help. But I don't know how to use it. I tried: ping www.google.com -T This is what I get: Invalid timestamp type What is the timestamp ...
2
votes
1answer
107 views

Installation of netbeans 8.1 from the .sh file in ubuntu 14.04

I have the installation file netbeans-8.1-linux.sh in the Others folder of Downloads. Now when I am using the command from the Netbeans official site to make the installer file executable i.e. chmod ...
-1
votes
0answers
16 views

convert a jpg file after being uploaded using inotifywait

First it is my first time writing a bash script so I apologize if this is trivial. I am trying to setup a watch so every time a jpg file is uploaded to a specific folder, it gets converted to webp ...
1
vote
0answers
14 views

Update apache/admin password in multpile folder

This is great work very well done. I have a problem too it is requested that you inform me how can do this. Let say i have folders named Folder1/apache/users/admin Folder2/apache/users/admin ...
0
votes
0answers
12 views

Detached process dies with terminal [duplicate]

I wrote a script to get around a problem with the volume indicator on my ubuntu mate 15.10 system (pulse audio sometimes doesn't start, not a clue why, but it will start after a try or two). I have a ...