8
votes
1answer
6k views

Why didn't Ctrl-C work?

I just hit Ctrlc twice at my shell in an attempt to halt a process that is taking a long time to finish. ^C was echoed twice, but the process just kept going. Why didn't Ctrlc quit the process like ...
2
votes
1answer
2k views

Bash Commands not working on Mac

Hello I open my terminal window on Mac Os 10.6.8 as I am trying to update my ruby to 1.9.3 and the terminal gives me this response immediately as I open it: -bash: export: /Library/Frameworks/Python....
65
votes
3answers
156k views

List all connected SSH sessions?

I just SSH'd into root, and then SSH'd again into root on the same machine. So I have two windows open both SSH'd into root on my remote machine. From the shell, how can I see a list of these two ...
3
votes
2answers
952 views

How does Debian make use of lots of CPU cores?

I just got an account on a 24 core VPS (according to UnixBench there are 24 CPUs). In general terms, how can I make good use of all these cores for general purpose shell computing in Debian? Do I ...
6
votes
5answers
407 views

Get filesystem name and usage with `df -h`

df -h | grep test | sed -e 's/*%.^ //g;s/.*[ ^I]//' Output: /test /test/drv0 /test/drv1 df -h | grep test | cut -d '%' -f1 | sed -e 's/*%.^ //g;s/.*[ ^I]//' Output: 10 20 15 I want to ...
2
votes
1answer
1k views

How may I distinguish encryption algorithm of htpasswd?

I have an apache web server running on Debian Linux and I secure a certain directory with htaccess. I have no history or knowledge how the .htpasswd file was created. Apache documentations says that ...
4
votes
1answer
4k views

How to download all the e-mail messages from POP3 server to a single text file with mailx?

I would like to download all the e-mails in my old e-mail server. It uses POP3 and I'm interested in e-mails in "Inbox" and "Sent" folders. Once I have downloaded all the messages, I would like to ...
2
votes
1answer
738 views

Starting Darkice automatically via daemontools

I have installed and configured darkice in Raspbian and it works fine if I run it with "sudo darkice". I want to run darkice automatically so I tried to run it via daemontools with the following steps ...
3
votes
1answer
4k views

Get all regex matches between two patterns and print them to file

I've got a file with a bunch of long lines. I'd like to grab every group between two patterns and print them to a new file, one match per line. I could manage to do this with Python, but I'd prefer ...
1
vote
1answer
42 views

Application fails if not in its directory?

I'm trying to run DeaDBeeF, a music player. It works fine if I'm in its directory, but if I'm anywhere else, it tells me that it "failed to find output plugin". Is there any way to get it to look in ...
1
vote
2answers
577 views

Performance and limitations of using an X GUI remotely?

I don't really have any experience with X. It appears from what I read that X has always been built from the ground up to allow windows in the WM to be transmitting over the internet, without ...
3
votes
1answer
507 views

How do I get tcpsvd to drop its root privileges?

Assume a script runs on boot as root. From this script I want to start tcpsvd -E 0 515 lpd. I want tcpsvd to run as an unprivileged user. But it requires root privileges to bind to the port 515. How ...
3
votes
0answers
286 views

“Overlay” a shell prompt on top of a terminal session? [closed]

I have several CLI application ideas that would be nice to run as an "overlay" on top of my terminal session. In other words I would like to superimpose a box containing a real live shell prompt on ...
13
votes
6answers
5k views

Can Linux “run out of RAM”?

I saw several posts around the web of people apparently complaining about a hosted VPS unexpectedly killing processes because they used too much RAM. How is this possible? I thought all modern OS' ...
0
votes
2answers
241 views

Low-RAM Linux Distro Specifically for serving static sites [closed]

I'm looking for a near-zero-configuration linux distro that is designed specifically for serving static web sites and nothing else on a low-RAM machine (I'm planning on 128MB, but the option of less ...
10
votes
2answers
14k views

How to tell rsyslog to create log file if not there?

Default behaviour by rsyslog is to append traces to an existing log file. Now, I've seen (CentOs, Scientific Linux) that when rsyslog is already running, you delete the log file (e.g. the one ...
2
votes
1answer
941 views

Cannot stop autofs on FC19

