Questions about using the command-line interface (CLI).

learn more… | top users | synonyms (6)

1
vote
1answer
32 views

Hot to get the message ID when sending email via command line?

I am trying to send a mail via simple mail command on the command line using this piece of code: $ echo "foo" | mail -s "Hello World" -t "someone@example.com" That’s working fine. My question is ...
1
vote
1answer
229 views

Why isn't Composer updated?

I'm using Ubuntu 16.04 LTS amd64. I have installed LAMP (php5.6, apache2, mysql) and Composer. I downloaded my laravel project from github. I would like to update Composer to start the local server ...
2
votes
2answers
47 views

How to extract certain strings from hyperlink and create a folder with same string in bash?

I have a text file(web.txt) containing a long list of urls with this pattern http://www.example.com/ab1.htm http://www.example.com/ab2.htm http://www.example.com/bc1.htm http://www.example.com/qw3....
2
votes
2answers
401 views

How can I switch between 12 hour and 24 hour format in command line?

I am in a learning phase. I could not find the command to change my time format from 12 hour to 24 hour. Can anyone please help me with this? Thank you!!
1
vote
0answers
27 views

Ubuntu starts up in terminal after updating to newer version

I have searched the internet for hours, and although I have found some similar problems and extracted some information from them, I still have the same problem. A few days ago I decided to update ...
1
vote
1answer
23 views

Recovery from Scalpel didn't show any recovered file

I have deleted some of my .odt files by mistake last night (near about 10 hours ago), and I had to recover those files as those were really important to me. I used scalepel for this purpose in which I ...
2
votes
1answer
249 views

mkdir says that file exists when it doesn't [duplicate]

When I run mkdir ~/.ipython/extensions/ I get mkdir: cannot create directory ‘/home/droudy/.ipython/extensions/’: File exists However when I navigate to /home/droudy, there is no .ipython ...
0
votes
1answer
17 views

Navigating/Exiting command line configuration screens from bash script

I'm new to bash scripting and making a initial setup script that I can run to quickly set up a new install. When installing ddclient sudo apt-get install ddclient -y it opens a command line ...
1
vote
1answer
39 views

Using source command to replace bash string with field array

I've programmed in other languages but bash and unix in general are very new to me. I think a bash wizard might see an obvious solution, using the source command to read in a settings file - and ...
3
votes
4answers
129 views

Concatenate strings stored in variables side by side

I have two variables which contain a set of strings. I need to concatenate the results of these variables to appear side by side. Variable a has: t t t Variable b has: xyz pqr stu I need to get ...
23
votes
2answers
1k views

What does “--” mean in terminal commands?

I have seen many tutorials that use a -- after commands. Something like this: command -- What does this -- mean?
1
vote
2answers
53 views

Command Prompt like Windows [duplicate]

Does Ubuntu have a command prompt like Windows and if so where do I find it to display the directory tree
1
vote
2answers
31 views

Save part of a terminal output

