Linux refers to the family of Unix-like computer operating systems using the Linux kernel. If your question is about a certain distribution only, use a more specific tag.

learn more… | top users | synonyms

37
votes
2answers
20k views

Why is “/dev/rdisk” about 20 times faster than “/dev/disk” in Mac OS X

According to the rasbery pi documentation, You can load your OS to a flash card with either /dev/disk or /dev/rdisk. rdisk stands for raw disk. /dev/disk is a block level device, why would rdisk ...
37
votes
2answers
96k views

Linux - Mount device with specific user rights

How can I mount a device with specific user rights on start up? I still have some problems figuring it out. I would like to mount the divide with uid=1000 and gid=1000. My current entry to the ...
37
votes
3answers
19k views

How do I execute multiple commands when using find?

I'm trying to run multiple commands on things I have found, how can I achieve this? find . -exec cmd1; cmd2 does not seem to work; it instead runs cmd2 after cmd1 has been executed on every file.
36
votes
6answers
46k views

Copy entire file system hierarchy from one drive to another

I would like to copy the entire file system hierarchy from one drive to another..i.e contents of each directory as well as regular files in Linux platform. Would be gratefull to know the best way to ...
36
votes
8answers
128k views

How to upload one file by FTP from command line?

I need to upload a single file to FTP server from Ubuntu. This operation should be done in a script (in non-interactive mode). What is the right syntax for ftp? I'm trying this, to no avail: $ ftp ...
36
votes
4answers
38k views

What does the dot mean at the end of `-rw-r--r--`? How do you set it with `chmod`?

I see that some of the files in my directories under Linux have a . at the end of the permissions listing. What does the dot mean at the end of -rw-r--r--? How do you set it with chmod?
36
votes
5answers
17k views

How can a linux kernel be so small?

An ordinary stable 3* kernel is about 70 mb now. But there are little linux distributions of 30-10 mb with software and other stuff running out of the box. How can the linux kernel be so small in ...
36
votes
4answers
10k views

How can I log all process launches in Linux

I would like to get a log of all processes that are launched with the time that they were launched and the arguments they were launched with. Is this possible in Linux?
35
votes
4answers
100k views

How do I exit an SSH connection?

I’m connecting to a server via SSH to send a message to a socket server using a command like: ssh 181.169.1.2 -p 5566 After the connection is established and I write the message and send it I ...
35
votes
4answers
9k views

Linux equivalent command for “open” command on Mac/Windows?

Coming from Mac OS X, you can type: $ open yourfilehere.txt and your file will open just as if you had opened it from Finder. On Windows, one can type: > start yourfilehere.txt and it will ...
35
votes
3answers
2k views

Say`vimrc`or `screenrc`, what does the `rc` mean?

What does the rc mean?
35
votes
4answers
3k views

Palindrome passwords disallowed—why?

I tried to change a Linux password to "sitonapotatopanotis" and got this error: BAD PASSWORD: is a palindrome Why does this rule exist?
34
votes
12answers
4k views

How do I remove a file in Linux whose name looks like it's ONLY a hyphen, as in “-”

I've tried rm -- - rm "-" rm "\-" rm \- Gave Perl a shot ~$ perl -e '$junk = glob("-"); chomp $junk; print "$junk\n"; `rm $junk`;' - rm: cannot remove `-': No such file or directory ...and... ...
34
votes
13answers
50k views

In Google Chrome on Linux, where is the flv if not in /tmp?

I like to keep videos because I like buffering them and then playing them back-to-back in my media player, I want to be able to stop/restart my browser without losing all the buffered video, and ...
34
votes
5answers
6k views

What is the equivalent of Linux's “~” (tilde) in Windows?

In Linux, we can go to the user home by entering the tilde (~) character after cd: cd ~ How to do the same in Windows? Each time, I need to type: cd C:\Document and Settings\freewind That's too ...
34
votes
8answers
58k views

How to auto detect text file encoding?

There are many plain text files which were encoded in variant charsets. I want to convert them all to UTF-8, but before running iconv, I need to know its original encoding. Most browsers have an ...
34
votes
6answers
20k views