I'd like to temporarily disable autofs on my fedora 19 x86 install. I would like to insert USB drives without them auto-mounting. Typing: service autofs stop Returns: Redirecting to /bin/systemctl ...
2
votes
1answer
262 views

Best way to have taskset assign a job to random cores?

I have an application whose license limits it to 4 cores per instance, running on a 16 core box. Several of these instances run in parallel. Instances spin up and down throughout the day. In ....
4
votes
3answers
1k views

Split stdin by lines

I want to invoke a command for every line of the standard input, much like xargs, but the line should be passed as standard input, not as a command-line argument: cat some-file.txt | <magic> | ...
6
votes
1answer
3k views

resolve the server hostname of a dnsmasq server with multiple subnets

I have a self-made Linux router running dnsmasq. It has two different NICs through which clients are connected; one of them has the subnet 192.168.1. and one the subnet 192.168.2.. My /etc/dnsmasq....
2
votes
1answer
118 views

error using yum in centos 6

my yum command used to work fine , but now , when I try to use it , it gives me an error : file:///home/user/repo/repodata/repomd.xml: [Errno 14] Could not open/read file:///home/user/repo/repodata/...
0
votes
1answer
293 views

What bit of the xfce DE controls the wallpaper?

I want to have the glmatrix xscreensaver running as my desktop background, which works well on pure openbox, but in xfce I need to kill whatever is is running the root window (as far as I understand). ...
1
vote
1answer
992 views

Access a NTFS external drive in centos [duplicate]

Is there any way to access a external hard drive with NTFS format in CEntOS 6.2 ?
1
vote
1answer
3k views

MySQL aborting during initial db installation

Linux version: shell> cat /proc/version Linux version 3.2.0-4-686-pae (debian-kernel@lists.debian.org) (gcc version 4.6.3 (Debian 4.6.3-14) ) #1 SMP Debian 3.2.46-1+deb7u1 Installing MySQL 5.6....
3
votes
1answer
916 views

How to print (Cups, lpr, whatever…) in grayscale in a _generic_ way?

Problem: E.g. Cups just offers options to manage colors. Unfortunately they are specific to the manufacturers model. I.e. xerox is using e.g. "XRXColor, BW", Dell "ColorModel, KGray" etc... I am ...
4
votes
1answer
52 views

User-specific virtual machines in VirtualBox

Is it possible to start many VMs created by different users on the same Linux host? I want to start four virtual machines with my own user name and start four with another user name at the same time ...
3
votes
1answer
18k views

How to add 'open folder as root' in Elementary OS file manager context menu?

Here it is the solution in order to add the 'open terminal here' into the context menu of Elementary OS' file manager (generically called 'Files' - the executable is pantheon-files). For that ...
52
votes
2answers
115k views

Sorting down processes by memory usage

I am able to see the list of all the processes and the memory via ps aux and going through the VSZ and RSS Is there a way to sort down the output of this command by the descending order on RSS ...
1
vote
1answer
61 views

Is there a general rule for tracking an error?

I would like to start with an example here just to make it easy to convey my question. I have uncommented the following line from the /etc/pam.d/su file auth required pam_wheel.so use_uid thus ...
4
votes
2answers
4k views

What is the STATE column of the TOP command on Solaris?

I'm running a very large, memory intensive program on my new UNIX server and trying to fully understand the output of the "top" command. Here is what I see right now (showing only the first process): ...
0
votes
1answer
626 views

How to restore kde plasma desktop

I was tried chrome remote desktop app with a friend. He has a Mac. By mistake he clicked cmd + s, I do not know if that is super + s combination, the thing is it killed all my kde plasma widgets. Is ...
1
vote
0answers
42 views

Ubuntu Linux 12.04 - Load Non-MBR grub from the old grub in MBR

I have installed Ubuntu linux 12.04 on sda10, and grub2 in sda5 . Actually I had a legacy grub installed in MBR, I want to load Ubuntu linux from the old grub. How could I do this? This question ...
2
votes
2answers
2k views

Logrotate doesnt start proftpd triggerd by cronjob

Im currently running of ideas. The proftpd doesn't restart, if logrotate is triggered by the cron task. Logrotate rotates all logfiles stops proftpd but does not start proftpd again. If i force the ...
4
votes
1answer
564 views

