Most Popular
1500 questions
160
votes
11 answers
How can I run a cron command with existing environmental variables?
How can I run a cron command with existing environmental variables?
If I am at a shell prompt I can type echo $ORACLE_HOME and get a path. This is one of my environmental variables that gets set in my ~/.profile. However, it seems that ~/.profile…
cwd
- 44,479
- 71
- 146
- 167
159
votes
10 answers
How to remove an audio track from an mp4 video file?
I have an mp4 video file with multiple audio tracks. I would like to strip away the rest of the tracks and keep just one. How do I do this?
tshepang
- 64,472
- 86
- 223
- 290
159
votes
6 answers
How can I communicate with a Unix domain socket via the shell on Debian Squeeze?
I’m running a Debian Squeeze web server. I’ve installed memcached on it, and configured memcached to listen on a Unix domain socket (at /tmp/memcached.sock), as it only needs to receive messages from the website, which lives on the same server.
It…
Paul D. Waite
- 3,527
- 5
- 21
- 21
159
votes
3 answers
Download using wget to a different directory than current directory
I need to use wget to download a file to the directory /var/cache/foobar/ (so, as an example, if I download stackexchange-site-list.txt, it'd be downloaded to /var/cache/foobar/stackexchange-site-list.txt)
Is this possible? curl would also be an…
jrg
- 4,206
- 3
- 20
- 16
159
votes
3 answers
What are pseudo terminals (pty/tty)?
This might be really basic question but I want to understand it thoroughly.
What is a pseudo terminal? (tty/pty)
Why do we need them? How they got introduced and what was the need for it?
Are they outdated? Do we not need them anymore? Is there…
hari
- 2,400
- 4
- 21
- 22
159
votes
8 answers
Use scp to transfer a file from local directory X to remote directory Y
I took a look around at other questions here and at various "scp usage" tutorials on Internet, but I can't sort out what's wrong.
I'm using Linux Mint and I'm trying to figure out how scp works.
I've a file file.ext (on my computer) in directory…
dragonmnl
- 2,169
- 3
- 19
- 26
158
votes
4 answers
locate vs find: usage, pros and cons of each other
In Linux and Unix systems there are two common search commands: locate and find.
What are the pros and cons of each? When one have benefits over the other?
m0nhawk
- 2,628
- 3
- 20
- 28
158
votes
3 answers
Trying to sort on two fields, second then first
I am trying to sort on multiple columns. The results are not as expected.
Here's my data (people.txt):
Simon Strange 62
Pete Brown 37
Mark Brown 46
Stefan Heinz 52
Tony Bedford 50
John Strange 51
Fred Bloggs 22
James Bedford 21
Emily Bedford 18
Ana…
Harry
- 1,843
- 3
- 13
- 8
158
votes
4 answers
How to add repository from shell in Debian?
In Ubuntu one can add a repository via following command -
sudo add-apt-repository ppa:yannubuntu/boot-repair
As Ubuntu is based on Debian code base, I was expecting that the same would work in Debian too, but it doesn't.
What is the reason for…
Kshitiz Sharma
- 8,585
- 21
- 59
- 75
158
votes
5 answers
What is a Superblock, Inode, Dentry and a File?
From the article Anatomy of the Linux file system by M. Tim Jones, I read that Linux views all the file systems from the perspective of a common set of objects and these objects are superblock, inode, dentry and file. Even though the rest of the…
Navaneeth Sen
- 9,369
- 17
- 58
- 65
158
votes
6 answers
How to merge all (text) files in a directory into one?
I've got 14 files all being parts of one text. I'd like to merge them into one. How to do that?
Ivan
- 17,368
- 35
- 93
- 118
158
votes
5 answers
Download only format mp4 on youtube-dl
How can I use the download-dl to download video through url playlist only format mp4 instead format .mkv or .webm?
I use this command to download videos: youtube-dl -itcv --yes-playlist https://www.youtube.com/playlist?list=....
The result this…
Edgar Oliveira
- 1,941
- 3
- 11
- 12
158
votes
11 answers
How to open rar file in linux?
I have a file with .rar extension, ex: foo.rar
I want to extract content from that file, how do I extract it?
shas
- 2,578
- 4
- 17
- 31
158
votes
1 answer
Understanding the output of --info=progress2 from rsync
If I run rsync with --info=progress2, I get an output like
105.45M 13% 602.83kB/s 0:02:50 (xfr#495, ir-chk=1020/3825)
But what do the single numbers mean? I haven't found a matching entry in the man page.
The first number seems to be the…
muffel
- 2,678
- 4
- 23
- 21
158
votes
4 answers
How to make log-rotate change take effect
I followed this link to change log-rotate configuration for RHEL 6
After I made the change to config file, what should I do to let this take effect?
BufBills
- 3,035
- 7
- 22
- 20