question_id
int64
1
1.16M
title
stringlengths
10
191
question_body
stringlengths
6
2k
answer_body
stringlengths
0
2.5k
tags
stringclasses
73 values
question_score
int64
-15
1.65k
answer_score
int64
0
2.91k
view_count
int64
4
1.24M
creation_date
stringdate
2008-08-01 18:45:00
2025-06-19 04:44:02
category
stringclasses
12 values
source_site
stringclasses
8 values
168,867
How to populate a table with a foreign key from a dropdown list?
I am building an event planning application and require some help. To begin the user will create an event. They will then be required to register participants to this event using a user form. The eventID is a foreign key in the participants table and all participants registered must be associated with a particular even...
The error is telling you that you are choosing an EventID which is not in the [CODE] table. There are a few things you should do or consider: Never, ever, write a [CODE] using user input without sanitizing (filtering) . You are opening a very big door to SQL Injection . If any user would write the surname O'Brien you'd...
1
1
4,182
2017-04-01T19:11:42.497
data_quality
dba.stackexchange.com
1,034,285
Prompt user for TLS client certificate after already visiting the site?
Is there a way to re-ask for a client TLS certificate after the user has already (recently) been on the site - without needing to clear history? Preferably with nginx. The way nginx works with [CODE] is that after selecting none on first visit the browser remembers this, and doesn't ask again - event when the TCP (and ...
The directive [CODE] can not be used at any lower level of the configuration than a [CODE] block, so to have a different setting you will need to use a different [CODE] block, which also means a different hostname and/or port. So your only real solution is, as you said: use different origins (i.e port or domain) for th...
0
1
580
2020-09-17T15:50:42.293
infrastructure
serverfault.com
905,545
Server Apache shutting down, nothing useful in the /var/log/apache2/error.log
My web server on my VPS running on Ubuntu 16.04 suddenly gets down randomly. I have changed nothing that I know of that could cause that behaviour. I am running an Apache webserver, I use letsencrypt for SSL certificate, sslh to be able to ssh on the port 443 while hosting a web service. I am not very friendly with sys...
You have a configuration that depends on the load of lots of variables from another file, this file is usually called " envvars ". By loading apache2 directly without loading envvars in your environment you will get the errors you do. Note the syntax check is OK when you use " apachectl " but not when you invoke the bi...
1
2
788
2018-04-01T22:01:21.483
api_errors
serverfault.com
68,504
How should I set up SQL Server Login permissions for access to website on a different server using Windows Authentication
I know this question doesn't really belong here, but I posted on the MS IIS Site and am still hoping for a reply. I have an intranet site created with .NET Framework 4.0 in Visual Studio 2012 and I used the VS2012 publish command with "Window Authentication". The SQL Server is on a different server than the Web Server....
In order to get the application pool account to be recognized by the SQL Server you'll have to configure the application pool to run under a domain account. Then give this account the rights that it needs within the SQL Server instance. If you are using Windows auth then your users will need read access to the folder w...
1
2
1,709
2014-06-18T17:14:22.287
api_errors
dba.stackexchange.com
981,434
How do I add SSL to my Nginx and Docker build?
I'm trying to configure SSL on my server, but I've been getting a file not found error. Is there something I'm missing? Here's my Dockerfile: [CODE] My nginx config: [CODE] My docker command: [CODE] And here's the error I get: [CODE]
The issue was that Nginx couldn't find my keys. I was actually running the docker command as a permanent background task rather than [CODE] , so I wasn't getting any output!
1
0
2,114
2019-08-31T17:54:33.967
pipeline_ops
serverfault.com
1,126,140
How to upgrade to php 8.1 on RHEL 8.7?
How to upgrade to php8.1 in RHEL 8.7, I went through various guides and ended up installing php:remi-8.1 which is desirable however, php-gd is not willing to be installed cause of missing libraries. [CODE] Has anyone went through this before? Best guide so far: https://rpms.remirepo.net/wizard/ Installation of repos [C...
Seems like you missed to enable the EPEL repos on your system. The wizard does remind you of that. Check that EPEL and the CodeReady Repos are both enabled.
0
0
3,132
2023-03-14T10:08:16.423
infrastructure
serverfault.com
3,608
How do I calculate working business minutes?
I'm working on business inteligence reports and one of my task is to create reports for time tracking. I have to report on business minutes (10 hours per day) within business week (monday to friday). My initial solution was to use a scalar function. It did not cater for holidays, but it worked. It was not optimized by ...
If your reports are based on a data warehouse that is dimensionally modelled (generally the case for business intelligence solutions), it is highly probable there is a date dimension and time dimension. If there are no such objects, it may be very useful to create them as they become highly re-usable as other reports a...
4
3
795
2011-07-01T14:19:46.597
warehouse_errors
dba.stackexchange.com
710,016
Adding Folder Permissions Using Powershell
I'm running this script in PowerShell: [CODE] and I'm getting this error: Add-NTFSAccess : Cannot bind parameter 'Account'. Cannot convert value "PROGRAMMING\IIS_IUSRS" to type "Security2.IdentityReference2". Error: "Some or all identity references could not be translated." At line:1 char:46 + Add-NTFSAccess -Path 'C:\...
use: [CODE] or just [CODE] [CODE] is a special internal group that you shouldn't/can't prefix with the computer or domain name. For other internal groups you have to use the prefix [CODE] or the equivalent in your language, like: [CODE] Please note that [CODE] is not a Windows cmdlets, it's some script that the origina...
4
8
5,498
2015-07-31T16:10:11.880
infrastructure
serverfault.com
821,961
Hard disk failure or about to fail Intel RST software RAID-1 volume event log
If any one of the two Hardisk of Intel rapid Storage Technology(IRST) Software RAID-1 is about to fail or already failed, then what event will write in event viewer log and what is the Event ID for that.
The answer is here in step 5: http://www.whiz-tech.com/blog/2013/01/01/how-to-setup-e-mail-alerts-for-intel-ichr-raid-failure-monitor-applies-to-windows-2008-server-windows-7/ Intel Storage Matrix Manager: Under “When a Specific Event is Logged” screen select “Application” under Log Dropdown, “IAANTmon” as Source and t...
-1
0
2,858
2016-12-21T05:43:14.107
infrastructure
serverfault.com
42,110
How find all the data loaded on previous day?
Issue: Data Loading into development environment from production database My production database is 40gb but I do not want all of those 40gb of data into my dev env and so my question is How can I get all the data loaded into Oracle database yesterday? Is there a way in Oracle to get all data loaded into db on previous...
Oracle Data Pump Network-Mode Import may be one of possible solutions. You can invoke Data Pump Import in network mode using database link ( [CODE] parameter) and specifying which version of data you want to import with [CODE] or [CODE] parameters. First, create a database link to you production database on your develo...
0
2
1,433
2013-05-13T14:55:51.327
database_errors
dba.stackexchange.com
155,216
TEMPDB full causing login problems with server login trigger
We have a server trigger used to prevent some logins from accessing SQL Server via SSMS in our DEV environment. [CODE] This works just great when tempdb isn't full but when it is, all logins get rejected. [CODE] No one can login from anywhere and we are forced to restart the instance. This is not going to be possible f...
I would like to point out an another way to do this instead of the trigger. As @Nic pointed out in the comment, your solution does not prevent users from connecting through SSMS (as you can change the app name). You should create SQL-logins for the application or use service accounts if you are using Active Directory a...
0
1
519
2016-11-14T15:44:02.620
database_errors
dba.stackexchange.com
446,250
Why are cost and compliance not a software quality characteristic?
According to the standard ISO/IEC 25010:2011 , the "quality of a system is the degree to which the system satisfies the stated and implied needs of its various stakeholders". The standard defines 8 categories of quality characteristics: Functional Suitability Performance efficiency Compatibility Usability Reliability S...
Cost cannot be part of a quality metric. If it were, cutting the price without changing anything else would mean that the quality metric goes up, and increasing prices without changing anything else would mean that it goes down. Neither of these make any sense if you're trying to measure the quality of a product. Compl...
4
5
318
2023-06-26T14:13:36.163
api_errors
softwareengineering.stackexchange.com
125,140
Wildcard DNS entry to match lang subdomain
We have a website www.example.com pointing to x.x.x.1 and a system with multiples minisites all having subdomains.examples.com pointing to x.x.x.2 Basically what we have in place is a wildcard DNS entry who could basically match any possible subdomain, once reaching x.x.x.2, the apache vhost would intercept and basical...
You can't do the two letter match in DNS, a wildcard specifically matches one or more labels, and that's the full extent of pattern matching in DNS. Have you considered using [CODE] instead? Then within your re-write rules you can have (for example) [CODE] redirecting to [CODE] , and that can be done based on condition...
1
1
597
2010-03-22T22:44:27.120
infrastructure
serverfault.com
208,229
Splitting Existing Partitions in SQL 2014
I have a SQL Server table that contains over 20 billion rows, with 13 billion rows in the last partition. The table is currently partitioned 6 ways by a "Time" field: [CODE] The 2016/2017/2018 partition needs to be split into their own partitions so there is a 2016, 2017, 2018 partition. How can this be done and in the...
Below is an example script to create the new yearly partitions. You may need to tweak the script for your actual partition function name and new filegroup names. This method assumes the operation is performed in a maintenance window when there are no inserts into the table and data for 2016 and later isn't needed for q...
2
6
1,571
2018-05-30T10:54:11.543
database_errors
dba.stackexchange.com
354,690
Do any languages make evaluation of the right-hand of an "AND" operation optional?
The C# language has two "AND" operators when dealing with Boolean values, & and &&. (Leaving aside the bit-wise operators.) When the left-hand value is False, the difference between these two operators regards the evaluation of the right operand. Consider [CODE] vs [CODE] && means the right hand side must not be evalua...
There are languages like Haskell which make very little guarantees about evaluation. Haskell only guarantees that evaluation is non-strict, i.e. that [CODE] evaluates to [CODE] . That is pretty much everything Haskell guarantees. Any (sub-)expression may be evaluated any number of times (or never). However, languages w...
3
6
198
2017-07-28T17:10:18.163
api_errors
softwareengineering.stackexchange.com
545,602
Unable to access certain files on web server
Background: I'm running a CentOS VM with Apache installed. The web root is "/var/www/html". There is a subdirectory ("/var/www/html/mp3") which has two mp3's in it. Both mp3's have exactly the same permissions (644). The "/mp3" directory has 755 permissions. I have a database which holds certain information on the song...
Copied from a comment to an answer: You say "weird permission issue with CentOS", I think "selinux". Check /var/log/audit/audit.log and see if One.mp3 is mentioned.
1
1
822
2013-10-12T17:10:59.173
pipeline_ops
serverfault.com
300,672
How can I use a table as a GUID pool without suffering race conditions?
I am in a position where I will be issued with a list of GUIDs to be assigned by a SQL Server database at runtime. My immediate idea is to create a table for the GUIDs. When a batch of GUIDs is ordered, they will be inserted into the table. Then, at runtime, a SPROC will be called to pick a GUID from the table. I can e...
Basically you are looking for exclusive access to the next row in a queue table. Assuming this kind of table: [CODE] This procedure will serialize deletes without blocking another session from taking the next value: [CODE] Or if you want to update instead: [CODE] You would grab the next item off the queue like this: [C...
1
5
187
2021-10-05T14:30:36.070
database_errors
dba.stackexchange.com
119,766
How to verify that a PostgreSQL base + WAL backup has been restored correctly
Coworkers were trying to extract a PostgreSQL database copy from a backup made at a hot standby in version 9.1, but it wasn't reliable - we would run it daily, but usually it would end up with various errors while running queries against the copy. Sadly I hadn't been able to find a definitive answer as to why on the we...
The answer will contain two sections - first, what's acceptable to see in the logs after the restore, and second a few examples of what is not. The first section should be fairly deterministic, while the second one is basically a random assortment of whatever happened to us that indicated we had a problem. Acceptable l...
5
9
3,296
2015-11-01T15:57:15.943
database_errors
dba.stackexchange.com
165,089
Can I create a fixed size VHD that fills a physical hard drive up 100%?
Would this create any foreseeable problems? The drive is a non-system drive. Should I bother leaving any extra space on the physical drive that is not taken up by the VHD? This may seem a bit silly, but I have an explicit need to mount a vhd instead of mounting the physical volume itself. Thanks!
If this is not a system drive, then you shouldn't have any issues. The only catch you might find is that Windows might keep reminding you that the drive is full.
1
1
248
2010-07-29T00:48:54.910
infrastructure
serverfault.com
10,453
Unable to connect to remote service using AWS VPC Peering
I have a question regarding some AWS infra I'm trying to build. Due to legacy constraints, I have a service running in a remote VPC that I need to access, and I have a new service I'm developing in another VPC. the reason the 2 VPCs are separate is because the newer VPC is managed by Terraform and I am planning to migr...
How are you trying to connect to the remote service? - IP address, default internal/external DNS name or custom DNS name private/public hosted zone? Please compare the output of nslookup to the remote service in both the VPCs. If the IPs resolving are different, the traffic is trying to go through the public internet a...
0
1
202
2020-01-09T18:52:28.843
pipeline_ops
devops.stackexchange.com
640,366
Windows 7 Spamming Domain Controllers on ports 445 and 139, causing lockout
I have a domain lockout issue and in troubleshooting, I found through netstat that my machine is pummeling the domain controllers on ports 445 and 139. It is creating thousands of user ports to do this: today it started at port 54000ish and within a couple of hours was up to 60000. netstat -ob identifies the process as...
The offending service turned out to be Windows Media Player Network Sharing (wmpnetwk.exe). I don't recall using media player on this machine, so I'm not sure how that service got activated. netstat -bo was reporting "Can not obtain ownership information" for the process name and PID 4 (which in task manager shows "NT ...
0
0
2,542
2014-10-28T22:13:07.697
infrastructure
serverfault.com
836,413
Apache2 : redirect subfolder to https (http://example.com/sub -> https://example.com/sub)
I'm setting up an [CODE] server on [CODE] . I use a self-signed certificate because I want my [CODE] instance to be available only with [CODE] . For now, I use a permanent redirection : [CODE] I followed that guide for setting up a self-signed certificate. However, I would like to publish files in a public html directo...
I guess I would do something like (this is completely untested): [CODE]
0
0
781
2017-03-05T18:36:43.203
infrastructure
serverfault.com
1,050,701
Is there a practical limit to the number of files in a Swift container?
(Copied over from StackOverflow as I was told it is more appropriate here) A solution I work on stores files in OpenStack's Swift but the files are spread out into multiple containers. I have been told this is because the performance is awful after about a million files in a container. The only reference I could find i...
Also copying over my answer from Stackoverflow. The page that documents Swift's relatively new container sharding feature makes that point as well. The fact that developers implemented this feature indicates that this is a real problem. Container sharding could be a better method for your use case than storing objects ...
1
2
847
2021-01-21T15:59:38.363
pipeline_ops
serverfault.com
846,022
How to calculate Contention Ratio
I am managing network for a college which provides shared internet access to students and employees. I have been asked to find the contention ratio for the internet provided. Is it the ratio of users sharing the connection?
A contention ratio is how much bandwidth you have versus how much you have sold. For example, you might have a 1000Mbps internet link, but you have have 24x 100Mbps connections on it. That gives a contention of (24*100):1000, or 2.4:1. Another scenario might be that you have an imposed bandwidth limit of 10Mbps per aut...
0
1
9,293
2017-04-23T04:59:11.327
infrastructure
serverfault.com
810,099
certbot setting up ssl, error "No module named 'ConfigParser'"
I am setting up my website to use https via certbot. I am following the directions here I run the [CODE] and [CODE] with no problems, but when I execute: [CODE] I get the following errors: [CODE] I have mostly been focusing on the error: ImportError: No module named 'ConfigParser' But can't find any solutions. How do I...
First of all, removing Python 3 as suggested in a previous answer is a terrible idea, while it has a slight chance of fixing your particular problem, it is much more likely to create many more since any program depending on it will crash. Second, your problem stems from a modification that was made to your system that ...
5
4
2,172
2016-10-19T20:55:19.463
infrastructure
serverfault.com
109,432
Apply the select privilege to all users in mysql
I have 30 plus MySQL users their permissions vary from one another. I want to [CODE] privilege to all of the 30 users. Is there any one command that I can use that can [CODE] to all 30 users in one shot!
Try this: [CODE]
1
0
123
2015-08-07T20:54:21.473
database_errors
dba.stackexchange.com
57,290
Multiple IP addresses on one NIC register twice in DNS server
We've got a build server (Windows Server 2008 SP2, 64-bit) which has one NIC and two IP addresses registered to that NIC (192.168.1.30 and 192.168.1.31). The build server is registering two identical Host (A) records for itself in our DNS server: buildserver.example.com => 192.168.1.30 buildserver.example.com => 192.16...
I had same problem with server that hosts multiple IPs on single network card. On name resolving on other machines I was getting random one of those IPs. Since I don't control DNS server (and it was Friday late at night) I removed all IPs except one, check "Register this connection's address in DNS, verified on other m...
2
1
14,563
2009-08-21T19:06:11.630
infrastructure
serverfault.com
303,087
After server is restarted, the database and the backups are destroyed by the system crash. What ACID properties are broken in this situation?
Let's assume that two transactions execute on a database, both reading, and writing. At some time, the system crashes. After the server is restarted, the database and the backups were destroyed by the crash and the database does no longer exists. Which ACID properties would this break? My first guess is that it breaks ...
After the server is restarted, the database and the backups were destroyed by the crash and the database does no longer exists. If a server failure has destroyed both the database and its backups, then whoever set up the backups is, frankly, incompetent. The whole point of Backups - indeed, the only reason that we expe...
1
2
293
2021-11-24T19:55:23.133
database_errors
dba.stackexchange.com
252,840
Oracle JSON ADT in Collection
Why is the table() operator not working? [CODE]
[CODE] Example: [CODE]
0
1
332
2019-11-08T14:35:44.760
database_errors
dba.stackexchange.com
104,262
How to calculate the information conveyed in a message for a given dataset
Given the data sets. Test Set [CODE] Training Set [CODE] I'd like to calculate the message conveyed/ Information Gained via [CODE] . Ideally, I'd like to do this for n classes [CODE] The step for this calculation is at [CODE] [CODE] Any help with this would be greatly appreciated.
I was able to implement an outline for processing the tree [CODE]
1
0
33
2021-11-18T10:55:49.277
data_quality
datascience.stackexchange.com
31,653
How much overhead is involved with querying a DB on the same server?
History The company I work for had two databases, DB [CODE] and DB [CODE] , on two different servers. [CODE] contains information pulled from a COTS application database in addition to information from our own developed applications. This was done to ensure the COTS application database was never disrupted as it is req...
If you just want a readable copy of the data in table [CODE] , then there are ways to make this efficient without worrying about whether the copy is in the same database or a different database. Or a different server, for that matter, as long as you can reliably point your application differently depending on whether i...
2
4
1,426
2013-01-09T19:05:06.247
warehouse_errors
dba.stackexchange.com
919,535
apache reverse proxy with SSL gives '400 bad request'
I have an Odoo instance running on port 9069 in an Ubuntu server. Right now, apache is listening on port 8069 and is proxypass-ing this to 9069 (which works fine). The working URL is http://example.com:8069 Now, I need to make this work with SSL on the front end URL. ( https://example.com:8069 ). However this is giving...
I actually fixed it using the below modifications. [CODE] is changed to [CODE] And [CODE] is changed to [CODE]
4
1
19,683
2018-07-05T07:04:37.943
infrastructure
serverfault.com
69,311
Network (firewall) architecture for a LARGE corporate
I am wondering how many of you who work for LARGE companies have a network architecture that enforces the use of three-separate firewalls to get at the data. In other words: * Separation of external (internet) parties and a presentation tier by a firewall * Separation of presentation and application tier by a firewall ...
What you're looking for, re: justification for a three firewall architecture, sounds like a bit of a fantasy world that isn't going to map well onto reality. Unless you control all the applications, the harsh reality is that most application vendors are assuming unfiltered and unfettered access between the software com...
0
1
2,137
2009-09-28T02:58:11.163
infrastructure
serverfault.com
57,976
Windows 2003 User folder mapping issue
We have a windows 2003 standard domain server/client network with about 450 users. Each user has a login script that maps shares, and syncs the time to the server. Each user account also has a user folder mapped - [CODE] . Every so often, a user will login, and their user folder is mapped to the user directory ( [CODE]...
We occasionally see this behavior happen on our domain. It occurs rarely and randomly. Naturally they don't have permissions into anybodies folder except their own but it is more of a confusion issue. The issue has to do with the user logging in before the network connection has finished establishing. If it can't grab ...
1
1
377
2009-08-24T14:03:36.077
infrastructure
serverfault.com
636,902
hylafax + modem (USR Sportster Flash X2) + MODEM TIMEOUT: reading line from modem
I have the following issue with my modem Sportster Flash X2. We had set it up with hylafax and it worked week or two. But today during receiving of fax it hangs and is not responding. Here is log from the last time modem was working [CODE] First we had try to reboot modem because it usually did a magic but it didn't he...
OK finally we have figured out where the problem was. HP Proliant DL360e Gen8 we are using has ilo4 connected to serial port and through this connection it allows remotely connect to console. After disabling ilo4 virtual serial port in ilo4 bios (Settings -> Serial CLI Status -> Disabled) everything start to work witho...
0
1
387
2014-10-14T12:39:11.437
infrastructure
serverfault.com
18,579
querying a table of events for reporting
The background (masking a real-world problem behind a word problem) Farmer Brown has a peach orchard in California and ships hundreds of thousands of peaches all across the country. When a shipment of peaches reaches its destination, the deliveryman inspects the peaches and keeps all the peaches that fail his inspectio...
I'd add a [CODE] field to the fact table. You'll have a lot of rows, but clustering on the [CODE] field should be pretty efficient, and querying would be quite simple. [CODE] You can pre-aggregate this a little, as long as Farmer Brown is never going to care about to which farms he has been shipping peaches. Movin' to ...
5
1
188
2012-05-30T13:24:34.853
database_errors
dba.stackexchange.com
845,141
Where to put certificates in Tomcat, when app acts as client?
For starters, i have my Tomcat8 configured for https with valid certificated linked in connector xml file. Something like this: [CODE] But I need my web aplication to connect as client to third party data provider with valid certificate. Where do i put this extra certificate? When I put in keystore for connector, "http...
At the end, I created one keystore (with keystore explorer on windows) with all the necessary certificates(keys) and aliases. Then I filled out keystore and trustore as java VM launch parameters: [CODE] Same keystore is used in tomcat connector, with appropriate keyAlias for HTTPS. Enabling [CODE] is also very helpful ...
0
0
13,419
2017-04-18T19:38:14.313
infrastructure
serverfault.com
80,945
Deploying multiple pre-trained model (tar.gz files) on Sagemaker in a single endpoint
We have followed the following steps: Trained 5 TensorFlow models in local machine using 5 different training sets. Saved those in .h5 format. Converted those into tar.gz (Model1.tar.gz,...Model5.tar.gz) and uploaded it in the S3 bucket. Successfully deployed a single model in an endpoint using the following code: [COD...
I also have been looking for answers regarding this before, and after several days of trying with my friend, we manage to do it. I attach some code snippet that we use, you may modify it according to your use case [CODE] also, make sure your model [CODE] files have this structure [CODE] more info regarding this
1
2
3,649
2020-08-28T16:51:26.647
data_quality
datascience.stackexchange.com
1,153,662
Office365 - Exchange Mailflow Rules for Signature
im using Office365 / Exchange and I have setup a nice HTML template to attach dynamic E-Mail signatures using the Mailflow-Rule: "attach disclaimer". I have used the attribute %%PhoneNumber%% its always empty even though contact-information its perfectly filled in UserAccount and Exchange. Whatever I do it stays empty....
Just go to docs.microsoft.com there you have an overview of all the values you can use. Maybe activation of the rule with PowerShell it goes quicker. Yes the EAC can be slow. [CODE] https://learn.microsoft.com/en-us/exchange/security-and-compliance/mail-flow-rules/disclaimers-signatures-footers-or-headers#use-exchange-...
0
1
40
2024-02-15T16:57:36.593
infrastructure
serverfault.com
686,742
Recover overwritten RAID5 array (XOR)
As I've mentioned in a recent question ( RAID5 rescue with LVM2 running on it ) I'm rebuilding an RAID5 array. Now, I think that the initial wrong [CODE] command has started the rebuild. When I analyze the parity data I can see that starting from sector 200000 the parity data makes sense again. Beyond this raid I have ...
Even if it seems to non -match, aborting the resync should not alter your data that fast. If you are running a large-array (like 1TB disks), the resync normally takes hours, so aborting it should keep your data. In my case it worked, even if it seems to be mismatching. Whenever you get your raid running, keep in mind t...
0
0
102
2015-04-30T12:29:59.950
infrastructure
serverfault.com
91,095
Debian Apache2 and SSL
I recently took over a server that is using Apache2 with SSL. I have setup a new server to which I am migrating all of the old websites so that we can more easily scale (it's a cloud server) and so that I can set everything up correctly (or at least with some sort of convention). I have read quite a few articles on set...
I think your guesses about those being the certificate and chain is correct. What you need to do is look for the key file on your old server. Perhaps look at the old apache configuration file to see where key file is. Can you tell us a bit more about the old server? Maybe we can help you locate it.
0
2
382
2009-12-04T16:50:13.817
infrastructure
serverfault.com
402,197
What is the best use case of a regular expression (TripleByte question)?
I have lots of experience with regexes. I just want to make sense of this. Am I missing something here. Which one of these would you rather validate with a regex? Question reads , Which of the following is the best use case for a regular express? Select the correct answer: Validate an IP address Validate a SQL query Va...
I agree that I wouldn't use a regular expression for any of them, but if I had to choose, I would go for the IP address, because the other ones all have a nested structure, and are therefore not well-suited for regular expressions, which is what I think they are trying to get at.
-4
7
2,842
2019-12-07T22:41:38.407
api_errors
softwareengineering.stackexchange.com
679,760
Allow Powershell script executed on Exchange server to send mail - best practice?
I've got a single multi-role Exchange 2010 server and a need to execute a Powershell script on monthly schedule. And i really would like to send a report via email to some local company's mailbox by the end of the task. I created a service account with required permissions and wrote a Powershell script that's doing eve...
The solution is quite simple, having a password for ExchangeServiceAccount as SecureString $ExchangeServicePassword variable: # Mail server $SmtpServer = "mail.company.com" # .NET object MailMessage $Msg = New-Object Net.Mail.MailMessage # .NET object SMTP server and SMTP authentication parameters $Smtp = New-Object Ne...
1
0
1,294
2015-04-01T08:45:04.847
api_errors
serverfault.com
77,767
Simple, permanent queue system with pub/sub for Node.js?
Highly related https://stackoverflow.com/questions/6021938/nodejs-many-clients-requests-through-one-socket I'm investigating a robust message passing system for this application of mine. The easyest solution would be Redis pub/sub (it's simple, effective and I'd also use Redis for caching) but as I understand it, publi...
use a second permanent database. Use redis for real time sending of messages through pub/sub but also store all your messages in a permanent database (couch / mongo). Then when a Client / User reconnects load all messages from the real database and put them in the redis pub/sub system. You will need this anyway to impl...
6
4
2,944
2011-05-19T15:03:50.587
database_errors
softwareengineering.stackexchange.com
138,886
Emails going to Junk for Hotmail recipients
We send daily mass emails to our customers (~30,000+ emails per day). We have problems with Hotmail users receiving our emails. Sometimes the email goes to the Junk folder, but often it will got to their inbox, but the content is blocked so the user sees a message saying "This email was blocked and may be dangerous". I...
The solution I found for Hotmail to quit blocking the content of the email was in the configuration of the mass email formats; this also fixed the problem of gmail recipients seeing our emails as "Uknown Sender". Examples: Our emails were original sent as "Mr. President " and this would cause hotmail to block the conte...
5
4
10,035
2010-05-05T17:06:50.907
infrastructure
serverfault.com
320,857
pg_stat_statements slows down the database
I have an aws aurora postgresql cluster running posgresql 13.7 engine. The cluster is using the default parameter group. These are the default settings used for pg_stat_statements in the parameter group (i use the default parameter group - this exact one, for other clusters as well). Basically nothing is changed from t...
Try turning off/ setting zero for all the pg_stat_statements parameters in the parameter group. I had the same problem and this fixed the issue. Also see the related issue pg_stat_statements causing DB to run out of memory
0
0
1,301
2022-12-12T16:50:16.243
database_errors
dba.stackexchange.com
291,094
How to protect against attack against a domain name?
A friend has a domain name which redirects to another through the domain registrar control panel. A few hours ago the server hugely slows down. When he removes the redirection server runs normally. Is it frequent that a domain name is targeted ? The domain name is rather nice is it possible that some guys try to get it...
There is just generally a lot of stupid people doing a lot of stupid things across the Internet. Usually, it's nothing personal to any particular person, domain name or anything else. If the "attacking" IP addresses are visible across the server logs, then those attacks may be put under control by just blocking them fr...
-4
1
112
2011-07-17T00:11:50.660
infrastructure
serverfault.com
661,095
Postfix after-queue filtering for local destinations only
I need to run all mail addressed to local domains (as defined in vmail_domains) through a simple after-queue content filter which then re-injects the processed emails back into Postfix via sendmail. I have successfully created a perl filter based on the example of a simple after-queue content filter shown in the postfi...
Unfortunately, that filter only filters the mail arriving vid the internet and misses all of the local deliveries such as Postfix bounce messages, messages from other local users and messages from local scripts via sendmail. This is one of limitation from simple content filter. Quote from Postfix documentation The firs...
2
3
1,224
2015-01-21T02:43:15.633
infrastructure
serverfault.com
498,414
Using 'source' command in bash scripts
I am writing a bash script to attempt to automate initial setup on Ubuntu, and I have run into an issue I do not understand. If I run the following code: [CODE] then the script finishes, but most of the commands fail, as [CODE] is undefined (tested after script finishes with [CODE] ). If I then run [CODE] , [CODE] beco...
You don't really need the "$(rbenv init -)" invocation during your initial setup. That part helps later, when using rbenv in interactive environments and may add some opacity when debugging a script. Try adding before the actual rbenv invocation: [CODE] In fact, to use rbenv in scripts it's enough adding that one and t...
1
1
1,583
2013-04-11T14:17:52.457
infrastructure
serverfault.com
184,086
A performance Issue when querying a big table using a PK/clustered index
To simplify the situation, I will only consider one large table... On a nightly basis a store will send all the new and changed data for one day for a large table to the head office. (this portion is good) Also, the store sends a summary of that table for the last 30 days to the head office for that large table. At the...
If speeding up this query is critically important, I'd consider creating a covering index: [CODE] Adding a new index will impact the time to add, update, and delete rows from the table. You should test to determine the impact of adding this index to the nightly update process. It won't help if this speeds up the query ...
2
4
1,833
2017-08-22T14:29:55.117
warehouse_errors
dba.stackexchange.com
439,421
Single Gateway for multiple gRPC Services
Currently I have a monolithic gRPC server that implements several service stubs that are utilized by a large amount of internal client programs (none of this is public internet facing). As our requirements have gotten more complex and more backends are being accessed by the monolithic gRPC server, I am looking to break...
Not sure if this should be an answer, or just a comment but here goes. Internally, gRPC uses HTTP/2, and at least nginx supoprts being a reverse proxy in front of your server. The clients see a single server, while internally you split it up however you wish. Searching for "gRPC reverse proxy" gives a number of hits fo...
1
1
729
2022-06-22T21:17:56.840
api_errors
softwareengineering.stackexchange.com
252,544
Postgresql return results of dynamic SQL
I'm using Postgresql, version 12. My goal is to create a function, or stored procedure, which generates a dynamic select which is returned by the function or stored procedure. The difficulty is that the form of the table which is returned is not known in advance. This is a follow up question to a previous thread , in w...
You can create a function that returns a table, here is an example .
2
0
2,960
2019-11-05T03:18:31.080
database_errors
dba.stackexchange.com
946,193
How can I add (not replace!) a default route upon OpenVPN connection?
When I run [CODE] I do not yet have a default gateway defined. Once the connection is established, I run [CODE] , where X.X.X.X is the local IP of the newly created tun interface. That works perfectly fine. Avoiding the manual step, I would like OpenVPN do this for me. So I add [CODE] to the configuration. This fails w...
The best practice of the openvpn is adding the two routes ( [CODE] and [CODE] ) to avoid replace the original default route. For this you can use the route options in the open vpn client configuration file: [CODE]
0
0
1,719
2018-12-20T22:20:23.313
infrastructure
serverfault.com
313,975
Why instantiate an object to a base class rather than a specific subclass?
For example: [CODE] Here we could have created [CODE] instead for parent class [CODE] : [CODE] Or for another example when creating a [CODE] in an activity: [CODE] Instead of referencing the base class [CODE] here, why not create [CODE] after all [CODE] extends [CODE] . What is the benefit of coding it this way?
In layman's words: By declaring the variable with the superclass type (i.e. [CODE] or [CODE] ) you assure that the code that uses that object will work even if you instatiate it to a different kind of [CODE] or a different kind of [CODE] as long as they are a subclass of [CODE] or [CODE] respectively. The code should w...
8
12
5,261
2016-03-27T12:20:22.843
api_errors
softwareengineering.stackexchange.com
833,958
Kubernetes LoadBalancer works Only for Port 80 and not Others on Google Cloud
I am having trouble exposing ports other than port 80 on my Google Cloud Kubernetes cluster. Below is the Kubernetes service yaml file, but for some reason only port 80 is exposed. I have SSHed into the pods and can confirm that they are internally serving on the other ports listed below, but they don't seem to be expo...
I was able to solve this issue only by manually specifying the static IP of the LoadBalancer within the yaml file. This seems very wrong, and I'd bet that either I'm doing something else incorrectly, or there is some bug somewhere. My yaml file looks something like this: [CODE]
0
1
522
2017-02-21T15:33:56.877
pipeline_ops
serverfault.com
772,479
Issue with site to site OpenVPN
So my end goal is to utilise OpenVPN to connect to a remote IP camera. The reason I am going down the route of OpenVPN is to try and overcome the carrier grade NAT that prevents me from doing port forwarding and having a static IP without paying $$$ every month for the privilege. So below is what the topology looks lik...
The other thing I was considering is do I need to set the IP cameras default gateway to be that of the IP of the Raspberry Pi? YES. Only Raspberry Pi knows where to send traffic targeted to VPN. Another option is iptables setup with SNAT/MASQUERADE on Raspberry Pi so every connection from VPN network will have source I...
2
0
1,441
2016-04-23T18:52:33.273
infrastructure
serverfault.com
889,175
Installing MySQL on Red Hat Linux on the remote server without internet using pre-downloaded RPM packages
I am trying to install MySQL on the Red Hat Linux remote server without the internet . Problem is : Can't use internet on the server (so cant use 'yum install ..' commands) Solution found: To pre-download RMP packages required for the MySQL installation and use RPM command to install them respectively. (so I downloaded...
If you don't have internet on server, you should download all required RPMs and install it before MySQL Server RPM installation.
-1
0
840
2017-12-21T11:34:24.253
data_quality
serverfault.com
338,713
405 Method even when posting to a php file
I been googling, and all I can find is that this error may happen when you post to an html file. In my setup I have a rewrite rule, that basically hides the index.php from the url, and I for the longest time I thought it had something to do with that. Get works fine. Method Not Allowed POST request is not allowed for t...
I just solved this problem my self! I installed lighttpd, and got the same error again with lighttpd as well. I was looking at all the wrong places because the error 405 is a webserver error. However, I just started using a new php framework called fatfree F3, and the error is being generated by this framework when you...
2
2
2,549
2011-12-07T20:52:13.857
infrastructure
serverfault.com
415,774
MySQL doesn't logs error to new file after rotating?
Problem solved but I'm writing down for the future reference. [CODE] [CODE] [CODE] [CODE] [CODE] is working fine when running from the command line: [CODE] but it doesn't work when running from cron at 4 A.M. The logs file was rotated but MySQL doesn't logs the error to newly created file: [CODE]
In the [CODE] , I redirect both stderr and stdout to a log file to see what happens: [CODE] What I get is: [CODE] It sounds like [CODE] doesn't read [CODE] during logrotate. So, try this: [CODE] Source: http://bugs.mysql.com/bug.php?id=51005 http://scribble.scran.ac.uk/svene/weblog/2893.html
15
12
15,323
2012-08-09T03:15:07.533
database_errors
serverfault.com
556,700
Rename command mistake, files do not show anymore in windows network drives
I made a mistake with rename command [CODE] After that the files are not under their folders as they used to be and every file has . in front of them. Now my customers can not see the files. Once I remove the . then they can see the files. How can I remove . from the files. Like this: [CODE] to [CODE] Please help me! I...
[CODE] Think about -n parameter of rename : it just display what it will do after you remove it !
1
1
137
2013-11-22T08:07:25.653
infrastructure
serverfault.com
759,536
zfs: dataset does not exist
I'm not able to set mountpoint to the pool. [CODE] [CODE] Pool is normally visible and I'm able to import it into some direcotory. But I can't set nor get mountpoint: [CODE] Can you say me why I have this issue? Thank you in advance.
Obviously, you didn't import the pool. Furthermore, I think you don't want to set a mountpoint to / unless you import the pool with [CODE] key.
0
2
8,157
2016-02-24T19:03:32.600
infrastructure
serverfault.com
114,188
Migrating from PostgreSQL to SQL Server
I have been tasked to migrate a database from PostgreSQL 9 to SQL Server 2008 R2, and I have found some issues I need to address. I have quite limited experiences with PostgreSQL I'm afraid. Most keys are BigInt. In PostgreSQL a function is called to get the next ID and this is done in advance in the code for whatever ...
You can create your keys using a SEQUENCE . Every time you need a new ID from the sequence, you just have to issue [CODE] . Unfortunately not all versions of SQL Server support sequences (it's 2012 and up), so if you're stuck with SQL Server 2008 R2 you will have to code it by yourself. See Sequence Tables by Paul Whit...
1
3
728
2015-09-04T09:44:05.990
database_errors
dba.stackexchange.com
74,991
Optimised way to search over 2 milllion poi data in mysql
We have over 2 million poi data in our mysql db. At any time we need to find what is the nearest point based on the following formula found at this link http://sqlfiddle.com/#!2/abba1/4 [CODE] The problem we find this taking too long. Some forum suggest to limit the search based on +1 and -1 the lat and long value. The...
You can use Geohashing ( Geohasing ) You have to create a geohash for every POI in your table. And then based on the precision that you choose you can use [CODE] Where the [CODE] 's are the 8 neighbors from the center calculated by your desired precision. Keep in mind that you are limiting the results with the precisio...
0
1
101
2014-08-26T17:38:14.940
database_errors
dba.stackexchange.com
243,236
Add windows user to a particular database in SQL Server
I have a windows user who I want to add to just one database [CODE] on the server. I added them in [CODE] section of the Database and gave them db_datareader permissions on the database. I cannot add them in the Top level Security section since I don't have permissions for that. The issue is when the user tries to conn...
Yes, you must first create a [CODE] on the SQL Server instance , then create a [CODE] in the database which maps to that [CODE] . Without a [CODE] , the user cannot be authenticated to SQL Server (unless you're using a Contained Database, which is not a feature of your version of SQL Server), so they won't be able to a...
0
1
124
2019-07-18T18:06:38.687
database_errors
dba.stackexchange.com
153,171
What is the benefit of writing to a temp location, And then copying it to the intended destination?
I am writing an application that works with satellite images, and my boss asked me to look at some of the commercial applications, and see how they behave. I found a strange behavior and then as I was looking, I found it in other standard applications as well. These programs first write to the temp folder, and then cop...
A few reasons I can think of: On most platforms, file moves are atomic, but file writes are not (especially if you can't write all the data in one go). So if you have the typical producer/consumer pattern (one process produces files, the other watches a directory and picks up everything it finds), writing to a temp fol...
53
101
16,469
2012-06-16T14:48:23.407
api_errors
softwareengineering.stackexchange.com
849,811
How to update my WSUS server content folder manually
I have a WSUS Server on a virtualized Windows Server 2008 R2. My server its not connected to the internet directly so I use a upstream corporative server for the updates download. This other server its connected with windows update service. First of all when I tried to sync my WSUS server with the corporative one I onl...
Yes, see this link: How to Synchronize Updates Using Export and Import While it is technically talking about SCCM and WSUS, it will still work with just a WSUS server. After it is synced, you can then point your downstream WSUS server to the parent to stay in sync going forward. Be aware though that your 1Mbps bottlene...
1
2
3,576
2017-05-12T18:31:27.743
infrastructure
serverfault.com
89,690
Semantic segmentation in high-resolution images with high variance - cannot avoid underfitting
I am working on a dataset of 2K images for a semantic segmentation problem. I want to detect and localize small objects, with the smallest mask to be 5x5 pixels. The images include 5 different textures, quite different from each other. I am using Unet and EfficientNetb0-3 as backbones, but whatever I do, I get underfit...
Given your mask is very small, you should look at reducing your convolutions to 2x2 since that will help aggregate more information from these smaller masks. EfficientNet has 3x3 and 5x5 convolutions which may not be suited for your purpose. It is a better idea for you to train from scratch using smaller convolutions (...
0
0
138
2021-02-21T07:24:16.030
data_quality
datascience.stackexchange.com
877,759
Multiple networks with firewalld and libvirt/KVM
In the past i had a hypervisor set up with libvirt/KVM and IPtables in order to have VMs reachable through NAT on IPv4 (forwarding and masquerading don in iptables) and directly on IPv6 (routed network configured in libvirt), according to this tutorial collection (Example 1). Since i wanted to switch to CentOS 7, which...
When libvirtd starts up it will automatically probe to see if firewalld is available. If it is running, then libvirtd will use firewalld DBus APIs, instead of running iptables directly. So this from POV everything that libvirt does wrt firewall rules should continue to "just work" if you have firewalld enabled. If you ...
0
1
1,983
2017-10-10T11:08:17.410
infrastructure
serverfault.com
873,972
AWS infrastructure of a site with few independent endpoints
I have a WordPress blog that serves niche content on [CODE] On a different endpoint, [CODE] I have a completely different Node.JS API that doesn't regard the WordPress but I want to serve it from the same domain. It is worth mentioning that we proiritize performance and speed above all. My thought was the following : S...
How about 'wp.domain.com' and 'api.domain.com'? Any reason to not use subdomains? Then you can almost trivially solve your problem with DNS.
1
1
42
2017-09-16T10:09:22.620
infrastructure
serverfault.com
35,866
How to get only one row from excel which has multiple rows data?
Actually, I have written code for reading data from an excel file. But, I want to read the first row and if required then read the second row which is not happening in my code. I got all rows data from excel. How can I get only one row from multiple rows? I have tried to read data by using cell number, but it is hard c...
If you would like to return only 1 specific row then you have to pass the row number as a parameter to the function and also stop using the first loop and your [CODE] array will be of size [CODE] . please check this code. [CODE] This function will return a [CODE] with specific row number, So after getting the required ...
1
1
3,617
2018-10-01T07:09:09.160
data_quality
sqa.stackexchange.com
1,048,905
I accidently deleted database folder from MySQL Server
I have a MYSQL server and I had created some database on it. Accidently, I deleted one database folder from the directory. I have copy of that database folder saved as backup. I stopped the server and pasted the database folder in it. After starting the server I notice I can see the database but am unable to run Query ...
You need to delete and re-import the tablespace (assuming it's innodb). Have look at this article: https://blog.toadworld.com/2017/06/14/transportable-tablespaces-in-innodb .
1
0
1,386
2021-01-07T09:36:16.223
database_errors
serverfault.com
105,407
Slow address translation in small business network
Here at my office we've started to experience a slow down for browsing websites due to our router becoming bogged down by the the traffic. I've narrowed it down to the router as the problem goes away temporarily anytime the router is unplugged and plugged back in. Current network configuration Comcast SMB cable modem L...
I've seen this exact same issue on a Soekris router we once used. Rebooting it always fixed our issue in the short term but then it would slow down again. Your router definitely can't keep up. You're network is probably fine, it's your router that is the bottleneck. We use a Cisco ASA 5505 for one of our remote offices...
-1
1
196
2010-01-22T16:11:54.557
infrastructure
serverfault.com
889,221
Users "crontab -e" save location
I'm trying to add a new crontab entry for a user on my server by using a script. Unfortunately the user has no permission to write into the [CODE] file, which is not too bad, because i can manually add the entry by using [CODE] - which works like a charm. But as you may know, that's not a thing you can do in a script -...
User crontabs are stored in [CODE] and you can write to the user file as long as you format it correctly - [CODE] is really just a wrapper around a text editor to ensure that the file parses correctly and is in the right place.
1
2
506
2017-12-21T16:14:51.277
infrastructure
serverfault.com
272,347
PHP Dev on Windows w/ WAMP and deploy on Unix - .htaccess setup?
So I'm pretty sure this question has been asked before, but I simply cannot find the answer by Googling - feel free to point me to the right site/post to look up the answer. Apologies for my poor search-fu... :( I am developing a PHP application on Windows with WAMP. This needs to be deployed to a UNIX web host. The ap...
See this SO question and read up on RewriteBase to make sure you understand it. I would just use a regular rewrite rule(s) at the server level: [CODE] The mod_rewrite page has more details and examples if needed. The downside of this approach is having to have multiple rules to rewrite everything needed in which case y...
0
0
508
2011-05-22T04:01:47.750
infrastructure
serverfault.com
216,251
What does "Failed to allocate BUFs: FAIL_BUFFER_ALLOCATION 64" in the SQL Server Log mean?
Every once in a while, I see the error Failed to allocate BUFs: FAIL_BUFFER_ALLOCATION 64 in the SQL Server log. Oddly this seems to get thrown at off hours where there is no job or backup running at all. This is a physical install of SQL Server with 128GB RAM. Here are the version details: Microsoft SQL Server 2014 - ...
Failed to allocate BUFs: FAIL_BUFFER_ALLOCATION 64 This message means you are getting out of memory error (OOM). SQL Server is looking to allocate 64 KB of memory, but is unable to do so. Microsoft SQL Server 2014 - 12.0.4213.0 (X64) You are on an unsupported service pack level (SP1 + GDR). You should try patching up t...
1
1
3,138
2018-08-29T20:54:46.647
database_errors
dba.stackexchange.com
96,893
MySQL databases on their own separate Logical Volume
I'm looking for a way to keep MySQL database sizes within certain limits. That's why I was thinking about creating a logical volume for each database. So for example: db1 => lv_db1 (5 GB) db2 => lv_db2 (5 GB) ... This way the databases will not be able to grow beyond their 5 GB. I know the databases are stored in [CODE...
This may sound twisted but here it goes.... DON'T USE [CODE] If you login as root and you do the following: [CODE] you just created the database. The INFORMATION_SCHEMA database will dynamically register [CODE] in the INFORMATION_SCHEMA.SCHEMATA table as a database. Since you want to create a volume for it, you can do ...
1
1
1,376
2015-04-02T13:37:59.097
database_errors
dba.stackexchange.com
323,706
What should I do about a "misbehaving" user?
What should I do about this user? The user is: Downloading pornography Attempting unauthorized access Running hacking software Sending unsolicited email Installing software / tampering with the system etc This is intended as a generic answer for employee behavioral problems, a la Can you help me with my software licens...
When it comes down to it most of us are just systems administrators. We might be the ones to spot bad behavior and even sometimes called upon to help resolve situations. It is not our job to police or enforce employee behavior. That being said having strong tools at your company’s disposal to address behavior issues as...
26
31
2,433
2011-10-21T17:18:48.980
infrastructure
serverfault.com
401,622
Websites projects on different drive to WAMP install result in forbidden 403
I have installed WAMP to [CODE] and I would like to have my projects on my second drive, d. I have the following in my vhosts file: [CODE] and added [CODE] to my hosts file. However the project produces a 403 Forbidden error. Projects inside the default [CODE] directory work. Is there something else I need to do?
[CODE] add that within the VirtualHost tag.
-1
0
519
2012-06-23T16:20:19.053
api_errors
serverfault.com
100,299
Replication between SQL 2008 & SQL 2000 - Across network (DMZ) - process could not connect to Subscriber
I have 2 servers... OTTO is located on site, and connected to domain It is running SQL 2008. I have created the database, in SQL 2000 compatability mode. WEBDB3 is located in datacenter, not connected to our domain. It is running SQL 2000 DMZ set up between two sites, on Firewall. I've created a transactional publicati...
From joeqwerty 's comments: I just noticed in your errors that it looks like you're using named pipes on OTTO to connect to WEBDB3. Try configuring OTTO to use TCP\IP to connect to WEBDB3. Named pipes requires file and print sharing traffic to be able to transit the firewalls, which is probably being blocked. Use the S...
0
1
3,204
2010-01-07T01:13:02.883
database_errors
serverfault.com
745,253
How use setEnv with another Env?
My question is how can I use setEnv with an already defined environment variable. For example: "/etc/apache2/envvars" [CODE] "/etc/apache2/sites-available/domain.tld.conf" [CODE] Without env this config work! Error output [CODE]
You have a conceptual misunderstanding about how these work in Apache, but it's not your fault. It's very misleading in Apache and a very common misunderstanding. Background: There are two types of environment variables in Apache, native process-wide environment variables and per-request environment variables (that wil...
0
0
1,369
2015-12-25T13:51:47.263
infrastructure
serverfault.com
84,430
What's wrong with my cronjob syntax, I'm trying to use a backtick (`)?
Here's what I'd like to automate: [CODE] Here's the error message: [CODE]
From crontab(5) : The ``sixth'' field (the rest of the line) specifies the command to be run. The entire command portion of the line, up to a newline or % character, will be executed by /bin/sh or by the shell specified in the SHELL variable of the crontab file. Percent-signs (%) in the command, unless escaped with bac...
44
86
13,031
2009-11-13T15:05:16.877
infrastructure
serverfault.com
933,565
Ubuntu Static Network Issue
[CODE] i get this error [CODE] I use Ubuntu on VM box over wifii. Network settings - Briged adapter.
From my understanding this is expected behaviour. [CODE] This command removes every IP address assigned to the adapter eth0. So this adapter does not have an IP assigned currently. Now you try to set a default route. But this cannot work since the adapter does not know how to reach the next hop. Try setting an IP to th...
-2
1
105
2018-10-02T04:24:42.077
infrastructure
serverfault.com
198,637
Where is it appropriate to do input validation in Erlang?
I'm writing a module that runs a finite state machine* based on the contents of an array of records passed in at initialization. Each record describes a state and includes instructions on how to act on inputs (i.e., when in state [CODE] , input [CODE] triggers a transition to state [CODE] ). For the FSM to work correct...
The reason it seems less "Erlangy" to do onerous type checking is because the language is dynamically typed. If you really need to ensure that data of a certain type is used, you can use the is_TYPE/1 functions to verify your input as guard expressions. You should do this as early as you are able. http://learnyousomeer...
8
1
1,154
2013-05-18T18:20:13.837
data_quality
softwareengineering.stackexchange.com
93,770
When is a 'core' library a bad idea?
When developing software, I often have a centralised 'core' library containing handy code that can be shared and referenced by different projects. Examples: a set of functions to manipulate strings commonly used regular expressions common deployment code However some of my colleagues seem to be turning away from this a...
Core libraries are bad when they start suffering from feature creep, and very bad when they aren't well maintained. You might find this article interesting for an extended view point (which I agree wholeheartedly with): http://www.yosefk.com/blog/redundancy-vs-dependencies-which-is-worse.html Don Knuth: "To me, 're-edi...
10
12
3,298
2011-07-18T02:25:54.090
pipeline_ops
softwareengineering.stackexchange.com
62,151
What could cause an auto increment primary key to skip numbers?
I have a table created with the following T-SQL: [CODE] I took a look at this table today and noticed the id column was skipping values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 1027, 1028, 1029, 1030, 1031, 1032, 1033, 1034, 1035, 2034, 2035, 3034 I'm not worri...
There are many things that can cause gaps in an IDENTITY column (rollbacks, deletes), but in this case due to the jump I suspect it is this bug - caused by the changes to IDENTITY with the introduction of SEQUENCE: Connect # 739013 : Failover or Restart Results in Reseed of Identity So I bet that if you look in SQL Ser...
6
8
42,169
2014-03-31T12:44:15.767
warehouse_errors
dba.stackexchange.com
33,393
Adding tests to a half-finished project
Background: We are a small dev team in a larger org. We have no testers allocated to us. We have had our backs against a wall for five months developing something as quickly as possible. In that time, we've conducted manual unit tests and our (React web-based) application works well, considering. Situation: We're on th...
Follow Test Pyramid and apply 80/20 rule : 80% of tests are low-level unit tests 16% are API tests (services) (16% is 80% of the reminder) 4% are UI tests Start with manually running unit tests. Add CI for unit test, then services and UI tests as you have time. Jenkins is commonly recommended as test runner for CI. See...
8
6
167
2018-04-27T19:19:18.580
pipeline_ops
sqa.stackexchange.com
1,015,886
Powershell Exchange Add-MailboxPermission
The command Add-MailboxPermission is not working. It is giving me the error: [CODE] However, Get-MailboxPermission and some other commands (e.g. Get-Mailbox) from exchange Powershell module are working. Any help is appreciated.
What the version of your exchange server? Can you assign permission via ECP? Here are some suggestions for your reference: Restart the server and check if this issue continues. Drop the domain and re-join the server and check results. Run the command : Dcdiag on DC server and post out the result. Run command: repadmin ...
0
0
1,297
2020-05-06T07:41:06.903
infrastructure
serverfault.com
414,760
How to make the 'less' command handle UTF-8?
On my Mac terminal, printing UTF-8 works in general, but the [CODE] doesn't work correctly. So this works correctly: [CODE] but piping it into less gives something like this: [CODE] How can this be fixed? For diagnostics: I'm using Mac OS 10.6.8. less version 418, Terminal 2.1.2 (273.1). The output of my locale is this...
Okay, I found the answer after some googling. Apparently, [CODE] needs to be set like this: [CODE] Now [CODE] works fine for me.
42
60
24,816
2012-08-06T16:49:49.170
infrastructure
serverfault.com
195,871
Is deep nesting of control flow in code a studied problem?
I made the case to coworkers that deep levels of control flow was harmful to the readability of code. Example, taken from the relevant stack overflow question https://softwareengineering.stackexchange.com/questions/52685/if-you-need-more-than-3-levels-of-indentation-youre-screwed : [CODE] As with most things, it's triv...
Quick googling shows that some research has been done. For instance, this paper shows that there's a value of cyclomatic complexity of code that minimizes bug rate: Probably deep nesting may be fine as long as it does not branch at every point. That is, a having many nested conditions on top, as in your example, is pro...
8
4
836
2013-04-23T17:27:00.777
api_errors
softwareengineering.stackexchange.com
222,112
Optimal way to implement this specific lookup table in C#?
I want to create a lookup table for this data: The "input variables" (what is used to "lookup") are 4 different doubles that can each take on 1 of 200 numbers (the numbers range from 1-1000 but there are only 200 possible numbers that each can be (these 200 possible numbers that each of them can be are known to me)) th...
Doubles with 2 decimal places can easily be stored in an integer (just multiply each one by 100). If you map your 5 input variables to an index from 0 to 200 (or 1-5 for the fifth), you will need at most 5 bytes to store them all. For your output records, from what you write I estimate you will need around 4 bytes per ...
2
4
3,141
2013-12-22T14:09:26.467
api_errors
softwareengineering.stackexchange.com
370,504
Can't login to SQL Server 2008 on Domain Controller
Possible Duplicate: Cannot connect to SQL Server I had SQL Server 2008 functional before I installed Active Directory and setup a domain (this is on Server 2008 R2, the only domain controller), but now I can't login to the SQL Server (from SQL Server Management Studio). It says: Cannot connect to (local). A network-rel...
Apart from the obvious (don't run application services on a domain controller), you're apparently trying to connect via a Named Pipe - why ? Enable TCP/IP connections in the SQL Server Configuration Manager console and use a Domain Administrator to log on to SQL server specifically via TCP/IP. (Only Domain Administrato...
0
0
1,466
2012-03-16T17:37:45.600
data_quality
serverfault.com
46,752
MySQL 5.5 High CPU Usage
I have been working with a client with high traffic website(500k visitors and 600-800 active users at any given time). This uses wordpress and the DB is using MyISAM engine. The problem we had was high CPU usage in the server. All the time CPU load is 15-20. We used litespeed and MySQL 5.1 with CentOS 5.9 in Dual Xeon ...
OBSERVATION #1 When committing to use InnoDB, you also need to commit to tuning for multiple cores. innodb_read_io_threads : The default is 4. I would raise it 16. innodb_write_io_threads : The default is 4. I would raise it 16. OBSERVATION #2 I see you have [CODE] . If you set innodb_thread_concurrency to 0 (which is ...
3
3
14,707
2013-07-22T07:43:43.093
database_errors
dba.stackexchange.com
158,930
What is the easiest way to get mod_perl and mod_dav_svn integrated into Apache on Solaris 10
I've written some software that uses Perl code running inside Apache (using mod_perl) to work with (amongst other things) subversion (using the mod_dav_svn module). I'm currently writing some how-to docs on how to get this set up and running on various OSs and I've run into problems on Solaris. The Apache2 server that ...
Building packages from source in general is a pain, but once it's done, you can use it to make a package and provide binaries yourself and save others the trouble of doing so for your project. I've only done subversion myself rather than mod_perl, but I've taken a look at the build script we use for mod_perl (sadly it'...
4
2
883
2010-07-09T12:34:23.063
infrastructure
serverfault.com
261,315
Syntax for correctly capturing current user in a trigger
So this worked as a test: [CODE] Now I'm getting syntax error substituting "5000" with CURRENT_USER() per chapter 6.4 MySQL 8.0 reference this would be correct reference...but not allowing the info to be passed?
I don't understand how you have found a problem. [CODE] | CURRENT_USER() | | :---------------------------- | | fiddle_XQKHLETMKAXKBKBXJWXJ@% | [CODE] [CODE] [CODE] [CODE] id | user -: | :---------------------------- 1 | fiddle_XQKHLETMKAXKBKBXJWXJ@% db<>fiddle here Search the uncorrectness elsewhere.
0
0
353
2020-03-05T21:09:58.857
api_errors
dba.stackexchange.com
305,631
PostgreSQL ignores index, runs seq scan
My table contains an index for column [CODE] : [CODE] And simple query goes for seq scan [CODE] How can I make PostgreSQL use index? Or in other words, is there more efficient way to scan table on presence of NaN values?
Precise explanation Postgres has an operator for [CODE] as well as for [CODE] . But not for [CODE] . One operand has to be cast. [CODE] , a.k.a. [CODE] is the "preferred" data type among numeric types. See pg_type.typispreferred . Operator type resolution is eventually decided in paragraph 3.d. Run through all candidat...
5
9
1,650
2022-01-04T21:48:33.473
database_errors
dba.stackexchange.com
434,324
Windows Server 2008 R2 - backup error
I have a serious problem, I need to recover a file from the backup, which is done automatically, but yesterday ended with an error Is there any way that I can recover the file from D drive?
If you have Shadow Copies enabled on D:\ drive then you may be able to recover the file from there. To access shadow copies, right click the disk in "Computer" select properties, then Previous versions. Also, looking at the screen shot above, the D:\ backup seems to have completed, so although the backup set did'nt fin...
0
0
290
2012-10-03T07:35:08.830
database_errors
serverfault.com
613,927
500 error on fresh install of IIS and PHP
When attempting to run a PHP file on Windows server 2012 and IIS, I keep getting a 500 error. I cannot find any detailed logs or anything. However, when going to PHP Manager for IIS and click check config, I get the following error: [CODE] I installed PHP using Microsoft Web Platform Installer 5.0 on a fresh install of...
There's a fairly good chance you're missing the correct VC++ runtime for the version of PHP you're running. If you're running PHP 5.5.x you need to ensure the VC++11 runtime is installed: http://www.microsoft.com/en-us/download/details.aspx?id=30679 Make sure you download and install the x86 version ( [CODE] ), PHP on ...
34
54
89,451
2014-07-20T02:53:33.477
database_errors
serverfault.com
366,736
How to create UDP proxy using iptables
I have a server running UDP server on port 50000. This server receives updates from clients, and pings back the clients every 5 seconds to the socket they were connected from. Now I want to redirect all the traffic to and from this UDP server via another server. Basically I want to setup a transparent proxy in front of...
There are some points you did not mention in your description: If you are forwarding the traffic received by iptables machine to another one. You need to enable IP forwarding. See below for details. Also, you need to allow forwarded traffic to pass through. This can be done by setting the [CODE] chain default policy to...
7
5
16,771
2012-03-06T07:42:33.543
api_errors
serverfault.com
124,950
Virtual Machine Library not updating
I have a problem with my library window. I use to have a XP VM, which I deleted and now have a Vista VM. Every time I start Fusion, the XP VM shortcut will still be in the library (File not found), and the Vista VM won't be. I have tried re-installing Fusion but the same XP shortcut keeps coming up. Fusion doesn't seem...
You should be able to remove them from the list by right clicking them and selecting "Delete" from the context menu.
0
0
60
2010-03-22T14:03:25.990
infrastructure
serverfault.com
732,657
PXE boot kernel panic
I am having trouble setting up a PXE boot server. I've got [CODE] running, [CODE] serves the files over tftp (verified works), and [CODE] hosts the rootfs image. The PXE client seems to download the kernel and initrd files correctly, then kernel panics. Here is my [CODE] : [CODE] My server is an [CODE] installation. I ...
your kernel panics because it is not a a PXE compatible kernel/initrd set. If I were you I would not reinvent the wheel; take a proved PXE compatible distro and customize initrd to your needs and add the required squashfs. For a big list of PXE compatible distros and their corresponding parameters see Serva
3
1
2,957
2015-10-29T23:49:48.133
infrastructure
serverfault.com