The command-line is the interactive interface to your shell.

learn more… | top users | synonyms (1)

1
vote
0answers
66 views

What is the meaning of the string **/* when used with grep?

I came across this picture (below), obviously it is a pun or some kind of allusion incorporating command-line expressions. Frankly speaking I do not understand anything of it except for grep -n. ...
1
vote
2answers
111 views

for loop when matching both front and back of file name

I'm trying to set up a for loop to run a process on pairs of files. The names of the files look like this 36_002_CGATGT_L001_R1_005.fastq.gz 36_002_CGATGT_L001_R2_005.fastq.gz ...
0
votes
1answer
42 views

What is the meaning of (^| )ABC( |$) as an extended REGEX ?

I came here across the command grep -E '(^| )ABC( |$)' file1 I am confused how to interpret the regular expression therein, because I know the ^ and $ character as beginning and end signifier, but in ...
1
vote
1answer
33 views

How do I control output after executing a command?

.. Script Run Complete. You have new mail in /var/spool/mail/<user-name> -bash-3.2$ I have seen the above message most the times on my prompt, probably while it's idle or as soon as script ...
1
vote
0answers
21 views

mkvmerge Backward Spliting not supported why?

I tried this:- mkvmerge -o new_file.ogg --split parts:0s-104s,+94s-208s,+8s-12s,+312s-410s,+17s-21s 500.ogg Thrown this error: "The start time must be bigger than or equal to the previous part's ...
1
vote
3answers
121 views

What is the meaning of ls -d ?

I entered the man page of ls, the entry for the -d option is as follows: -d, --directory list directory entries instead of contents, and do not derefer‐ ence ...
0
votes
1answer
40 views

tail-ing a filename that is a date [duplicate]

I am creating a logfile from kermit named the current date (which is in the format of DD MMM YYYY - which can not be changed AFAIK), and using the file name as today's date. I then have a Bash script ...
1
vote
1answer
47 views

Replace case-insensitive string in all folder files

I'm trying to replace a string with another in all files in dir. Trying to use this command sed 's/foo/bar/' * But it replaces foo and not fOo or Foo and others. how to find "foo" ...
0
votes
2answers
62 views

Why can't I kill the shell using the PID obtained from the $$ special variable? [duplicate]

After I have learned that the $$ special variable holds the process number of the shell, I tried too kill the shell by simply: kill , however this did not work, I also tried some variations, but them ...
7
votes
7answers
196 views

What is the purpose of having two variables ($@,$*) to transmit the arguments of a command into a script? [duplicate]

I have read of the special variables used in a script $@ and $*. As far as I understand, the arguments used while executing the script are stored into two special variables, once all arguments into $@ ...
1
vote
1answer
52 views

No such directory after creating it

I'm taking a basic Unix course and right now we're learning terminal. My directions are create a directory called company and subdirectories called sales, accounting and marketing. So I did that. ...
0
votes
1answer
108 views

SIPp “hello world” message to Asterisk

How do I run diagnostics against Asterisk? Asterisk is running on tleilax; and doge is on the same network (My network topology isn't optimal). Specifically, I want to do something like: sipp ...
1
vote
1answer
108 views

Changing themes and hot-corner settings from command-line

I want to change the elementary tweak themes and hot-corner settings on my Elementary Luna (built on Ubuntu 12.04 "Precise") from the commandline. With what command can I do this? I know how to make ...
1
vote
1answer
134 views

Linux commands for kids [closed]

My youngest daughter (6) is fascinated with the sl and gti commands. She even learned to combine them with ; and when the time comes to teach her about return values I'll show her how sl && ...
1
vote
1answer
19 views

How to display metainformation for different kinds of time of a file ?

As far as I know each name within a path, e.g. /name1/name2/name3, is allocated to one inode. This inode is a collection of meta information for each name (file or directory). Some of these ...
-1
votes
1answer
76 views

How to install stardict from a tar.gz manually ?

I have downloaded stardict-2.0.0-pre2.tar.gz and applied the extraction on it by writing: tar xzvf stardict-2.0.0-pre2.tar.gz , thereupon a new folder was created with the following content: From ...
11
votes
5answers
899 views

How do I get the size of a directory on the command line?

I tried to obtain the size of a folder (containing folders and sub folders) by using the ls command with option l. It seems to work for files (ls -l file name), but if I try to get the size of a ...
3
votes
3answers
66 views

how to remove accidentally created '~' and '..'

I'm using wget to download some webpages and I used the -P option without knowing that it wouldn't expend .. or ~. So I found I've created them after running the program. Now the problem is, how do I ...
2
votes
0answers
53 views

How to display entire subject line in `mail`?

There are two messages in /var/mail/test. mail Mail version 8.1.2 01/15/2001. Type ? for help. "/var/mail/test": 2 messages 2 new >N 1 test@test Tue Feb 17 15:07 18/628 *** SECURITY ...
-1
votes
2answers
110 views

How to create a new partitioning table on SD card from the command line ? [closed]

I have tried to mount a SD card on Linux Mint, I have found the right device file and tried: mount -t vfat /dev/sdb /mnt/zauberportal ,but it failed and I tried some variations like different types of ...
2
votes
2answers
240 views

Using find to list all files under certain directory

I'm trying to use a single line command that will find every directory (or sub-directory) named bin and will then print a list of all the files under it, but will not also list the directory names ...
0
votes
3answers
249 views

Simple TCP server listening on a port but not returning SYN-ACK

I am looking for a command-line TCP server (preferably a one-liner), that will listen on a specified port and when received SYN, it will not respond with SYN-ACK as usual TCP servers do. The purpose ...
0
votes
2answers
46 views

Simple http server from the command line that will always cause a timeout

Regarding the question Simple command line http server I would like to know, what is the simplest method for creating a http server listening on a specified port that will always cause timeout (it ...
0
votes
1answer
62 views

How to find with grep lines that end in a certain string?

I know that to find a REGEX that ends in a certain string I have to write "string$". Although I tried the following variations of grep : cat foo | grep "string$", cat foo | egrep "string$", grep -E ...
1
vote
2answers
96 views

Copy files to multiple computers over LAN

Good day, I am pretty new to Unix and I need to do this simple task. I have a few files, let's name them file01, file02, file03 etc. and I need to copy each of them to one computer from a list. The ...
0
votes
1answer
150 views

What does the option -C achieve in ls output?

In the man pages it says: -C list entries by columns However, I really cannot notice any difference between the output of ls or ls -C, could someone explain this to me?
1
vote
0answers
31 views

How much arguments can I pass to command? [duplicate]

Is there any limit of arguments that could be passed to C/C++, Python, Bash etc. program? Practical usage: pass bitmap data from/to C++ to/from Python program via arguments.
0
votes
2answers
73 views

What regular expression in grep searches for strings of three same letters in a row?

I have a text file and I am using the grep command with a regular expression to get only the lines which contain three same successive letters, e.g.: aaa bbb ccc ddd What regular expression do I ...
12
votes
4answers
923 views

What is the meaning of IFS=$'\n' in bash scripting ?

at the beginning of a shell script program in the bash is the following line: IFS=$'\n' What is the meaning behind this collection of symbols ?
-1
votes
2answers
91 views

How do I get a list of all directories and files with absolute paths each line ?

Using ls -R / i get every file and directory listed that exists, but not in the desired format. What do I need to write on the command line in order to get a list in such a format, that every line ...
5
votes
3answers
418 views

How do I move all the files with the same name scattered through the file system into one folder?

I have a file system tree and on different locations within it are files with the same name. I tried the following command on the command line: find / -name "HAHA" -exec mv {} /home \; It only ...
6
votes
3answers
319 views

How do I use the regular pattern operator {m,n} in grep?

I have a text file, from which I need to select only those lines, which include the string "tt". So I tried this on the command line: grep "t{2}" textfile Allthough I know the textfile contains ...
0
votes
1answer
119 views

Command to to restart Pantheon files manager (elemenaryOS)?

After editing context menu entries (by editing files in /usr/share/contractor) I have to restart the file manager to see the changes. How to restart Pantheon Files with a command so that I don't have ...
1
vote
1answer
25 views

How do i start a sound file without displaying the window of the player ?

Whenever I type xdg-open filename or vlc filename, a window opens and start playing the filename. How can I achieve to play the sound file without displaying a corresponding window in the command line ...
1
vote
0answers
34 views

How can I get my Linux distribution name and version using the command line ? [duplicate]

I have Linux Mint Version 7.1 Rebecca. What do I need to write in the command line in order to find this information. I tried uname -a , but I got informations about my computer name, Kernel Version ...
0
votes
1answer
23 views

what do i need to do additionally to start X in order to not end in a black screen?

From the xfce desktop environment in Linux Mint, I pressed Ctrl + Alt + Fn in order to get into a virtual terminal, then I stopped the mdm display manager with killall mdm. So far it worked, but once ...
0
votes
1answer
333 views

command to clean up old log files

I was trying to automate some auto cleaning of my Ubuntu System, with Cron Jobs I tryed to simplify this: sudo find /var/log -type f -name "*.1.gz" -delete sudo find /var/log -type f -name "*.2.gz" ...
0
votes
2answers
81 views

what are considered old and powerfull commands? [closed]

I came across the terms awk and sed, awk goes once through all lines and performs a task whenever a line meets a certain condition, sed can manipulate a stream of input before it goes further to the ...
2
votes
0answers
54 views

Show connected printers in CUPS

Is there a way to list the available/connected printers in CUPS using the command line or better yet using the CUPS API ? I already tried lpstat -a but it only lists the installed printers and not ...
0
votes
0answers
48 views

How do i log into a virtual terminal ?

I do not know what a virtual terminal is, but i have to enter one, in order to switch off the display manager in a fashion that allows me to type next a command in the virtual terminal that starts the ...
0
votes
1answer
47 views

what is the difference betwwen starting a command with nohup and &? [duplicate]

nohub and & seem to have a similar effect on the surface, they both start processes without occupying the shell from which they have been started, how do they differ on a deeper level?
0
votes
0answers
20 views

How can i enter the sudo X command after having killed the mdm display manager?

I was told, in order to just start the x window system, i have to input at the command line: sudo killall mdm. After having done so, my window freezes and i have no further controll, my only option so ...
2
votes
1answer
57 views

how to start into the x window server from linux mint ? [closed]

what do i have to do in the terminal in order to switch all the frontends of the xserver off, just to have the x window system running without any window manager or desktop environment?
0
votes
2answers
40 views

How to match multiple lines starting with a TAB, and the line before the 1st one in a group?

I've got some third party log files I'm trying to pull errors out of on the command line. The logs look like this: time=1 time=2 time=3 at com.test.com.... at com.test.com.... at ...
2
votes
1answer
127 views

Debian Linux: Start/run application/process in another virtual terminal

You'll have to bare with my my Linux terminology is pretty bad. When I say virtual terminal I'm talking about when you press ctrl+alt+ a function key (F1-F12). I think they are called virtual ...
2
votes
3answers
141 views

How to insert bash variables in awk?

How to insert bash variables in awk (for example i need to do in in some for loop - like this: in first iteration use awk to search string by first column, next by second column and so on with using ...
0
votes
0answers
75 views

Is there a way to find the uptime of a network card in unix?

Some of the information i am requesting can be gleaned from /var/log/syslog , e.g: grep wlan /var/log/syslog But the usefulness of that information also depends on how you are network connecting; ...
1
vote
2answers
324 views

Perform multiple commands on one line

There are two steps, that I would like to be run on one line: twinkle -c then call sip:in06khattab@sip.linphone.org Here is the output: I wanted to perform these two steps on one line, I ...
2
votes
1answer
138 views

Unix sort by multiple columns

I have trouble understanding unix sort. Consider the following file (tab separated) aa ~ a1 aa B b A b ~ e bb B bb ~ B When calling: cat tmp2 | sort -t $'\t' -k1,2 I get aa ~ a1 aa B ...
0
votes
1answer
25 views

Coordinates X237595Y81600 to X2375Y8160

I have create a gerber file and it has lines inside which look like this: X90095Y15350 X100095Y15350 X110095Y15350 X120095Y15350 X120095Y25350 X110095Y25350 X100095Y25350 X90095Y25350 X80095Y25350 ...