I am using Ubuntu to get the output from a BLE device, and in the terminal I get a continuous stream of values. The only problem is that they are preceded by a useless string (I'm reading ...
2
votes
2answers
22 views

Problems with floating arithmetic in bash

I have code in bash: a=$(cat "tempf.out") Where tempf.out is smth like this: -432.4319347412 I want to multyiply it by 2, so, I write: result=$(expr $a*2) But I get this: *232.4319347412 ...
1
vote
0answers
19 views

How To Use Cloc On Ubuntu [duplicate]

I'm a Ubuntu novice and I'm trying to figure out how to use cloc to count lines of code in a directory. https://github.com/AlDanial/cloc I think I got it installed correctly using: sudo apt-get ...
3
votes
2answers
70 views

How to determine, from the command line, whether rhythmbox is playing?

rhythmbox-client --print-playing tells me the name of a song, regardless of whether it is actually playing. I simply need to know whether or not sound is currently being generated by rhythmbox (so ...
1
vote
2answers
44 views

Why terminal writes me that Sub-process /usr/bin/dpkg returned an error code?

I have tried to remove mysql. I am using ubuntu 16.04 LTS amd64 and python 3.5.1+ . The terminal wrote me the error shown below. What's the problem? What did I do wrong? heartprogrammer@...
4
votes
1answer
61 views

Terminal only shows up as a black window

I'm running Ubuntu 15.10 on a Lenovo Ideapad, and whenever I try to open a terminal window, only a black box appears, and the menus have thick black borders and the nofification box is also black.
1
vote
1answer
45 views

Strange option in xfce4 menu

I've installed a java program from a government website. I uninstalled it again, but it left a menu icon in my main menu after uninstall. I tried to edit my menu by Menu Editor but got This ...
1
vote
1answer
86 views

How to prevent execution of “sudo rm -rf --no-preserve-root / ” command? [duplicate]

After going through this question I'm quite scared! It's not that I don't want to use sudo rm command, but I want to inhibit the execution of the sudo rm -rf --no-preserve-root / command. If this ...
0
votes
2answers
21 views

Changing Default Size of Xfce4 Terminal

How do I change the default window size of the Xfce4 terminal emulator? Going to Edit > Preferences on the menu does not allow me to change the window size.
0
votes
0answers
20 views

16.04 - Connecting through RDP with a VM over terminal

I have set up VirtualBox-VM with the terminal and now I want to connect with the VM through RDP over the terminal. Is there a command which makes this possible? The VM is running on my locale computer....
0
votes
0answers
116 views

Selenium(python) not working -Ubuntu 16.04(LTS)

I am learning selenium with python. Just to test whether selenium is running,I ran a sample program given on the site. import unittest from selenium import webdriver from selenium.webdriver.common....
0
votes
0answers
21 views

dev/pts doesn't show in ls command

I'm fairly new to ubuntu, I'm running it in a virtual machine online on an application called cloud 9. I've run the commands sudo -i, followed by cd \, cd dev, and ls. When I ran ls it gave me: ...
3
votes
2answers
359 views

Difference between rm executable >>dev/null and rm executable

What is the difference between rm executable and rm executable >>dev/null I had the later statement in a Makefile and changed it to the first one. I had the impression that nothing changed....
1
vote
1answer
51 views

Terminal windows open with [“#Curl: command not found”]

This seems to be related to my ~/.bash_aliases file. The message only appears when I open a new terminal window and when I try source ~/.bash_aliases. I've made sure CURL and all related libraries are ...
0
votes
1answer
41 views

How to check memory type and speed? [duplicate]

I want to get more RAM for my computer, and I understand that to get the right type of RAM I have to know the memory type and speed (minimum and maximum as far as I understand). So how do I find these ...
0
votes
1answer
53 views

Problem installing pip: pip command not found

Having problems installing pip and not sure why can someone help me find out why the pip is returning "-bash: pip: command not found"? $ echo $PATH /Library/Frameworks/Python.framework/Versions/3.5/...
6
votes
4answers
1k views

Why aren't there any man pages for disown or other Ubuntu commands?

phatez@phatez-laptop:~$ help GNU bash, version 4.3.46(1)-release (x86_64-pc-linux-gnu) These shell commands are defined internally. Type `help' to see this list. Type `help name' to find out more ...
1
vote
1answer
26 views

Removing ghostscript alias

I'm using zsh which uses gs as an alias for git status. But on Ubuntu, gs is an alias for ghostscript. I tried uninstalling ghostscript, but then I get this instead: The program 'gs' is currently not ...
2
votes
1answer
53 views

How to restore a broken Deja Dup backup manually

For various reasons (possibly this bug) a Deja Dup backup I made failed. I have been following this guide to restore my backup by hand. The steps have been: In the folder containing the backups run: ...
0
votes
0answers
16 views

Sipsak error: didn't received '200 OK' on register

How can I use sipsak to simulate a call on the CLI between SIP accounts? I can only run a local test using Asterisk successfully and would like to run a similar test or simulation using linphone, ...
-5
votes
0answers
45 views

Using the Top command with ps and kill [duplicate]

For my Computing Controlled Assessment I am looking into some of the basic commands for the Linux OS Debian. For the final question I have to write a short essay on using the top command along with ps ...
1
vote
1answer
19 views

How to run a perl script with arguments

I'm pretty new with Ubuntu and Linux and I need some help in order ton run a perl script. It may sound silly, but I need to run a perl (.pl) file, using a specific argument. The key is that when I run ...
3
votes
1answer
96 views

No output from service start/stop/restart command

I just installed Ubuntu 16.04 LTS and found that when I run usr@server:~$ sudo service <servicename> restart usr@server:~$ The service is restarted (I can see the status with service <...
2
votes
1answer
55 views

How to set cursor position with command/script?

I have a script which resets some things, and at the end of it I need it to set the cursor to certain coordinates, either to a custom set or to the centre of the screen (where it is reset to by ...
3
votes
2answers
95 views

What is the difference between 'kill' and the 'k' option within 'top' in Linux?

I found out from http://www.tecmint.com/12-top-command-examples-in-linux/ (it's number 7 on that webpage) that you can use the k option to terminate a program. Would that work in the same way as ...
-1
votes
1answer
21 views

Using Terminal In 12.04 [duplicate]

When I try to use terminal, I put in a command and then it asks for my password. I type my password and nothing comes up on the screen. Help?
0
votes
1answer
42 views

Create and remove directory using Terminal in Ubuntu 15.10 [duplicate]

I created a directory using the following command mkdir TEST. Now I am trying to remove it using rm TEST and rm TEST/ but it is showing the following error: cannot remove ‘TEST’: Is a directory ...
0
votes
0answers
16 views

Error installing VLC through Terminal GPG error [duplicate]

I tried Installing VLC media player in ubuntu 14.04 using information from page VLC Player installation ubuntu 14.04 Then, I ran: sudo apt-get update Terminal Returned: Reading package lists... ...
1
vote
1answer
66 views

Fix Package Dependencies?

I'm trying to install build-essential using sudo apt-get install build-essential like I'm supposed to. It returns with the error The following packages have unmet dependencies: build ...
2
votes
1answer
30 views

TAR a folder with exlcusions

I'm trying to create a compressed TAR file. I have a disk that I am going to destroy and would like to take one last snapshot of the /users folder but don't want the users .m4v .m4a and .mp3 files ...
3
votes
2answers
99 views

Can't permanently export PATH variable with custom path

I've installed composer and the laravel installer which is now located unter ~/.config/composer/vendor/bin. I want to use laravel directly as a command from anywhere, so I tried to add the directory ...
0
votes
2answers
77 views

How to stop `clear` from clearing scrollback buffer

Initially I thought Unlimited scrolling was not working with the terminal application on 16.04. I have the option "limit scrollback to" unchecked. Some times it scrolls back some times it does not. ...
3
votes
3answers
50 views

folder not shown when being created by command line

I have an issue when I am creating a folder by command line. I create it by typing: mkdir TEST and it does not appear on the graphical desktop view. But if I type the command "ls" in the Terminal I ...
1
vote
2answers
34 views

how to delete particular number or letter before an symbols (|) using grep command

I have N number of sequence in a file like this >668|CAX10446 conserved hypothetical protein MSIRGVGGNGNSRIPSHNGDGSNRRSQNTKNKVEDRVRSLYSSRSNENRESPYAVVDVSSMIESTPTSGE ...
9
votes
3answers
610 views

Simulate action of mv command

I'm moving some files around, and I want to make sure that the mv command I've typed is correct before I go ahead and run it. If I was using apt-get, I could use the -s flag to perform a simulation ...
0
votes
1answer
36 views

Cron - Check if enabled on boot

I have a script and configuration file. Configuration file contains information about if script will run or not (enabled or disabled). If enabled, script must run in predetermined intervals. I ...
0
votes
0answers
28 views

PLINK execution of: echo -e “%UNIXPW%\n” ^| sudo -S nginx -t -c, works OK on one, fails on another

My batch file runs a PLINK script in Ubuntu 16.04 LTS, which works correctly on my own VM/Ubuntu. The same command fails in when run on a different VM/ubuntu 16.04 LTS. echo -e "%UNIXPW%\n" ^| sudo -...
0
votes
1answer
29 views

Get key name from keycode

I am writing a shell script that uses xinput, and I would like to get a human-readable description of what the user has typed using the keycode from xinput. For example, A generates 38. Ctrl is 37. ...