38
votes
13answers
15k views

iptables Tips & Tricks

I'm sure Linux sysadmins are quite familiar with iptables, the userland interface to the netfilter packet-filtering framework. Now, this "Question" is meant to be a Community Wiki for collecting ...
49
votes
17answers
21k views

Switching to IPv6 implies dropping NAT. Is that a good thing?

This is a Canonical Question about IPv6 and NAT Related: How does IPv6 subnetting work and how does it differ from IPv4 subnetting? How can I 'dip my toes' into dynamic IPv6 ...
52
votes
5answers
3k views

How should an IT department choose a Linux distribution: Technical reasons

There is a lot of community feeling about what Linux distributions are appropriate for production server environments and what aren't. Some of this is based on the availability of commercial support. ...
40
votes
4answers
114k views

How can I port forward with iptables?

I want connections coming in on ppp0 on port 8001 to route to 192.168.1.200 on eth0 on port 8080 I've got these two rules -A PREROUTING -p tcp -m tcp --dport 8001 -j DNAT --to-destination ...
47
votes
2answers
52k views

SFTP logging: is there a way?

I'm wondering if there is a way to log commands received by the server. It can be all SSH commands, as long as it includes information on commands related to file transfer. I'm having issues with an ...
29
votes
14answers
13k views

Linux - Running The Same Command on Many Machines at Once

I have about a dozen Linux boxes that I occasionally need to run the same command(s) on. Is there an easier way (or automated way) to do this asides from logging on to each machine and running the ...
38
votes
15answers
4k views

Preventing brute force attacks against ssh?

What tool or technique do you use to prevent brute force attacks against your ssh port. I noticed in my Security logs, that I have millions of attempts to login as various users through ssh. This is ...
10
votes
3answers
2k views

LAMP Server Performance Tips [closed]

What performance tips can be offered to someone running a LAMP server? In the instance that something is Distribution specific, I'm targeting Debian.
33
votes
9answers
14k views

Why not block ICMP?

I think I almost have my iptables setup complete on my CentOS 5.3 system. Here is my script... # Establish a clean slate iptables -P INPUT ACCEPT iptables -P FORWARD ACCEPT iptables -P OUTPUT ACCEPT ...
22
votes
2answers
30k views

How to reduce number of sockets in TIME_WAIT?

Ubuntu Server 10.04.1 x86 I've got a machine with a FCGI HTTP service behind nginx, that serves a lot of small HTTP requests to a lot of different clients. (About 230 requests per second in the peak ...
22
votes
6answers
10k views

CIDR for Dummies

I understand what CIDR is, and what it is used for, but I still can't figure out how to calculate it in my head. Can someone give a "for dummies" type explanation with examples?
38
votes
12answers
2k views

Sell partitioning to me

I have often wondered why there is such a passion for partitioning drives, especially on Unixy OSes (/usr, /var, et al). This does not seem to be a common theme with Windows installations. It seems ...
19
votes
5answers
74k views

Finding why a user is locked out in Active Directory

A user's account keeps getting locked out in Active Directory. It's probably caused by an app that's using Windows authentication to connect to SQL Server. Is there a way to find out which app is ...
20
votes
6answers
29k views

Choosing local versus public domain name for Active Directory [duplicate]

