Greatest Hits

89
votes
14answers
47k views

How do diff over ssh?

How do I diff files/folders across machines provided that the only connectivity available is ssh?
124
243
votes
27answers
58k views

100% uptime for a web application

We received an interesting "requirement" from a client today. They want 100% uptime with off-site failover on a web application. From our web application's viewpoint, this isn't an issue. It was ...
7
votes
5answers
80k views

Cannot enable network discovery on Windows Server 2008 R2

I'm trying to enable the Network Discovery feature on a newly installed Windows Server 2008 R2 instance. The network connection is in the Home or Work profile (it is not domain joined). These are the ...
8
votes
3answers
63k views

How to delete domain user profile from a computer?

I'm wondering how to safely remove a domain user profile from a computer that is a part of a domain. I don't want to delete the account from the domain itself, I just need to remove the profile from ...
62
votes
12answers
64k views

How to reconnect to a disconnected ssh session

Is there a way to connect to an ssh session that was disconnected? We are having problems with our network connection to a remote site that we are working on separately; however, in the mean time we ...
21
votes
8answers
79k views

Group Policy installation failed error 1274

I'm trying to deploy an MSI via the Group Policy in Active Directory. But these are the errors I'm getting in the System event log after logging in: The assignment of application XStandard from ...
19
votes
4answers
68k views

Get directory containing the currently executed batch script

I use %0 in batch file to get the containing directory of the batch file but the result is :- c:\folder1\folder2\batch.bat I want just directory, without batch file name, like this :- ...
10
votes
9answers
77k views

Windows File and Folder “Attributes” A or C

In Windows Server 2003, in the "Attributes" column of windows explorer, some files have "A" or "C" or "AC" or others. What do these mean?
1
vote
8answers
96k views

User Profile keeps loading TEMP Profile

I am having a difficult time with an issue that our support staff won't support (as they will not support Vista). I am able to log into our domain without any issue, however, when I go home and log ...
87
65
votes
11answers
9k views

How bad is it really to install Linux on one big partition?

We will be running CentOS 7 on our new server. We have 6 x 300GB drives in raid6 internal to the server. (Storage is largely external in the form of a 40TB raid box.) The internal volume comes to ...
29
23
votes
6answers
96k views

Disable password complexity rule in Active Directory

Where do I go to disable the password complexity policy for the domain? I've logged onto the domain controller (Windows Server 2008) and found the option in local policies which is of course locked ...
62
votes
11answers
65k views

apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName

I keep getting this warning when I (re)start Apache. * Restarting web server apache2 apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ...
107
votes
15answers
88k views

Why is DNS failover not recommended?

From reading, it seems like DNS failover is not recommended just because DNS wasn't designed for it. But if you have two webservers on different subnets hosting redundant content, what other methods ...
90
votes
2answers
32k views

How do I select which Apache MPM to use?

I'm a little confused between the different MPMs offered by Apache - 'worker', 'event', 'prefork', etc. What are the major differences between them, and how can I decide which one will be best for a ...
35
votes
7answers
68k views

How do you restart php-fpm?

I need to reload my php.ini and there's nothing in the help dialog about restarting it.
5
votes
9answers
48k views

How to remotely see what users are logged into Windows 7 or Vista

I need to login to a remote into either a Win7 or Vista computer but when I connect I get a Logon Message "Another user is currently logged on..." but it does not specify who. I have a domain ...
19
votes
11answers
27k views

What are your best senior level Linux interview questions

Every now and then on this site there are people asking what are some sys admin interview questions. Mostly when reading them they are all junior to mid-level questions. I'm wondering what are your ...
119
19
votes
2answers
21k views

ia32-libs : Depends: ia32-libs-i386 but it is not installable

I am trying to install ia32-libs (a dependency to build the VirtualBox sources) on my Debian x86_64 box, however it's giving me the error: The following packages have unmet dependencies: ia32-libs : ...
51
votes
3answers
58k views

How to add dependency on a Windows Service AFTER the service is installed

I have a Windows Service that makes use of a SQL Server database. I don't have control over the installation of the service, but would like to add a dependency on the service to ensure that it starts ...
29
votes
13answers
47k views

How to create an SHA-512 hashed password for shadow?

The previous SF questions I've seen have lead to answers that produce MD5 hashed password. Does anyone have a suggestion on to produce an SHA-512 hashed password? I'd prefer a one liner instead of a ...
73
votes
7answers
62k views

How can I run Debian stable but install some packages from testing?

Say you're running a server and you don't want to upgrade to Testing (Squeeze) from Stable (Lenny) to just install a required package or two. What's the best way of installing only certain packages ...
56
votes
6answers
51k views

Can I automatically add a new host to known_hosts?

Here's my situation; I'm setting up a test harness that will, from a central client, launch a number of virtual machine instances and then execute commands on them via SSH. The virtual machines will ...
42
votes
6answers
64k views

how to check if a library is installed?

In linux, how do I check if a library is installed or not? (from the command line of course). In my specific case now, I want to check whether libjpeg is installed.
8
votes
4answers
128k views

What's the default username and password for an Ubuntu Live CD?

What's the username and password for an Ubuntu Live CD image? I ask cause I've recently copied the contents of an Ubuntu based live ISO (easypeasy, the ldistro for nwtbooks) onto a harddisk, but the ...
72
votes
14answers
64k views

In my /etc/hosts/ file on Linux/OSX how do I do a wildcard subdomain?

I need to test sub-domains on my localhost. How can I effectively have this result of adding *.localhost.com to m /etc/hosts/ file? If it's not possible, how do I work around this problem? I need ...
47
votes
9answers
57k views

How can I export the privileges from MySQL and then import to a new server?

