Most Popular
1500 questions
87
votes
5 answers
What is the difference between 'nobootwait' and 'nofail' in fstab?
In this question I asked how to prevent a media failure from halting the system boot process. However, I got two suggestions for /etc/fstab options
nobootwait
nofail
What is the difference between the two?
Evan Carroll
- 28,578
- 45
- 164
- 290
87
votes
3 answers
What is the bash shortcut to change to the previous directory?
Sadly, I only learned about this last year by stumbling upon it randomly on the internet. I use it so infrequently that I always forget what it is by the time I need it again.
How do you change to your previous directory?
hobodave
- 1,173
- 1
- 7
- 10
87
votes
3 answers
Shell: how to go to the beginning of line when you are inside a screen?
I am inside a screen (screen -Ra). I have a long command, and I am at the end. Instead of keeping the left arrow, how can you go to the beginning of the line?
CTRL-A works when I am in a normal window, but when I am inside a screen pressing CTRL-A…
user11498
- 2,421
- 4
- 22
- 25
87
votes
5 answers
Refresh env variables after editing bashrc file
I frequently edited the .bashrc file to export new environment variables.
Rather than close the console and start a new one to refresh the env variables, is there a convenient way to refresh?
xiaohan2012
- 1,655
- 3
- 14
- 24
87
votes
11 answers
Is it good to make a separate partition for /boot?
I've seen some people make a separate partition for /boot. What is the benefit of doing this? What problems might I encounter in the future by doing this?
Also, except for /home and /boot, which partitions can be separated? Is it recommended?
Am1rr3zA
- 1,555
- 4
- 16
- 15
87
votes
4 answers
How to close (kill) ssh ControlMaster connections manually
With the following .ssh/config configuration:
ControlMaster auto
ControlPath /tmp/ssh_mux_%h_%p_%r
ControlPersist 4h
How to close the persisting connection before the 4 hours?
I know you can make new connections, but how to close them (all)?
Maybe…
Paolo
- 1,495
- 2
- 13
- 8
87
votes
2 answers
Nslookup: command not found error on RHEL/CentOS 7
During linux installation I selected "minimal" option:
When I went to run the nslookup command to look up an IP address I got the error message nslookup: command not found as shown in the example below.
$ nslookup www.google.com
bash: nslookup:…
Anthony Ananich
- 7,234
- 5
- 31
- 45
87
votes
4 answers
How can I echo dollar signs?
For example, $PATH and $HOME
When i type echo $PATH it returns my $PATH, but i want to echo the word $PATH and not what the actual variable stands for, echo "$PATH" doesn't work either.
DisplayName
- 11,468
- 20
- 73
- 115
87
votes
4 answers
Recursive grep vs find / -type f -exec grep {} \; Which is more efficient/faster?
Which is more efficient for finding which files in an entire filesystem contain a string: recursive grep or find with grep in an exec statement? I assume find would be more efficient because you can at least do some filtering if you know the file…
Gregg Leventhal
- 7,480
- 19
- 65
- 100
87
votes
4 answers
How do I update GRUB in Arch Linux
In Ubuntu, we use this command to update GRUB:
# update-grub
But how do I update GRUB version 2.00 in Arch Linux?
Hamed Kamrava
- 6,678
- 12
- 35
- 47
86
votes
3 answers
How do the internals of sudo work?
How does sudo work internally? How is it possible that it can become root without having the root password, unlike su? What syscalls, etc. are involved in the process? Is it not a gaping security hole in Linux (e.g. why couldn't I compile a…
strugee
- 14,723
- 17
- 73
- 119
86
votes
2 answers
Replacing string based on line number
I have a situation where i want to replace a particular string in many files
Replace a string AAA with another string BBB but there are lot of strings starting with AAA or ending in AAA ,and i want to replace only one on line 34 and keep others…
krypto
- 961
- 1
- 6
- 5
86
votes
6 answers
How to loop over the lines of a file?
Say I have this file:
hello
world
hello world
This program
#!/bin/bash
for i in $(cat $1); do
echo "tester: $i"
done
outputs
tester: hello
tester: world
tester: hello
tester: world
I'd like to have the for iterate over each line individually…
Tobias Kienzler
- 9,184
- 13
- 65
- 106
86
votes
2 answers
Why has Raspbian apparently been renamed into "Raspberry Pi OS"?
I was making some routine checks just now and realized this:
Raspberry Pi OS (previously called Raspbian)
Source: Raspberry Pi OS
I found no mention of this in their blog, nor on the Wikipedia page. Why change such a good name as "Raspbian" into…
Rithy
- 691
- 5
- 4
86
votes
7 answers
How to view a TTF font file?
Is there an application to simply preview a font from a TTF file without installing it?
Ivan
- 17,368
- 35
- 93
- 118