What are the pros and cons of choosing a local domain name such as mycompany.local versus a publicly registered domain name such as mycompany.com (assuming that your org has registered the public ...
18
votes
5answers
12k views

How can I chroot ssh connections?

I would like to setup a chroot jail for most (not all) users logging in though SSH. I've heard it's possible with the latest versions of openssh, but I've not been able to find out how to do it. The ...
32
votes
1answer
9k views

HP ProLiant DL360 G7 hangs at “Power and Thermal Calibration” screen

I have a new HP ProLiant DL360 G7 system that is exhibiting a difficult-to-reproduce issue. The server randomly hangs at the "Power and Thermal Calibration in Progress..." screen during the POST ...
18
votes
11answers
29k views

VMware Linux Server — how can you tell if you are a vm or real hardware?

An interesting question. I have logged into a Linux (most likely SuSE) host. Is there some way that I can tell programmatically that I am a VM host or not? Also assume that the vmtools are not ...
15
votes
4answers
1k views

SSL certificate selection based on host-header: is it possible?

Is it possible for a web server to select an SSL certificate to use based on the host-header of the incoming connection, or is that information that is only available after the SSL connection is ...
9
votes
1answer
481 views

Why can't a CNAME record be used at the apex of a domain?

It's relatively common knowledge that CNAME records at the apex of a domain are a taboo practice. Example: example.com. IN CNAME ithurts.example.net. In a best case scenario nameserver software ...
2
votes
1answer
59 views

Hosting multiple distinct folders for distinct domains

I have a VPS that I've installed a Apache Web Server on. What I want to do is forward my own website domains to that server and host those websites' files inside my Apache Web Server. As far as I ...
104
votes
12answers
105k views

How to set up Nginx as a caching reverse proxy?

I heard recently that Nginx has added caching to its reverse proxy feature. I looked around but couldn't find much info about it. I want to set up Nginx as a caching reverse proxy in front of ...
69
votes
19answers
14k views

Why should I firewall servers?

PLEASE NOTE: I'm not interested in making this into a flame war! I understand that many people have strongly-held beliefs about this subject, in no small part because they've put a lot of effort into ...
44
votes
40answers
5k views

How do you manage your passwords?

Obviously seeing as how many of us here are system administrator type people, we have a lot of passwords strung out across numerous systems and accounts. Some of them are low priority, others could ...
61
votes
6answers
3k views

Choosing between meaningful and meaningless hostnames

Assume an environment with a puppet-managed cluster of different servers - various hardware, software, operating systems, virtual/dedicated, etc. Would you choose meaningful hostnames ...
50
votes
15answers
8k views

Are IP addresses “trivial to forge”?

I was reading through some of the notes on Google's new public DNS service: Performance Benefits Security Benefits I noticed under the security section this paragraph: Until a standard ...
24
votes
5answers
15k views

Geo-DNS providers? [closed]

We've got a website visited by users mainly in the USA and UK. The site will be run on servers in both these locations. We would like to use a DNS service to direct users to the nearest server, but ...
33
votes
23answers
5k views

Who is a good registrar these days? [closed]

It's been a long time since I've had to register a new domain. What registrar is considered geek and sysadmin friendly? I've heard that godaddy will screw you 10 ways to Sunday, and a lot of the ...
26
votes
8answers
5k views

How do you setup ssh to authenticate using keys instead of a username / password?

How do you setup ssh to authenticate a user using keys instead of a username / password?
24
votes
3answers
18k views

iptables port redirect not working for localhost

I want to redirect all traffic from port 443 to the internal port 8080. I'm using this config for iptables: iptables -t nat -I PREROUTING --source 0/0 --destination 0/0 -p tcp ...
31
votes
5answers
4k views

What to look for in a server rack?

I'm looking to purchase a rack/enclosure for some servers. As this is my first time shopping for this type of equipment, I need to know what to look for. I'm asking not only about how to buy the rack, ...
20
votes
6answers
6k views

Can windows domain controller be virtualized?

Just the question on the title. There is any problem? Any experience on this?
17
votes
6answers
7k views

Log all commands run by admins on production servers

It is company policy for admins to login to the servers via a personal username, and then run sudo -i to become root. Upon running sudo -i, sudo will create an environmental variable called ...
20
votes
7answers
18k views

How to workaround the NTFS Move/Copy design flaw?

As anyone that has dealt with file server permissions is aware, NTFS has an interesting design feature/flaw known as the Move/Copy problem. As explained in this MS KB article, the permissions for a ...
16
votes
5answers
11k views

Possible to get SSD TRIM (discard) working on ext4 + LVM + software RAID in Linux?

We use RAID1+0 with md on Linux (currently 2.6.37) to create an md device, then use LVM to provide volume management on top of the device, and then use ext4 as our filesystem on the LVM volume groups. ...
31
votes
2answers
7k views

Why does Heroku warn against “naked” domain names?

I ran across this page in the Heroku docs... Naked domains, also called bare or apex domains, are configured in DNS via A-records and have serious availability implications when used in highly ...
14
votes
4answers
39k views

How to configure vsftpd to work with passive mode

Whenever I install vsftpd on centos, I only setup the jail environment for the users and rest is default configuration of vsftpd. I create user and try to connect with filezila ftp client but I could ...
14
votes
1answer
11k views

How to interpret output from Linux 'top' command?

Following a discussion made HERE about how PHP-FPM consuming memory, I just found a problem in reading the memory in top command. Here is a screenshot of my top just after restarting PHP-FPM. ...
10
votes
2answers
2k views

Enabling hardware virtualisation BIOS; anything to beware?

A lot of recent virtualisation tools can either make use of, or demand, BIOS support (Intel-VT, AMD-V, etc). But in most of the BIOS screens I've seen, it has been disabled by default - sometimes even ...
7
votes
9answers
6k views

No free disk space [duplicate]

I have weird situation because Linux df command says that there is no free disk space [root@backup cache]# df -h Filesystem Size Used Avail Use% Mounted on /dev/sda3 72G ...
6
votes
5answers
3k views

Is it worth the effort to block failed login attempts

Is it worthwhile running fail2ban, sshdfilter or similar tools, which blacklist IP addresses which attempt and fail to login? I've seen it argued that this is security theatre on a "properly ...
4
votes
5answers
5k views

How can I automaticaly change the DNS A record to point my site to a secondary server in case of a failure?

My hosting is charging me a $50/month fee to put my servers on the same VLAN so that I create a cluster using the Network Load Balancing feature. I'm really not needing split the load between the ...
3
votes
4answers
4k views

HP D2700 enclosure and SSDs. Will any SSD work?

I've got an HP D2700 enclosure that I'm looking to shove some 2.5" SSD drives in. Looking at the prices of HP's SSD drives vs something like an Intel 710 and even something less 'enterprisey', there's ...
3
votes
3answers
3k views

How do I find out what is using up all the space on my / partition?

I am on a large instance on Amazon's EC2 servers. I run the df command and get: root@db:~# df -h Filesystem Size Used Avail Use% Mounted on /dev/sda1 9.9G 9.1G 284M 98% / ...
7
votes
2answers
592 views

Difference between SSL products

I'm looking into getting a few SSL certificates for domains to cover the following: autodiscover.example.com remote.example.com www.example.com Wildcard certificates are too expensive, so I'm ...
1
vote
2answers
2k views

My OpenSolaris Server hangs when writing large files after upgrading zpool

yesterday I added new harddrives(four as a raidz1 and one as hot-spare) to a opensolaris server, after extending the zpool the server hangs when writing large files but not when reading large ...
25
votes
0answers
1k views

What should I name my Active Directory? [duplicate]

Possible Duplicate: Windows AD Domain naming recommendations There are a lot of really screwed up configurations out there, because people didn't take a minute to sit down and think about ...
3
votes
4answers
640 views

ssh delay when connecting

When connecting to one specific server (running Debian Lenny) it always takes about 5 seconds before it prompts me to enter a password. After login there is no noticable delay anymore. There is also ...
66
votes
6answers
132k views

Boot and Install Windows from a USB thumb drive

Installing Windows from a thumb drive is vastly superior to burning a copy to a DVD which will fill some landfill somewhere with toxic stuff. Not to mention it's about 50x faster to install Windows ...
51
votes
8answers
100k views

What limits the maximum number of connections on a Linux server?

What kernel parameter or other settings control the maximum number of TCP sockets that can be open on a Linux server? What are the tradeoffs of allowing more connections? I noticed while load testing ...
54
votes
5answers
15k views

Active Directory explained

If you had to explain Active Directory to someone how would you explain it?

15 30 50 per page