Most Popular

1500 questions
48
votes
9 answers

Assign multiple IPs to 1 Entry in hosts file

I have a web sever that connects to an internal database through a VPN. There are 2 IPs (primary and secondary) to the database from the web server. How can I setup my /etc/hosts file so that if the primary IP is not available then the secondary…
Mike T
  • 493
  • 1
  • 4
  • 6
48
votes
6 answers

Permanent block of IP after n retries using fail2ban

I have a fail2ban configured like below: block the ip after 3 failed attempts release the IP after 300 sec timeout This works perfectly and I want to keep it this way such that a valid user gets a chance to retry the login after the timeout. Now,…
BTR Naidu
  • 627
  • 1
  • 7
  • 14
48
votes
34 answers

How are you documenting your work, processes and environment?

Are you using a wiki format? If so, which product? (MediaWiki, Confluence, Sharepoint etc.) Have you create a knowledge base? (Problem/solution-oriented short documents.) What challenges do you find with creating documentation that works, so you…
user1804
48
votes
2 answers

How can I see the contents of the mail whose ID I get from mailq command?

I used mailq command and I got a line like for example: A705238B4C 603953 Wed May 23 11:09:58 [email protected] So, now I'm wondering is there a way where I can "read" an actual content of the mail by its id A705238B4C
Nikola
  • 847
  • 4
  • 13
  • 22
48
votes
2 answers

How does Apache merge multiple matching Location sections

I'm working on some basic apache configuration, but I don't understand precisely how apache merges different sections when several of them match an incoming requests URL. The apache documentation in its "How the sections are merged"…
LordOfThePigs
  • 717
  • 1
  • 7
  • 7
48
votes
8 answers

Delete a iptables chain with its all rules

I have a chain appended with many rules like: > :i_XXXXX_i - [0:0] > -A INPUT -s 282.202.203.83/32 -j i_XXXXX_i > -A INPUT -s 222.202.62.253/32 -j i_XXXXX_i > -A INPUT -s 222.202.60.62/32 -j i_XXXXX_i > -A INPUT -s 224.93.27.235/32 -j i_XXXXX_i…
timy
  • 699
  • 1
  • 7
  • 14
48
votes
8 answers

Remove path from find command output

I have a bash script for deploying code from a beta environment to a production environment but currently I have to add the list of files to a txt file manaully and sometime I miss some. Basically my deployment script cat/loops copying the files…
Mikey1980
  • 751
  • 1
  • 8
  • 12
48
votes
6 answers

How do I view a file's hard links in Windows?

I've found a description of hard links and junctions in Windows, however I'd like to know ,from the Windows UI or command prompt, how I can view the hard links of a particular file or folder?
John K
  • 1,753
  • 3
  • 16
  • 21
48
votes
5 answers

How to disable Nginx logging?

I have the following in config file server { listen 80; server_name _; access_log /var/log/nginx/access.log main; ... server { listen 80; server_name example.com access_log off; error_log off; But it…
user965363
  • 743
  • 2
  • 6
  • 11
48
votes
1 answer

Chef best Practices/Questions

I use and love Puppet. I moved to a new company and they are adopting Chef. So I'm trying to learn Chef but am having a hard time piecing it all together because I still think in Puppet =) These are my questions: Is it better to setup roles in…
rizen
  • 503
  • 1
  • 5
  • 4
48
votes
5 answers

How to export result of a MySQL query using phpMyAdmin 3.4.3?

I've got a 30K row table When I run a long, 50-line query on that table, a GROUP function reduces the number of rows to 7K I want to export the grouped 7K rows as a new table, or save them as a CSV When I attempt to export, instead of getting the…
grape
  • 481
  • 1
  • 4
  • 3
48
votes
4 answers

How does SSO with Active Directory work whereby users are transparently logged in to an intranet web app?

I'm told that it's possible to make a web application that does not require a login. The user logs in to Windows, which authenticates via an Active Directory (LDAP) Lookup. Then, they should be able to go to my webapp and never see a login prompt.…
blak3r
  • 731
  • 1
  • 11
  • 16
48
votes
5 answers

Confidential Documentation and the role of the Sysadmin

I've got another interesting one. I'm about to backup and reinstall the HR Administrator's PC. I suspect that the fastest way to do this is to use the Windows 7 Transfer tool, and create a backup of the entire Users and Settings profiles on the…
Tom O'Connor
  • 27,480
  • 10
  • 73
  • 148
48
votes
8 answers

Why can't I connect to Amazon RDS after setting it up?

So, I just created the Amazon RDS account. And I started an instance of database. The "endpoint" is: abcw3n-prod.cbmbuiv8aakk.us-east-1.rds.amazonaws.com Great! Now I try to connect to it from one of my other EC2 instances. mysql -uUSER -pPASS…
Alex
  • 8,471
  • 26
  • 75
  • 99
48
votes
7 answers

How to find other end of unix socket connection?

I have a process (dbus-daemon) which has many open connection over UNIX sockets. One of these connections is fd #36: =$ ps uw -p 23284 USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND depesz 23284 0.0 0.0 24680 1772 ? …
user13185