How do I get ls --color=auto to work on Mac OS X?

I'm trying to move my bash configuration from Ubuntu to Mac OS X and it looks like ls is slightly different. For instance, it won't accept the --color option. How do I get this to work?
34
votes
1answer
54k views

Linux unzip command: Option to force overwrite?

I am writing a shell script that unzips a ZIP file into an existing hierarchy of files, potentially overwriting some of the files. The problem is that the unzip command asks for confirmation: replace ...
34
votes
3answers
17k views

Set background image in xmonad

I have just switched from Fluxbox to giving xmonad a go, and I am definitely liking it. However, the one thing I haven't managed to do is to change my desktop background. I am using Ubuntu 8 (uh, ...
34
votes
8answers
7k views

How do you track which packages were installed on Ubuntu (Linux)?

(This question is very similar to 10458. It was suggested that Fedora and Ubuntu/Debian are different enough to warrant different answers.) As I use any Ubuntu setup I gradually install a number of ...
34
votes
11answers
119k views

PuTTY Network Error: Software caused connection abort

I have a strange problem: When I'm using PuTTY with SSH connecting to a Linux server hosted in VMware on my local Windows 7, I often get the error saying "Network error: Software caused ...
34
votes
1answer
28k views

How do file permissions apply to symlinks?

Let's say you have this structure: + directory -- file1 -- file2 -- file3 -> /tmp/file3 file3 is a link to another file3 somewhere else on the system. Now let's say I chmod 777 the directory ...
33
votes
15answers
16k views

What is Gnome / KDE etc?

I have been on Windows my entire life. Without getting too technical, what are these things? When I search on the net, I get some technical results. I simple do not understand what these things are! ...
33
votes
3answers
45k views

How can I create a non-login user?

I'd like to create a user and a group both called subversion on a RHEL 5 system. I looked at the man page for useradd and I guess the command would be just be... useradd subversion However, not ...
33
votes
2answers
4k views

How come one user can delete another user's 755 files?

I have a backup upload script that scp’s files to another server using the user upload. Another script on the target server then chown’s these to another user and sets the file mode to 755. If I then ...
33
votes
5answers
53k views

How to determine available free space on Ubuntu?

I am in a situation where I am getting an error when I try to save a file to my Ubuntu server via ssh. It says there isn't any available space left. I don't know how that can be true. What should I do ...
33
votes
3answers
12k views

Can a process be frozen temporarily in linux?

I was wondering if there is a way to freeze any process for a certain amount of time? What I mean is that: is it possible for one application (probably running as root) to pause the execution of ...
33
votes
3answers
90k views

How does one change user's home directory in Ubuntu 9.04?

Does anyone know how I might change my home directory in the shell please?
33
votes
4answers
87k views

How to update Google chrome in Ubuntu?

How to update Google chrome in Ubuntu?
33
votes
5answers
52k views

How can I know the absolute path of a running process?

If I have multiple copies of the same app on the disk, and only one is running, as I can see with ps, how can I know the absolute path to distinguish from the others?
33
votes
5answers
18k views

How to use different network interfaces for different processes?

I have two network interfaces on a Linux PC, and I need to manually set the interface that a given process will use. The program (Twinkle softphone) does not have a similar option, so I believe that ...
33
votes
5answers
9k views

Two keyboards on one computer. When I write with A i want a US keyboard layout, when I use B i want Swedish. Possible?

I have a laptop which I use an external keyboard with. When I type using the external keyboard I want to use a US keyboard layout, since that's the type of external keyboard I have. On the other hand, ...
32
votes
3answers
3k views

Have a file named ~ (tilde) in my home-directory

I just noticed that I have a file called ~ in my ~-directory. $ ls -la ~ ... -rw-r----- 1 x1 x1 733962240 Mar 1 17:55 ~ ... Any idea how I can mv or rm it?
32
votes
8answers
196k views

How to set current time on Linux?