I know how to export/import the databases using mysqldump & that's fine but how do I get the privileges into the new server. For extra points, there are a couple of existing databases on the new ...
15
votes
2answers
87k views

I cannot connect to my local SQL Server 2008?

I've just installed SQL Server 2008 and I cannot connect to it with SQL Server Management Studio. My intention is to just let my local windows user be authenticated but I am not totally sure how to do ...
329
votes
13answers
58k views

How do I deal with a compromised server?

This is a Canonical Question about Server Security - Responding to Breach Events (Hacking) See Also: Tips for Securing a LAMP Server Reinstall after a Root Compromise? Canonical ...
13
votes
6answers
43k views

How can I edit the welcome message when ssh start?

I have a vps for my website hosting. It is running a ubuntu server. Every time I logged in my server by ssh, it displays a lengthy welcome message in my terminal. Linux node61.buyvm.net ...
17
votes
3answers
98k views

How to properly set permissions for NFS folder? Permission denied on mounting end.

I'm trying to connect to an NFS folder on my dev server. The owner of the folder on the dev server is darren and group darren. When I export and mount it to my Mac using the Disk Utility it mounts, ...
16
votes
3answers
71k views

How to write ISO image to usb memory stick from linux command-line?

I'm having trouble figuring out how I would write an ISO disk image to a USB flash memory device from the command line in Ubuntu. I have the Startup Disk Creator utility, but I need to be able to ...
29
votes
4answers
72k views

Adding a directory to $PATH in CentOS?

We just got our new server(s) up and we're running CentOS on them all. After successfully installing Ruby Enterprise Edition, I would now like to add the REE /bin (located at ...
7
votes
3answers
39k views

What is a domain controller, when is it needed, and how to set it up?

I would like to know what do we mean by Domain controller and how do we make a system a Domain Controller and when do we have to make a system a DC?
22
votes
4answers
83k views

How do I install an rpm that complains about rpmlib(FileDigests) <= 4.6.0-1?

Im trying to install an rpm file on CentOS 5 and Im not sure how to resolve this issues it brings up: $ rpm --install epel-release-6-5.noarch.rpm warning: epel-release-6-5.noarch.rpm: Header V3 ...
69
votes
8answers
74k views

how to set global PATH on OS X?

I'd like to append to the global PATH variable on OS X so that all user shells and GUI applications get the same PATH environment. I know I can append to the path in shell startup scripts, but those ...
23
votes
10answers
74k views

How to take ownership of files from the command line?

Every so often I run into a file that I need to take ownership of. I normally use cacls for changing ntfs permissions, but it doesn't seem to do ownership. Under *nix I would run something like ...
72
votes
8answers
106k views

How do I create a symbolic link in Windows?

Windows Vista added the ability to create symbolic links to files and directories. How do I create a symbolic link and what are the current consumer and server versions of Windows that support it?
28
votes
14answers
59k views

What is a patch panel?

What is a patch panel? How it is different from (layer 2) switch? EDIT: I think my primary question (and confusion) is this: Why don't network connections go straight to the switch? Don't we still ...
11
votes
7answers
46k views

How do I remove login credentials for a network location in Win7?

I just tried to access a folder like so: \\somecomputeronmynetwork\somelocation$ When going to this location I'm prompted for a user name and password. I put one in, and it let me in fine. Now I ...
52
votes
11answers
105k views

How do I find if there is a rogue DHCP server on my Network?

What's the best approach towards determining if I have a rogue DHCP server inside my network? I'm wondering how most admins approach these kinds of problems. I found "DHCP Probe" ...
27
votes
7answers
47k views

df in linux not showing correct free space after file removal

I have file servers which are used to store files. Files might reside there for a week, or for a year. Unfortunately, when I remove files from the server, df command doesnt reflect the freed up space, ...
13
votes
9answers
93k views

How to create a service running a .bat file on Windows 2008 Server?

I've created the service using sc create myService binpath=myservice.bat But when I start it, it fails with the following error message: [SC] StartService FAILED 1053: The service did not ...
105
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 ...
6
votes
7answers
33k views

Get list of AD groups a user is a member of

Suppose I have the user id of a user in Active Directory. I'd like to get a list of all AD groups in which that user is currently a member of. How can I do this from the Windows command line? I've ...
39
votes
9answers
45k views

Finding out what user Apache is running as?

I want to secure a file upload directory on my server as described beautifully here, but I have one problem before I can follow these instructions. I don't know what user Apache is running as. I've ...
26
votes
4answers
83k views

Where to set java heap options (e.g. -Xmx) for Tomcat 6 under Ubuntu 9.04?

I'm running Tomcat using the tomcat6 package from Ubuntu 9.04, which makes a daemon out of Tomcat using jsvc. I'd like to know the proper way to set Java heap options like -Xmx for Tomcat. I'd like to ...
12
votes
9answers
83k views

Unable to connect to mysql through JDBC connector through Tomcat or externally

I've installed a stock mysql 5.5 installation, and while I can connect to the mysql service via the mysql command, and the service seems to be running, I cannot connect to it through spring+tomcat or ...
46
votes
15answers
43k views

Showing total progress in rsync: is it possible?

I have searched for this option already, but have only found solutions that involve custom patching. The fact that it does not show in --help and no more info can be found probably indicates the ...
16
votes
7answers
69k views

How can I get a list of shared directories on local Windows server?

If I have a Windows server (typically 2000, 2003 or 2008), is there a simple way to list all local directories shared on that server? I can find the shares themselves easily enough, but I would love ...
49
votes
6answers
88k views

How do I create user accounts from the Terminal in Mac OS X 10.5?

I would like to be able to create new users in Mac OS X 10.5 remotely after ssh'ing into the machine. How do I do this?