Most Popular

1500 questions
102
votes
8 answers

Connecting to wifi network through command line

I am trying to connect to my WEP network just using the command-line (Linux). I run: sudo iwconfig wlan0 mode Managed essid 'my_network' key 'xx:xx:... hex key, 26 digits' Then I try to obtain an IP with sudo dhclient -v wlan0 or sudo dhclient…
Jayson Condor
  • 1,021
  • 2
  • 8
  • 3
102
votes
7 answers

Does LVM impact performance?

I have to migrate a few servers to Linux, and one important aspect that I need to evaluate is that my new host system must have elastic storage capacity. Naturally, doing some basic research, I came across LVM. Is there any performance penalty for…
Pablo
  • 2,485
  • 6
  • 27
  • 23
102
votes
5 answers

How do you make samba follow symlink outside the shared path

This is Ubuntu server 10.04 64 and samba 3.4.7. I have a shared directory /home/mit/share and another one /home/temp that I link into the shared one: ln -s /home/temp /home/mit/share/temp But on windows, after using internet, I cannot open S:/temp,…
mit
  • 1,413
  • 3
  • 12
  • 17
102
votes
8 answers

Using rsync to move (not copy) files between directories?

I have been using rsync to copy files for some time. My understanding is that rsync is faster than cp when some of the files to transfer are already in the destination directory, transferring only the incremental difference (i.e. the "deltas"). If…
Amelio Vazquez-Reina
  • 40,169
  • 77
  • 197
  • 294
102
votes
4 answers

What does "3>&1 1>&2 2>&3" do in a script?

I saw this line in a script: DEVICE=`dialog --inputbox "Festplatten-Laufzeit auslesen. Gebe Sie das gewünschte Device an: " 0 70 "" 3>&1 1>&2 2>&3` What is 3>&1 1>&2 2>&3 doing? I know that 1 = stdout and 2 = stderr, but what are the 3 and the &…
jsterr
  • 1,281
  • 4
  • 12
  • 12
102
votes
4 answers

Multiline shell script comments - how does this work?

Recently, I stumbled upon a multiline comment type I have never seen before - here is a script example: echo a # : aaa : ddd # echo b This seems to work, even vim syntax-highlights it. What is this style of commenting called and how to I find…
Wiesław Herr
  • 1,350
  • 2
  • 10
  • 10
102
votes
2 answers

List of terminal generated signals (eg Ctrl-C -> SIGINT)

Where can I find a complete list of the keyboard combinations which send signals in Linux? Eg: Ctrl+C - SIGINT Ctrl+\ - SIGQUIT
Tom Hale
  • 28,728
  • 32
  • 139
  • 229
102
votes
15 answers

GRUB starts in command line after reboot

I installed Linux Mint on my laptop along with a pre-installed Windows 10. When I turn on the computer, the normal GRUB menu appears most of the time: But after booting either Linux or Windows then rebooting, I GRUB starts in command line mode, as…
Antoine Aubry
  • 1,081
  • 2
  • 8
  • 10
102
votes
3 answers

Why can't a normal user `chown` a file?

Why is the chown command root-only? Why can't non-root users use chown to give away files they own?
phleg
  • 1,021
  • 2
  • 7
  • 4
102
votes
3 answers

Install PostgreSQL client (psql) only on CentOS

Simple question, but no resources found about this. Is there any way to install only a PostgreSQL client, the terminal-based one, psql, on a CentOS7 system, without installing the complete PostgreSQL server? There is no dedicated postgresql-client…
102
votes
5 answers

How to find out if a system uses SysV, Upstart or Systemd initsystem

Is there a simple way to find out which initsystem is being used e.g by a recent Debian wheezy or Fedora system? I'm aware that Fedora 21 uses systemd initsystem but that is because I read that and because all relevant scripts/symlinks are stored…
Valentin Bajrami
  • 9,244
  • 3
  • 25
  • 38
102
votes
10 answers

How to mount a device in Linux?

I read some resources about the mount command for mounting devices on Linux, but none of them is clear enough (at least for me). On the whole this what most guides state: $ mount (lists all currently mounted devices) $…
its_me
  • 13,709
  • 23
  • 54
  • 52
102
votes
7 answers

List ports a process PID is listening on (preferably using iproute2 tools)?

I'm looking to list all ports a PID is currently listening on. How would you recommend I get this kind of data about a process?
ThorSummoner
  • 4,312
  • 6
  • 30
  • 47
102
votes
4 answers

The ls command is not working for a directory with a huge number of files

I had a directory which had around 5 million files. When I tried to run the ls command from inside this directory, my system consumed a huge amount of memory and it hung after sometime. Is there an efficient way to list the files other than using…
Ramesh
  • 38,687
  • 43
  • 140
  • 215
102
votes
6 answers

As root, how can I list the crontabs for all users?

I have a script being run automatically that I can't find in the crontab for the expected users, so I'd like to search all users' crontabs for it. Essentially I want to run a crontab -l for all users.
Highly Irregular
  • 2,455
  • 6
  • 23
  • 24