Tmux: equivalent command to screen -d -m -S session_name

I'm looking at replacing screen with tmux, currently I use this screen command: screen -d -m -S session_name /root/script Is there an equivalent command for tmux that will do the same thing?
4
votes
1answer
11k views

Replace exact word with another in shell with tr command

I want to replace a word with another word in a text file. file.txt : alireza fallah my code : cat file.txt | tr ali ALI but I get this : ALI fALLAh it replace all 'a's to 'A' , and 'l's ...
0
votes
1answer
1k views

nfs-common installation fails

on newly installed Debian Wheezy machine, installation of nfs-common fails: apt-get install nfs-common Reading package lists... Done Building dependency tree Reading state information... Done ...
1
vote
2answers
688 views

“Out of Memory” error while copying large files with pcmanfm

This is an older machine running a Debian-based distro with lxde and pcmanfm used as file manager. pcmanfm normally runs quite well, except when it comes to copying very large files (e. g. *.VOBs from ...
5
votes
5answers
2k views

In Bash how does one determining the length of filename?

I'm doing a little script to rename some files. Actually a lot of files. The problem and the cool thing is, that I actually just need to change the files that have a filename length of 5 characters. ...
4
votes
2answers
2k views

Capturing Screenshot of terminal application via shell script?

Problem Run iftop for 5 seconds, capture the screenshot and save it to a file. iftop is a beautiful program for visualizing network traffic, but it doesn't have a batch mode where I can run it for ...
0
votes
2answers
1k views

How to remove n number of lines from a file using sed command? [duplicate]

I want to remove a particular number of lines after the given pattern is matched. Can anyone please tell me how that can be done using the sed command ?
0
votes
1answer
25 views

Correct way of updating plugins for webapplications hosted on linux

I am developing a plugin for PrestaShop, it works but the issue is with its autoupdate. Sometimes it fails on customers server due to permissions issues. The plugin is downloaded as a zip(using php/...
0
votes
1answer
3k views

How can I install perf 3.4.25?

By installing perf using sudo apt-get install linux-tools-common sudo apt-get install linux-tools-3.2.0.23 gave me perf version 3.2.14 How can I install perf 3.4.25? Is it related to kernel ...
1
vote
1answer
103 views

visit a website with multiple domains on the same server using the IP address

I've a web server hosting multiple domains, user webmin and virtualmin. How can I view the website for example www.abc.com by IP address? As I remember, something like user mode of Apache can view the ...
28
votes
8answers
26k views

Bash script to get ASCII values for alphabet

How do I get the ASCII value of the alphabet? For example, 97 for a?
1
vote
3answers
12k views

bash script check if variable is is [A-Z]

How do I check if a variable is in [A-Z] I want something like this: read var while [ $var in [A-Z] ] do #code here done How to achieve this?
1
vote
0answers
22 views

Interesting numbers when apache benchmarking

[root@NOTEBOOK ~] time for i in 128 321; do sleep 302; ab -n $i -c $i https://EXAMPLE.COM/ 2>/dev/null | egrep '^Complete requests:|^Failed requests:|^Requests per second:|^Time taken for tests:'; ...
7
votes
2answers
4k views

What's the difference between .local, .home, and .lan?

How can I reliably address different machines on my network? I've always used the .local suffix to talk to computers on my local network before. With a new router, though, .local rarely (though ...
1
vote
1answer
972 views

how to investigate Firewall blocked outbound TCP

CentOS webserver with CSF (Config Server Firewall) running. Blocking all outbound / Inbound traffic except listed ports 80 81 22 21 etc. for web, mail & FTP services etc. I'm use to seeing heaps ...
3
votes
2answers
538 views

Unlock Gnome shell takes a long time

I lock my GNOME Shell 3.6.3.1 by Ctrl+Alt+L as usual but when I try to unlock it takes up to a minute before I get my desktop back. While waiting I get a black background and a mouse pointer. Any ...
1
vote
2answers
5k views

“lftp” login still possible for “/etc/pam.d/vsftpd” blocked users

I have a ftp server running on the machine 192.168.122.50 Below are the last three directives from /etc/vsftpd/vsftpd.conf file pam_service_name=vsftpd #userlist_enable=YES #userlist_deny=YES ...

15 30 50 per page