Why is the output of the following commands different? root@vmi2115:/var# hwclock Sun 26 Jun 2011 01:21:38 PM CEST -0.273230 seconds root@vmi2495:/var# date Sun Jun 26 15:21:39 CEST 2011 ...
32
votes
9answers
23k views

Linux: Compare Directory Structure Without Comparing Files

What is the best and simplest way to compare two directory structures without actually comparing the data in files? This works fine: diff -qr dir1 dir2_ But it's really slow because it's comparing ...
32
votes
4answers
80k views

How do you set a password for transmission-daemon, the BitTorrent client server?

The config file is ambiguous, and keeps getting overwritten when you restart the daemon in Debian, anyway. In /etc/transmission-daemon/settings.json, there are these options: rpc-username ...
32
votes
13answers
24k views

Is there a way to display a countdown or stopwatch timer in a terminal?

How can I display a real-time countdown timer on the Linux terminal? Is there an existing app or, even better, a one liner to do this?
32
votes
3answers
43k views

How to get list of dependencies of non-installed RPM package?

apt-cache show <package> shows also it's dependencies. yum info <package> does not show dependencies, but it obviously know them. How to ask yum for dependencies of specified package?
32
votes
2answers
5k views

Slight delay when switching modes in vim using tmux or screen

Switching to and from insert mode in Vim is no longer instantaneous since I use tmux. After pressing Esc in insert mode, it takes a noticeable amount of time to actually get out of insert mode. After ...
32
votes
6answers
60k views

Bash script to delete files older than x days with subdirectories

I'm trying to delete a ton of files older than x days. Now I have a script to do that find /path/to/files* -mtime +10 -exec rm {} \; But this will also delete the subdirectories. There are a ton ...
32
votes
3answers
14k views

Does rm -f follow symbolic links?

I have a directory like this: $ ls -l total 899166 drwxr-xr-x 12 me scicomp 324 Jan 24 13:47 data -rw-r--r-- 1 me scicomp 84188 Jan 24 13:47 lod-thin-1.000000-0.010000-0.030000.rda ...
32
votes
2answers
4k views

How urgent is a *** System restart required *** for security?

To learn a bit of server administration I've set up a simple Ubuntu 14.04 server on which I run a personal website. I've set it to automatically install security updates, but leave out the other ...
32
votes
3answers
13k views

Bad font anti-aliasing in Ubuntu

I'm switching from Fedora 8 to Ubuntu 9.04, and I can't seem to get it to get a good font anti-aliasing to work. It seems that Ubuntu's fontconfig tries to keep characters in integral pixel widths. ...
31
votes
3answers
15k views

Convert a PDF to greyscale on the command line in FLOSS?

I have a colour PDF file, and I'm going to print it out and then photocopy it in black and white. I'd like to know what it's like in B&W before photocopying it. Is it possible to 'greyscale' a PDF ...
31
votes
4answers
15k views

How to: Unlimited Bash/shell history?

Is there a way to define an unlimited history in Bash ?
31
votes
2answers
28k views

Obtain kernel config from currently running Linux system?

I accidentally deleted my .config for my kernel configuration on Linux, and seem to remember there was a way to retrieve the kernel configuration via the proc filesystem somehow. Is this still ...
31
votes
3answers
28k views

How do I get out my embedded Windows 8 key from a Linux environment?

I have seen other SuperUser questions on this topic: How to find Windows 8 product key? | How to find Windows 8 OEM product key? However, all of the answers assume you have Windows 8 running. I've ...
31
votes
9answers
93k views

How to check the health of a hard drive

My SATA drive started clicking and I was unable to access the data. It was not clicking loudly though, like a drive that has already gone bad. After tightening the connections to the hard drive, it ...
31
votes
6answers
21k views

How can I diff two XML files?

On Linux, how could I generate a diff between two XML files? Ideally, I would like to be able configure it to some things strict, or loosen some things, like whitespace, or attribute order. I'll ...
31
votes
3answers
3k views

Can history files be unified in bash?

I routinely run multiple screen sessions on my Linux desktops and servers. A problem with this is that when I grep through my command history, I find I issued a command in a different session, and ...